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

v12 fail #370

Closed
mhosman opened this issue Aug 19, 2024 · 7 comments · Fixed by #372
Closed

v12 fail #370

mhosman opened this issue Aug 19, 2024 · 7 comments · Fixed by #372

Comments

@mhosman
Copy link

mhosman commented Aug 19, 2024

It fails sometimes with error message:

"1 errors occurred during unsubscription:\n1) Error: NG0600: Writing to signals is not allowed in a computed or an effect by default. Use allowSignalWrites in the CreateEffectOptions to enable this inside effects."

The bar get stuck at 100% and is not disappearing.

@MurhafSousli
Copy link
Owner

MurhafSousli commented Aug 19, 2024

Please fill the issue template properly, what angular version are you using? and add stackblitz reproduction

@mhosman
Copy link
Author

mhosman commented Aug 19, 2024

I'm using the latest Angular version: 18.2. Is an erratic behaviour and is not related to my code:

<ng-progress ngProgressHttp ngProgressRouter flat aria-progressbar-name="progressbar"
    color="'#e91e63'"></ng-progress>

I get that error in console after loading some stuff. If i comment this ng-progress code, the error never arises.

Maybe based on the error you can find the origin:

{ "stack": "Error\n at _super (http://localhost:4200/@fs/Users/martin/dev/MyProject/core-ui/.angular/cache/18.2.0/vite/deps/chunk-HBBEYCRV.js?v=84d645e1:250:22)\n at new UnsubscriptionErrorImpl (http://localhost:4200/@fs/Users/martin/dev/MyProject/core-ui/.angular/cache/18.2.0/vite/deps/chunk-HBBEYCRV.js?v=84d645e1:261:5)\n at Subscription2.unsubscribe (http://localhost:4200/@fs/Users/martin/dev/MyProject/core-ui/.angular/cache/18.2.0/vite/deps/chunk-HBBEYCRV.js?v=84d645e1:358:15)\n at Subscriber2.unsubscribe (http://localhost:4200/@fs/Users/martin/dev/MyProject/core-ui/.angular/cache/18.2.0/vite/deps/chunk-HBBEYCRV.js?v=84d645e1:558:36)\n at Object.cleanupFn (http://localhost:4200/@fs/Users/martin/dev/MyProject/core-ui/.angular/cache/18.2.0/vite/deps/chunk-Q5UIJGG6.js?v=84d645e1:122:15)\n at Object.run (http://localhost:4200/@fs/Users/martin/dev/MyProject/core-ui/.angular/cache/18.2.0/vite/deps/chunk-EOEZFFSG.js?v=84d645e1:346:12)\n at EffectHandle.run (http://localhost:4200/@fs/Users/martin/dev/MyProject/core-ui/.angular/cache/18.2.0/vite/deps/chunk-EOEZFFSG.js?v=84d645e1:23907:18)\n at ZoneAwareEffectScheduler.flushQueue (http://localhost:4200/@fs/Users/martin/dev/MyProject/core-ui/.angular/cache/18.2.0/vite/deps/chunk-EOEZFFSG.js?v=84d645e1:23883:14)\n at http://localhost:4200/@fs/Users/martin/dev/MyProject/core-ui/.angular/cache/18.2.0/vite/deps/chunk-EOEZFFSG.js?v=84d645e1:23874:31\n at _ZoneDelegate.invoke (http://localhost:4200/polyfills.js:300:158)", "message": "1 errors occurred during unsubscription:\n1) Error: NG0600: Writing to signals is not allowed in a computedor aneffectby default. UseallowSignalWritesin theCreateEffectOptions to enable this inside effects.", "name": "UnsubscriptionError", "errors": [ { "code": 600 } ] }

@MurhafSousli
Copy link
Owner

Make a reproduction please, I need to see the issue.

@mhosman
Copy link
Author

mhosman commented Aug 19, 2024

Sorry, I don't have time right now. I'm traveling today and I'll be off for 2 weeks.

@softworckx
Copy link

No idea that it's possible to reproduce it in Stackblitz but I'm facing exact the same issue as @mhosman.
I just upgraded from Angular 17.3 to 18.2 and from ngx-progressbar v11 to v12. I followed the wiki to change my module and styling and I'm getting the same error. I suppose the issue is somewhere in the ngProgressHttp, because that's the only way I interact with the progressbar. I can't reproduce it 100% at the same point, but when I click around in my webapp the error occurs after a few API-calls.

image

@MurhafSousli MurhafSousli linked a pull request Aug 24, 2024 that will close this issue
@MurhafSousli
Copy link
Owner

Please try with v12.0.1 and let me know!

@softworckx
Copy link

@MurhafSousli, I have given it a try and the reported issue is fixed. Thanks a lot, your new version (v12.0.1) works like a charm.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants