This topic was automatically generated from Slack. You can find the original thread here.
I cloned (and edited) some pipedream code from github run this to publish it
pd publish Notion-Voice-Tasks.js
and it shows this
component create api call responded with status: 500, body: {"error":"Unexpected error, please reach out to our team at https://pipedream.com/support"}
It seems like you’re encountering an internal server error when trying to publish a Pipedream component. This could be due to various reasons, such as an issue with the Pipedream platform at the time of publishing or a problem with the component code itself. Here are a few steps you can take to troubleshoot this issue: 1. Check the Component Code: Ensure that the component code you’re trying to publish is correct and does not contain any syntax errors or issues. Make sure it follows the structure and rules for Pipedream components. 2. Pipedream Status: Check the Pipedream status page to see if there are any ongoing issues with the service that might be causing this error. 3. Support: Since the error message suggests reaching out to the Pipedream team, I recommend visiting https://pipedream.com/support for more support options. They will be able to provide more detailed assistance and help diagnose the issue. 4. Retry Publishing: Sometimes, temporary issues can cause such errors. You might want to wait for a few minutes and try publishing the component again. If you’re still having trouble after these steps, please provide more details about the component code or any specific steps you took before encountering this error, and I’ll do my best to assist you further.
I want to modify this action and can do the JS part …what I do not understand is how to get it to publish.
(I did reach out to Thomas and he’s happy for me to fork and mod. it - but does not have time to help)
Can someone walk through the steps to get that repo code to publish please ?
(github repo for this code from Thomas Frank)
ran npm run build and it builds for other items , but not this component (located in F:/pd/pipedream-master/components/personal/voice_tasks) Are you able to build this github repo on your system?
ie…
I worked out the issue !
There is a limit on the file size of 64k ! (65,536 bytes)
A file of 65,535 bytes will publish
pd publish note.js
"sc_lyi1vRz Note 0.0.9 just now note"
A file with 65,536 bytes will not publish and will give a generic error.
pd publish note.js
"component create api call responded with status: 500, body: {"error":"Unexpected error, please reach out to our team at https://pipedream.com/support"}"
I am unsure how Tom got his published as the .js file is 85k.
Based on the information provided, it seems you’re encountering an issue with the file size limit when trying to publish an action using the Pipedream CLI. The error you’re experiencing with a file size of 65,536 bytes suggests that there is indeed a limit close to that size. To address this issue, you might consider the following steps: 1. Refactor your code: If possible, try to refactor your code to reduce its size. This could involve removing unnecessary comments, using shorter variable names, or modularizing your code by splitting it into smaller, reusable components. 2. External modules: If your action script includes large libraries or dependencies, you might want to check if you can use external modules instead of bundling them with your action. Pipedream’s environment includes many popular npm packages that you can use without including them in your action file. 3. Split the action: If the action can be logically divided, consider splitting it into multiple actions that can be called sequentially within a workflow. 4. Publish as a multi-file component: If your action is complex and cannot be reduced in size, you might need to publish it as a multi-file component. This would involve separating your code into multiple files and publishing the component using the Pipedream CLI. Unfortunately, without access to live data or external content, I cannot provide a definitive answer regarding the file size limit for action scripts or specific steps to circumvent it beyond the suggestions above. If these steps do not resolve your issue, I recommend reaching out to Pipedream support for further assistance: https://pipedream.com/support They may be able to provide more information on the file size limit and offer additional solutions.
Hi that is a very large action, are you trying to include a static asset like an image, video or binary with it?
If so, you can use a File Store or Workflow Attachments to upload the file dependency separately to exclude it from the action’s code and reduce your overall size limit for the component.
No, it’s code. It’s not my code. But it’s code. See my first message for link to repo.
Tom (the code originator) was obviously able to publish it as his action is available to me to be cloned in Notion…but I can not publish the same code due to the size limit. https://thomasjfrank.com/notion-chatgpt-voice-tasks/
(and yes it’s a very large set of code!)
Thanks Andrew, I didn’t realize this was from the Thomas Frank tutorial.
Thomas has set up a specific support channel on his community for this, he may have a new update or guidance for working through this. I would ask this question there.
Thanks. As per my original post, He has no interest or time to helping me on this.
The issue (and ask here) is purely related to pipedream file size limits…not his code.
Is there a limit?
Ok - thanks for confirming.
I did not see it in a doco. search…but it could be easily missed so appologies if missed
Interesting that he is able to pub 85k (above the limit) and I am not.
Perhaps them limit was applied post his pub (ie a recent change) or perhaps he had special exemption applied. Anyways limit hit Time to take a chainsaw to code
Thanks for confirming
As a hack, I do not know enough about all the tools and practices - but I can usually stumble my way with some help. I never had to use minify before on my .js so it was news to me.
Thanks heaps and have a Merry Christmas.