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

NPM Error in frontend build #2

Closed
bwulff opened this issue Jun 30, 2023 · 5 comments
Closed

NPM Error in frontend build #2

bwulff opened this issue Jun 30, 2023 · 5 comments

Comments

@bwulff
Copy link

bwulff commented Jun 30, 2023

I'm trying to build the frontend using the command from the README and the default build arguments on SLES 15 with Docker 23.0.6-ce.

Step 16/22 fails with the following error message:

Step 16/22 : RUN npm run generate
 ---> Running in 98698f94514d

> [email protected] generate /bwhc-frontend
> nuxt generate

/bwhc-frontend/node_modules/@nuxt/utils/node_modules/consola/dist/shared/consola.4bbae468.cjs:473
                if (codePoint >= 0x3_00 && codePoint <= 0x3_6F) {
                                 ^^^

SyntaxError: Invalid or unexpected token
    at Module._compile (internal/modules/cjs/loader.js:723:23)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:789:10)
    at Module.load (internal/modules/cjs/loader.js:653:32)
    at tryModuleLoad (internal/modules/cjs/loader.js:593:12)
    at Function.Module._load (internal/modules/cjs/loader.js:585:3)
    at Module.require (internal/modules/cjs/loader.js:692:17)
    at require (internal/modules/cjs/helpers.js:25:18)
    at Object.<anonymous> (/bwhc-frontend/node_modules/@nuxt/utils/node_modules/consola/dist/index.cjs:5:15)
    at Module._compile (internal/modules/cjs/loader.js:778:30)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:789:10)
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! [email protected] generate: `nuxt generate`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] generate 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!     /root/.npm/_logs/2023-06-30T13_03_32_003Z-debug.log
The command '/bin/sh -c npm run generate' returned a non-zero code: 1

This seems to be an bug in one of the dependencies of nuxt, consola...

@bwulff
Copy link
Author

bwulff commented Jun 30, 2023

Maybe this issue should be moved to the frontend project?

@pcvolkmer
Copy link
Collaborator

pcvolkmer commented Jun 30, 2023

I will take a look at it. PR #1 could solve this problem.

In addition, an older, but freely available ZIP file is currently downloaded. I have already asked if I can use newer ZIP files from the published using dropbox in the future.

In addition to this, https://github.com/CCC-MF/bwhc-frontend/tree/docker and KohlbacherLab/bwhc-frontend#1 might be of interest.

@pcvolkmer
Copy link
Collaborator

pcvolkmer commented Jun 30, 2023

I suggest to use https://github.com/CCC-MF/bwhc-frontend/tree/docker (with docker branch) to create a docker image.

This will use latest (at the time of writing) frontend application and builds a docker image using Node.js 16 from source.

As mentioned above, the Dockerfile in this (docker-bwHealthCloud) project downloads outdated frontend package and I have to await permission to publish a new version with a download link providing newer frontend package.

@bwulff
Copy link
Author

bwulff commented Jul 3, 2023

The build of the bwhc-frontend on the docker branch works for me. Thanks!

@pcvolkmer
Copy link
Collaborator

We provide docker images for frontend application here: https://github.com/orgs/CCC-MF/packages?repo_name=bwhc-frontend

The images will be build from docker-dev branch which provides a Dockerfile with multi-stage build and images, that can be configured using env vars. The Nuxt application within will be (re)generated -if required- on startup. Branch docker-env is based on docker branch.

See docker/entrypoint.sh for more information.

I will close this issue. Since this project will be archived soon, please use this link to file any issues related to the docker build: https://github.com/CCC-MF/bwhc-frontend/issues

Use this project/link to file any issues related to the frontend application itself: https://github.com/KohlbacherLab/bwhc-frontend/issues

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