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

TodoApp tutorial: error after 'Listing tasks' step. Cannot find module .wasp/out/server/src/core/auth.js #159

Closed
edoloughlin opened this issue Dec 18, 2020 · 3 comments
Labels
bug Something isn't working

Comments

@edoloughlin
Copy link

edoloughlin commented Dec 18, 2020

Please note the TodoApp still runs even though the error below is present.

Describe the bug
Using wasp v0.1.9
Follow the TodoApp setup steps to the 'Listing tasks' step.
I added the getTasks query to main.wasp and created ext/queries.js. Saved both files (save all to avoid intermediate 'file missing' errors).
Console shows:

Recompiling on file change...
Recompilation on file change succeeded.
Web app: Compiled successfully!
Server: [nodemon] restarting due to changes...
Server: [nodemon] starting `node ./src/server.js`
Server (stderr): (node:589921) ExperimentalWarning: The ESM module loader is experimental.
Server (stderr): internal/modules/run_main.js:54
Server (stderr):     internalBinding('errors').triggerUncaughtException(
Server (stderr):                               ^
Server (stderr):
Server (stderr): Error [ERR_MODULE_NOT_FOUND]: Cannot find module '/datadisk/ed/dev/TodoApp/.wasp/out/server/src/core/auth.js' imported from /datadisk/ed/dev/TodoApp/.wasp/out/server/src/dbClient.js
Server (stderr):     at finalizeResolution (internal/modules/esm/resolve.js:284:11)
Server (stderr):     at moduleResolve (internal/modules/esm/resolve.js:665:10)
Server (stderr):     at Loader.defaultResolve [as _resolve] (internal/modules/esm/resolve.js:755:11)
Server (stderr):     at Loader.resolve (internal/modules/esm/loader.js:97:40)
Server (stderr):     at Loader.getModuleJob (internal/modules/esm/loader.js:243:28)
Server (stderr):     at ModuleWrap.<anonymous> (internal/modules/esm/module_job.js:46:40)
Server (stderr):     at link (internal/modules/esm/module_job.js:45:36) {
Server (stderr):   code: 'ERR_MODULE_NOT_FOUND'
Server (stderr): }
Server: [nodemon] app crashed - waiting for file changes before starting...

To Reproduce
Install wasp-lang 0.1.9, follow TodoApp tutorial steps.

Expected behavior
No errors.

Screenshots

image

Desktop (please complete the following information):

  • OS: Pop_OS! 20.04
  • Browser: n/a
  • Version: n/a

Smartphone (please complete the following information):
n/a

Additional context
Add any other context about the problem here.
NodeJS v12.18.2

@Martinsos Martinsos added the bug Something isn't working label Dec 18, 2020
@Martinsos
Copy link
Member

Martinsos commented Dec 18, 2020

Hi @edoloughlin , thanks a lot for reporting this, it was a bug from our side!
I just fixed it and deployed new version of Wasp, 0.1.9.1, download/install it and this should be problem no more.

You mentioned you are doing save all to avoid intermediate 'file missing' errors -> what exactly do you mean by that? Those were the errors you would get from Wasp I guess?

@edoloughlin
Copy link
Author

I just saved main.wasp and queries.js using 'Save All' in my editor so the changes would be detected once.

@Martinsos
Copy link
Member

@edoloughlin got it! Any specific reason to do that? To avoid error messages from Wasp?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants