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

I'm getting 'Error: Cannot find module 'workbox-build'' error when trying to run my project after setup #1

Closed
lazio opened this issue Apr 15, 2021 · 1 comment
Labels
bug Something isn't working

Comments

@lazio
Copy link
Member

lazio commented Apr 15, 2021

Hey, I'm trying to run my project right after I initialized it, but getting an error:

npx kickin land                                                                                                                                                                     ░▒▓ ✔
npx: installed 32 in 3.041s
✔ package.json is created.
✔ Dependencies are installed.
✔ Project's structure is generated.
To start development server use:
  - npm start command.
To build project:
  - npm run build command.
Done! Happy coding :)
 ~/workspace ▓▒░ cd land                                                                                                                                                                       ░▒▓ ✔ | 36s
 ~/workspace/land ▓▒░ npm start                                                                                                                                                                      ░▒▓ ✔
> land@0.1.0 prestart /Users/serg/workspace/land
> npm run clean
> land@0.1.0 clean /Users/serg/workspace/land
> rimraf build
> land@0.1.0 start /Users/serg/workspace/land
> eleventy --serve --port=3000
Eleventy fatal error: (more in DEBUG output)
> Error in your Eleventy config file '/Users/serg/workspace/land/.eleventy.js'. You may need to run `npm install`.
`EleventyConfigError` was thrown
> Cannot find module 'workbox-build'
Require stack:
- /Users/serg/workspace/land/node_modules/eleventy-plugin-workbox/index.js
- /Users/serg/workspace/land/.eleventy.js
- /Users/serg/workspace/land/node_modules/@11ty/eleventy/src/TemplateConfig.js
- /Users/serg/workspace/land/node_modules/@11ty/eleventy/src/Config.js
- /Users/serg/workspace/land/node_modules/@11ty/eleventy/src/TemplateEngineManager.js
- /Users/serg/workspace/land/node_modules/@11ty/eleventy/src/EleventyExtensionMap.js
- /Users/serg/workspace/land/node_modules/@11ty/eleventy/src/TemplateRender.js
- /Users/serg/workspace/land/node_modules/@11ty/eleventy/src/TemplateData.js
- /Users/serg/workspace/land/node_modules/@11ty/eleventy/src/Eleventy.js
- /Users/serg/workspace/land/node_modules/@11ty/eleventy/cmd.js
`Error` was thrown:
    Error: Cannot find module 'workbox-build'
    Require stack:
    - /Users/serg/workspace/land/node_modules/eleventy-plugin-workbox/index.js
    - /Users/serg/workspace/land/.eleventy.js
    - /Users/serg/workspace/land/node_modules/@11ty/eleventy/src/TemplateConfig.js
    - /Users/serg/workspace/land/node_modules/@11ty/eleventy/src/Config.js
    - /Users/serg/workspace/land/node_modules/@11ty/eleventy/src/TemplateEngineManager.js
    - /Users/serg/workspace/land/node_modules/@11ty/eleventy/src/EleventyExtensionMap.js
    - /Users/serg/workspace/land/node_modules/@11ty/eleventy/src/TemplateRender.js
    - /Users/serg/workspace/land/node_modules/@11ty/eleventy/src/TemplateData.js
    - /Users/serg/workspace/land/node_modules/@11ty/eleventy/src/Eleventy.js
    - /Users/serg/workspace/land/node_modules/@11ty/eleventy/cmd.js
        at Function.Module._resolveFilename (internal/modules/cjs/loader.js:982:15)
        at Function.Module._load (internal/modules/cjs/loader.js:864:27)
        at Module.require (internal/modules/cjs/loader.js:1044:19)
        at require (internal/modules/cjs/helpers.js:77:18)
        at Object.<anonymous> (/Users/serg/workspace/land/node_modules/eleventy-plugin-workbox/index.js:1:93)
        at Module._compile (internal/modules/cjs/loader.js:1158:30)
        at Object.Module._extensions..js (internal/modules/cjs/loader.js:1178:10)
        at Module.load (internal/modules/cjs/loader.js:1002:32)
        at Function.Module._load (internal/modules/cjs/loader.js:901:14)
        at Module.require (internal/modules/cjs/loader.js:1044:19)
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! land@0.1.0 start: `eleventy --serve --port=3000`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the land@0.1.0 start script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR!     /Users/serg/.npm/_logs/2021-04-15T16_05_03_590Z-debug.log

here are my node/npm versions:

 ~/workspace/land  node -v                                                                                                                                                                      
v12.16.1
 ~/workspace/land  npm -v                                                                                                                                                                        
6.14.4
@Kapelianovych Kapelianovych added the bug Something isn't working label Apr 16, 2021
@Kapelianovych
Copy link
Contributor

Hello, thank you for contributing! This bug is fixed in 0.2.0 release.

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