-
Notifications
You must be signed in to change notification settings - Fork 27k
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
Errors occurs when 'minimumCacheTTL' or 'icon.ico' are used with Turbopack #69330
Comments
@Enkratia Thank you for submitting an issue! I have shared this with the Turbopack team. We will be taking a look! |
Large TTL Value#69379 should fix the TTL issue by changing the Workaround: In the meantime, if you really want to set a TTL this large, just use ICO Decode ErrorThis is because your
ICO files are required to be encoded with a RGBA/ARGB colorspace when using PNG image data:
-- https://en.wikipedia.org/wiki/ICO_(file_format)#PNG_format This error comes from the image library we use:
While Workaround: In the meantime, you should be able to encode your ICO file using RGBA colorspace, which should fix this issue, or you can save the file as a normal |
Fixes (part of) #69330 We were using a `u32` here instead of a `u64` for no good reason. The workaround if you're encountering this is to just use `u32::MAX` instead, which should be large enough for all practical purposes: `4294967295`. ## Test Plan Build turbopack in the next.js repo: ``` pnpm pack-next ``` Follow the repro in #69330: ``` git clone https://github.com/Enkratia/css-reload-show-2.git # edit the package.json following the instructions from `pnpm pack-next` above rm package-lock.json pnpm i pnpm dev --turbo ``` ## Integration Testing? There are some tests in `test/integration/image-optimizer/test/index.test.ts`, but I didn't see the obviously best way to test this, as most of those tests are looking for errors by scanning stderr, and this is about not generating any error. Either way, I think this is very unlikely to regress.
This closed issue has been automatically locked because it had no new activity for 2 weeks. If you are running into a similar issue, please create a new issue with the steps to reproduce. Thank you. |
Link to the code that reproduces this issue
https://github.com/Enkratia/css-reload-show-2
To Reproduce
First error:
minimumCacheTTL
(in terminal)Second error:
minimumCacheTTL
innextConfig.images
(innext.config.mjs
)icon.ico
(in browser)Current vs. Expected behavior
minimumCacheTTL: 31540000000
tonextConfig.images
it gives an error:** Yes, minimumCacheTTL is not needed in dev mode, so i can just create 2 different
next.config.mjs
(for dev/prod mode), but this is working withwebpack
without any problems.**
minimumCacheTTL: 3154000000
is working fine (one zero less).** It might be related to
BigInt
.icon.ico
inapp
(as it is written here https://nextjs.org/docs/app/api-reference/file-conventions/metadata/app-icons) - i get this error:Expected behavior - no errors (these errors doesn't occur when webpack is used)
Provide environment information
Which area(s) are affected? (Select all that apply)
Turbopack
Which stage(s) are affected? (Select all that apply)
next dev (local)
Additional context
** Actually my Operating System is Linux MInt 21 Cinnamon Edition x64, but when i use: "npx --no-install next info", - i am getting an error: "npm ERR! npx canceled due to missing packages and no YES option: ["next@14.2.6"]"
** node version: v21.7.2
The text was updated successfully, but these errors were encountered: