nodeca / probe-image-size

Get image size without full download. Supported image types: JPG, GIF, PNG, WebP, BMP, TIFF, SVG, PSD, ICO.
MIT License
978 stars 77 forks source link

async probe hangs with json file #62

Closed danielberndt closed 3 years ago

danielberndt commented 3 years ago

Hello 👋,

I'm a happy user of this library but just observed something very unexpected:

calling probe(url) with e.g. this url containing a json will result in a never-resolving promise.

It seems to be the case that it hangs for any kind of json file. (even a file containing only {})

I've updated to 7.2.0 and could still observe this behaviour.

puzrin commented 3 years ago

Reproduced. Thanks.

node support/dump.js https://uploads-dev-codecks.s3.eu-central-1.amazonaws.com/_tmp/2021/UNtr66GG63/cdx-colors.json

Hangs for 30 sec. Not nice.

rlidwka commented 3 years ago

Fixed, thanks for reporting.

danielberndt commented 3 years ago

awesome! Thanks for the super quick fix 🎉

puzrin commented 3 years ago

published 7.2.1