Open ctrlaltdylan opened 1 year ago
I can also reproduce this on my side
Nhost CEO here.
Is there anything we can do from our side to support resolving this issue?
Hi @elitan thanks for reaching out.
Does the NHost JS client make any changes to globals when it's imported?
I'm wondering if there's some kind of collision during the lifecycle of a Pipedream component.
Importing the graphql-request library throws the same error for me.
Importing "myq-api" does the same thing
Importing 'pdf-parse' does the same thing as well, see: https://pipedream.com/community/t/node-code-error-in-ui-but-unable-to-see-the-error/3809/6
Does the NHost JS client make any changes to globals when it's imported?
Not that I know of.
@dylburger @ctrlaltdylan Any predictions to fix this? We are considering abandoning Pipedream because of this issue that has been preventing us from evolving.
@renattomachado I looked into this more. Currently the original code:
import { NhostClient } from '@nhost/nhost-js'
// To use previous step data, pass the `steps` object to the run() function
export default defineComponent({
async run({ steps, $ }) {
// Return data to use it in future steps
return steps.trigger.event
},
})
returns this error trying to install packages:
Error: Cannot find module 'graphql'
@elitan Is there a reason the @nhost/nhost-js
package specifies graphql
as a dev dep and not a production dep? Looks like @nhost/graphql-js
also specifies the same (dev and peer dep). We install packages with pnpm -P
, so would only install dependencies
.
Pinging in @nunopato ☝️
@nunopato I just wanted to check in to see if you had a moment to look into this.
@renattomachado FYI
Describe the bug When attempting to import the
NhostClient
from NPM, the Pipedream code step breaks with a message:Code Error could not compute configurable props
To Reproduce Steps to reproduce the behavior:
Expected behavior I expect to be able to import the Nhost Client.
Screenshots
Additional context Reported from community here:
https://pipedream.com/community/t/error-code-error-could-not-compute-configurable-props/3299