Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

play script fails to run #257

Closed
jameschensmith opened this issue Dec 7, 2020 · 1 comment
Closed

play script fails to run #257

jameschensmith opened this issue Dec 7, 2020 · 1 comment

Comments

@jameschensmith
Copy link

As mentioned here, the play script is currently not functional in the v2 branch. The error below occurs.

$ yarn play
yarn run v1.22.5
$ nodemon -e ts -w . -x ts-node src/playground.ts --project tsconfig.json
[nodemon] 2.0.2
[nodemon] to restart at any time, enter `rs`
[nodemon] watching dir(s): *.*
[nodemon] watching extensions: ts
[nodemon] starting `ts-node src/playground.ts --project tsconfig.json`
sh: ts-node: command not found
[nodemon] failed to start process, "ts-node" exec not found
[nodemon] Error
    at Bus.<anonymous> (./zod/node_modules/nodemon/lib/nodemon.js:156:25)
    at Bus.emit (events.js:327:22)
    at ChildProcess.<anonymous> (./zod/node_modules/nodemon/lib/monitor/run.js:167:11)
    at ChildProcess.emit (events.js:315:20)
    at Process.ChildProcess._handle.onexit (internal/child_process.js:275:12)
✨  Done in 0.32s.

To resolve this, simply adding ts-node to the dev dependencies should be enough. Though, playground.ts also appears to not be in a stable state either. The error below occurs.

Error: You can't call .parse on a schema containing async transformations.

Perhaps also putting playground in a stable state as well may be good for new developers coming in and being able to test out the library right away. A decision here should probably be made on whether this ticket should encompass both issues before a PR is sent in, though 🙂

@colinhacks
Copy link
Owner

colinhacks commented Dec 7, 2020

Should be stable now. I always try to delete the contents before pushing, guess I missed it this time 😬

I also added ts-node to devDeps.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants