question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Chokes on 512x512px image

See original GitHub issue

If it can’t downscale, it should fail with a user friendly exception (“Images larger than 256x256 px are not supported”).

$ file icon_512x512.png 
icon_512x512.png: PNG image data, 512 x 512, 8-bit/color RGBA, non-interlaced

$ node_modules/.bin/to-ico icon_512x512.png 
TypeError: "value" argument is out of bounds
    at checkInt (buffer.js:1040:11)
    at Buffer.writeUInt8 (buffer.js:1088:5)
    at createDirectory (node_modules/to-ico/index.js:32:6)
    at Promise.all.then.data (node_modules/to-ico/index.js:98:16)
    at process._tickCallback (internal/process/next_tick.js:103:7)

$ npm list | grep to-ico
└─┬ to-ico-cli@1.0.0
  └─┬ to-ico@1.1.3

Issue Analytics

  • State:open
  • Created 7 years ago
  • Reactions:2
  • Comments:6 (2 by maintainers)

github_iconTop GitHub Comments

1reaction
kevvacommented, Oct 18, 2017

@albinekb, I think the first step is to just resize the image to 256x256 if it’s larger. A PR would be greatly appreciated 👍.

0reactions
DanielRufcommented, Oct 11, 2019

Generally setting the option {resize: true} should prevent that.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Choking png images - PNGWing
Choking Chokehold Abdominal thrusts, Choking s, boy, fictional Character, ... heart attack, child, heart, first Aid Supplies png 512x512px 263.58KB ...
Read more >
Choking png images | PNGEgg
Choking Symbol Breathing First Aid Supplies Asphyxia, heart attack, child, heart png 512x512px 263.58KB; MikuMikuDance Upload, Choking, hand, ...
Read more >
Choking Pictures, Images and Stock Photos - iStock
Search from 7372 Choking stock photos, pictures and royalty-free images from iStock. Find high-quality stock photos that you won't find anywhere else.
Read more >
remy on Twitter: "I need the FASTEST way to draw an image() to a ...
I need the FASTEST way to draw an image() to a canvas. Using data uris are choking on base64 decoding. 90fps with 100x100...
Read more >
22830 Choke Images, Stock Photos & Vectors - Shutterstock
Find Choke stock images in HD and millions of other royalty-free stock photos, illustrations and vectors in the Shutterstock collection.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found