store: π[BUG]: ngxs-store.js: Invalid count value
πππππππππππππππππππππππππππ
Hi, It might be not the best place to find the answer, but after a day of searching and commits revert, I keep get the following error which appeared after the nightly build. I reverted to the previous version in which the build had passed, but it was still not successful. Any ideas?
./node_modules/@ngxs/store/ivy_ngcc/fesm2015/ngxs-store.js - Error: Module build failed (from ./node_modules/@angular-devkit/build-angular/src/babel/webpack-loader.js): RangeError: /opt/build/workspace/Project/Feature_Build_Pipeline/angular-client/src/main/resources/node_modules/@ngxs/store/ivy_ngcc/fesm2015/ngxs-store.js: Invalid count value
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! tim-client@0.0.1 build-maven:dev:web: node --max_old_space_size=8192 node_modules/@angular/cli/bin/ng build --aot --configuration="dev_web" --output-hashing=all "--base-href=/jart-angular/"
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the tim-client@0.0.1 build-maven:dev:web script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
ngxs version: β@ngxs/devtools-pluginβ: β3.7.2β, β@ngxs/form-pluginβ: β3.7.6β, β@ngxs/logger-pluginβ: β3.7.2β, β@ngxs/router-pluginβ: β3.7.6β, β@ngxs/storeβ: β3.7.2β, Angular 14.3.0
Thank you!
πππππππππππππππππππππππππππ
About this issue
- Original URL
- State: closed
- Created 7 months ago
- Reactions: 1
- Comments: 16 (4 by maintainers)
We are unable to make any assumptions without reproducible examples, and the lock files do not provide sufficient information. I am unsure if we can proceed with resolving the issue until additional details are provided. Range errors typically originate from Webpack or Terser during the build process, and they can be challenging to identify. Debugging locally during the build, particularly by adding console logs in files such as
babel/webpack-loader.js
, is essential for pinpointing and addressing these errors.Hey guys. Found a potential solution. We bumped the version requirement for ng store to 3.8.1. See if that helps out yall.
unfortunately, I canβt change the labels for any reasons. Instead, I changed from support to bug. Letβs hope that we will receive an answer
Hi! The update to 3.8.1 fixed the issue. We had to make some adjustments after the update, but now everything is fine. Thank you all for help! @kingofdreams777 @tempodooloo @abhi-niceincontact @Rafeedmefood @markwhitfeld thanks to you and the team for your involvement I will close the ticket since the issue can be fixed with the update.
Great, thanks @alinghinea98 . Yeah, I see now that it is a problem that has suddenly been experienced by many people, and it is not related to any change that we have made, but an upstream dependency (still need to figure out which package that is).
Can I ask each person who is experiencing the issue to confirm whether or not you have frozen the dependencies of your project using a lock file? I suspect that most of you might not be using lock files to fix your dependencies, and so this failure just started happening. BUT, I hope that there is at least one of you who is using a lock file, and this issue happened after updating the lock file.
If there is someone like this (where things broke after a lock file update), then you may hold the key to figuring out what is causing the failure!!! We could compare the before and after versions of the lock file to possibly identify the upstream package. cc @kingofdreams777 @tempodooloo @abhi-niceincontact @alinghinea98 @Rafeedmefood
@Rafeedmefood Thank you so much for the context. The flood of comments was very familiar to the βspam the repoβ I have seen many times before, so my sincere apologies for assuming soπ. This is a very strange issue then! Neither NGXS v3.7, nor Angular v14 have published any new patch packages for those versions recently. I suspect that there is some upstream dependency of the angular build tool is not happy, and was updated recently. I am wondering if peopleβs package lock files will show the change since monday. Could you check if you are running npm ci or a similar βforzen lockfileβ installation command in your ci. This might resolve it in your ci if you havenβt updated your lockfile since monday. It would be super interesting to see a comparison of a working and non-working appβs lockfile.
+1 here. Seems to be affecting things at large and causing massive defects in builds. I think tagging this as βnot an issueβ is the wrong tag.