Skip to content
This repository was archived by the owner on Feb 16, 2025. It is now read-only.

www.libelektra.org down #4795

Closed
markus2330 opened this issue Dec 30, 2022 · 7 comments
Closed

www.libelektra.org down #4795

markus2330 opened this issue Dec 30, 2022 · 7 comments
Labels
Milestone

Comments

@markus2330
Copy link
Contributor

Website is down Uncaught Error: [$injector:modulerr] Failed to instantiate module elektra.rest.angular due to: Error: State 'main.dyn.installation' is already defined

Maybe due to #4794? I created #4794 to revert it.

Help appreciated.

@markus2330 markus2330 mentioned this issue Dec 30, 2022
31 tasks
@markus2330
Copy link
Contributor Author

@lukashartl Can you please also think about how we can check this kind of outage with monit?

@lukashartl
Copy link
Contributor

@lukashartl Can you please also think about how we can check this kind of outage with monit?

Adding a monit check that checks for a valid HTTP Response (>=200,<400) is easy.
But to also check whether we get valid JavaScript, would require to spawn a browser (Selenium, ...) and actually open the webpage every x minutes.

@markus2330
Copy link
Contributor Author

Yeah, it makes more sense that we let the build process fail in such cases. Unfortunately we don't know yet what is the cause and why the build succeeded.

I now tried to build it locally, and got following error during make install:

npm WARN deprecated angular-animate@1.8.3: For the actively supported Angular, see https://www.npmjs.com/package/@angular/core. AngularJS support has officially ended. For extended AngularJS support options, see https://goo.gle/angularjs-path-forward.
npm WARN deprecated angular-sanitize@1.8.3: For the actively supported Angular, see https://www.npmjs.com/package/@angular/core. AngularJS support has officially ended. For extended AngularJS support options, see https://goo.gle/angularjs-path-forward.
npm WARN deprecated angular@1.8.3: For the actively supported Angular, see https://www.npmjs.com/package/@angular/core. AngularJS support has officially ended. For extended AngularJS support options, see https://goo.gle/angularjs-path-forward.
npm WARN deprecated opn@6.0.0: The package has been renamed to `open`
npm WARN deprecated querystring@0.2.0: The querystring API is considered Legacy. new code should use the URLSearchParams API instead.
npm ERR! code ELIFECYCLE
npm ERR! errno 6
npm ERR! website@1.0.2 postinstall: `./node_modules/grunt-cli/bin/grunt install`
npm ERR! Exit status 6
npm ERR! 
npm ERR! Failed at the website@1.0.2 postinstall script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

and in the log:

1186 error code ELIFECYCLE
1187 error errno 6
1188 error website@1.0.2 postinstall: `./node_modules/grunt-cli/bin/grunt install`
1188 error Exit status 6
1189 error Failed at the website@1.0.2 postinstall script.
1189 error This is probably not a problem with npm. There is likely additional logging output above.

Looks rather unrelated to #4794?

@Namoshek Can you maybe help out here?

@Namoshek
Copy link
Contributor

Namoshek commented Jan 1, 2023

I cannot reproduce this locally on Debian 10 (WSL). I see the npm WARN and some npm notice, but not the error.

@markus2330
Copy link
Contributor Author

@Namoshek Thank you for looking into it! And did this website you were able to produce work?

Ok, my npm ERR might be some local problem. It wasn't there a few weeks ago, though.
What my test showed nevertheless is that make install doesn't fail despite of npm errors.

https://build.libelektra.org/job/libelektra/job/master/946/consoleText also doesn't have a npm ERR!. It doesn have plenty of additional npm WARN, though, e.g.:

npm WARN deprecated chokidar@1.7.0: Chokidar 2 will break on node v14+. Upgrade to chokidar 3 with 15x less dependencies.
npm WARN config production Use `--omit=dev` instead.

Unfortunately, it is not clear which of the warnings belong to the website build...

Maybe we need to build it more similar to the buildserver. Here a first start. Assuming we are inside a folder where libelektra master is checked out:

DOCKER_BUILDKIT=1 docker build -t buildelektra-website --build-arg JENKINS_USERID=$(id -u) --build-arg JENKINS_GROUPID=$(id -g) -f scripts/docker/website/Dockerfile .

 => => # npm WARN deprecated request@2.88.2: request has been deprecated, see https://github.com/request/request/issues/3142                                                                                                                                                  
 => => # npm WARN deprecated angular-sanitize@1.8.3: For the actively supported Angular, see https://www.npmjs.com/package/@angular/core. AngularJS support has officially ended. For extended AngularJS support options, see https://goo.gle/angularjs-path-forward.         
 => => # npm WARN deprecated angular-animate@1.8.3: For the actively supported Angular, see https://www.npmjs.com/package/@angular/core. AngularJS support has officially ended. For extended AngularJS support options, see https://goo.gle/angularjs-path-forward.          
 => => # npm WARN deprecated angular@1.8.3: For the actively supported Angular, see https://www.npmjs.com/package/@angular/core. AngularJS support has officially ended. For extended AngularJS support options, see https://goo.gle/angularjs-path-forward.                  
 => => # npm WARN deprecated docsearch.js@2.6.3: This package has been deprecated and is no longer maintained. Please use @docsearch/js.                                                                                                                                      
 => => # npm WARN deprecated mkdirp@0.3.0: Legacy versions of mkdirp are no longer supported. Please update to mkdirp 1.x. (Note that the API surface has changed to use Promises in 1.x.)

@mpranj
Copy link
Member

mpranj commented Jan 2, 2023

I think most of the mentioned (deprecation) warnings have been there for quite some time.

The problem was that multiple menu-entries with the same reference were created. (Error: State 'main.dyn.installation' is already defined). You're right, it seems it was introduced by #4756, but I fixed only the offending occurences instead of a complete revert.

I updates the website manually and will push the fix shortly.

@markus2330
Copy link
Contributor Author

Thank you so much for fixing it! I created #4803 as follow-up to avoid this problem in the future.

Can you share (in #4803) some insight of how you debugged the problem? How did you find out which part of the file is broken?

Dynamichost96 pushed a commit to Dynamichost96/libelektra that referenced this issue Jan 15, 2023
Janldeboer pushed a commit to Janldeboer/libelektra that referenced this issue Jan 16, 2023
@mpranj mpranj added this to the 0.9.12 milestone Jan 19, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

4 participants