Hi folk,
I got this error message while trying to publish a package larger than 1GB to our local NPM registry. Looks like a Nodejs issue but I hope the Unity community should have the experience with it. Guessing a lof of project will create as large packages with graphical assets.
Thanks in advance!
Hi @Gunvald ,
You are right. This is a NodeJS/npm issue. As long as we rely on it to publish packages, we will have to cope with this limitation. NodeJS offers a configuration to increase the string buffer size limit. If you have Node 8.x or greater installed, you can try set the env var NODE_OPTIONS=--max_old_space_size=4096
.
I haven’t tried this myself. So, if you can, let us know if it works!
Regards,
Pascal
Hi Pascal,
I have tried increasing the max_old_space_size, which is solution for another type of error indeed.
FATAL ERROR: invalid array length Allocation failed - JavaScript heap out of memory.
So far, I have to split up the large package into smaller pieces as a workaround. Really hope the Unity editor built-in solution will work soon, with authentication.
Thanks!
1 Like