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

Update node version in gh-pages.yml workflow file #8

Closed
kdipippo opened this issue Aug 7, 2021 · 1 comment
Closed

Update node version in gh-pages.yml workflow file #8

kdipippo opened this issue Aug 7, 2021 · 1 comment

Comments

@kdipippo
Copy link

kdipippo commented Aug 7, 2021

Thank you for putting this templated repo together! I found it extremely useful when utilizing it in my own project.

Bug Summary

A recent build following the workflow file gh-pages.yml resulted in the below error:

internal/modules/cjs/loader.js:818
  throw err;
  ^

Error: Cannot find module 'react-is'
Click for full error message
Run npm ci
added 414 packages in 4.487s

> daeclipse-openapi-spec@0.0.4 build /home/runner/work/daeclipse/daeclipse
> swagger-cli bundle spec/openapi.yaml --outfile _build/api/openapi.yaml --type yaml

Created _build/api/openapi.yaml from spec/openapi.yaml

> daeclipse-openapi-spec@0.0.4 html /home/runner/work/daeclipse/daeclipse
> npm run build && redoc-cli bundle _build/api/openapi.yaml  --output _build/api/index.html --options.onlyRequiredInSamples


> daeclipse-openapi-spec@0.0.4 build /home/runner/work/daeclipse/daeclipse
> swagger-cli bundle spec/openapi.yaml --outfile _build/api/openapi.yaml --type yaml

Created _build/api/openapi.yaml from spec/openapi.yaml
internal/modules/cjs/loader.js:818
  throw err;
  ^

Error: Cannot find module 'react-is'
Require stack:
- /home/runner/work/daeclipse/daeclipse/node_modules/redoc-cli/node_modules/styled-components/dist/styled-components.cjs.js
- /home/runner/work/daeclipse/daeclipse/node_modules/redoc-cli/index.js
    at Function.Module._resolveFilename (internal/modules/cjs/loader.js:815:15)
    at Function.Module._load (internal/modules/cjs/loader.js:667:27)
    at Module.require (internal/modules/cjs/loader.js:887:19)
    at require (internal/modules/cjs/helpers.js:74:18)
    at Object.<anonymous> (/home/runner/work/daeclipse/daeclipse/node_modules/redoc-cli/node_modules/styled-components/dist/styled-components.cjs.js:1:145)
    at Module._compile (internal/modules/cjs/loader.js:999:30)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:1027:10)
    at Module.load (internal/modules/cjs/loader.js:863:32)
    at Function.Module._load (internal/modules/cjs/loader.js:708:14)
    at Module.require (internal/modules/cjs/loader.js:887:19) {
  code: 'MODULE_NOT_FOUND',
  requireStack: [
    '/home/runner/work/daeclipse/daeclipse/node_modules/redoc-cli/node_modules/styled-components/dist/styled-components.cjs.js',
    '/home/runner/work/daeclipse/daeclipse/node_modules/redoc-cli/index.js'
  ]
}
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! daeclipse-openapi-spec@0.0.4 html: `npm run build && redoc-cli bundle _build/api/openapi.yaml  --output _build/api/index.html --options.onlyRequiredInSamples`
npm ERR! Exit status 1
npm ERR! 
npm ERR! Failed at the daeclipse-openapi-spec@0.0.4 html 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!     /home/runner/.npm/_logs/2021-08-07T15_20_03_874Z-debug.log
Error: Process completed with exit code 1.

Link to build: https://github.com/Pepper-Wood/daeclipse/runs/3269822656

Proposed Solution

Thanks to this comment - nodejs/help#1846 (comment) - a working fix was to update the node version that's listed in the gh-pages.yml workflow file.

Link to my code change: kdipippo/daeclipse@5dac86f

Following the diff here should be able to future-proof if any others run into the same issue with attempting to deploy.

@dgarcia360
Copy link
Owner

@Pepper-Wood First off, sorry for the +6 month delay. Many thanks for providing a fix!

I'm glad you find the extension useful. I recently had the time to upgrade the dependencies of this project to the latest version f4b2aa5

Please do not hesitate to let me know any other improvements you applied to daeclipse!

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