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

Inaccurate (zero) size reported for some images #243

Open
martinkrcho opened this issue Aug 14, 2023 · 0 comments
Open

Inaccurate (zero) size reported for some images #243

martinkrcho opened this issue Aug 14, 2023 · 0 comments

Comments

@martinkrcho
Copy link

I am using perfume.js to collect information about images loaded on a website. Sometimes perfume.js reports image with 0 size -
decodedBodySize, encodedBodySize and also transferSize have all value 0.

Strangely, the Network tab in the Chrome Dev Console shows correct image sizes, as expected.

I am getting similar results with lazy loading enabled and disabled.

Have you seen this behaviour somewhere else? Do you know what's causing it?

Below is the full list of images and their size as reported by perfume.js.

Size Image URL
272359 https://my.site/wp-content/uploads/2023/08/vertopal.com_bogomil-mihaylov-i-IIU6gqHgo-unsplash-progressive-scaled.jpeg
0 https://images.rawpixel.com/image_1300/czNmcy1wcml2YXRlL3Jhd3BpeGVsX2ltYWdlcy93ZWJzaXRlX2NvbnRlbnQvbHIvZnJsYWtlX3dhdGVyX2xhbmRzY2FwZV9uYXR1cmVfMC1pbWFnZS1reWJkYzBxNS5qcGc.jpg
0 https://images.rawpixel.com/image_1300/cHJpdmF0ZS9zdGF0aWMvaW1hZ2Uvd2Vic2l0ZS8yMDIyLTA0L2xyL2ZycGF0aF90cmFpbF9hdWJyYWNfbW91bnRhaW4taW1hZ2Uta3liZDFveWYuanBn.jpg
48488 https://my.site/wp-content/uploads/2023/08/sleepy-purrito-progressive-1.jpeg.webp
0 https://images.rawpixel.com/image_1300/czNmcy1wcml2YXRlL3Jhd3BpeGVsX2ltYWdlcy93ZWJzaXRlX2NvbnRlbnQvbHIvZnJtb3VudGFpbnNfbmF0dXJhbF93b25kZXJmdWxfdmlldy1pbWFnZS1reWJkNmIwcS5qcGc.jpg
0 https://s.w.org/images/core/5.8/outside-02.jpg
0 https://s.w.org/images/core/5.8/outside-01.jpg
0 https://s.w.org/images/core/5.8/outside-03.jpg
110666 https://my.site/wp-content/uploads/2023/08/hvneoufseno.jpg.webp
62696 https://my.site/wp-content/uploads/2023/08/b3a3ryz1apk.jpg.webp
122400 https://my.site/wp-content/uploads/2023/08/niivykobcmu.jpg.webp
52344 https://my.site/wp-content/uploads/2023/08/xykvsjpqjzq.jpg.webp
0 https://pd.w.org/2022/01/84661f60659149cc8.02053291.jpg
0 https://pd.w.org/2022/01/21261f60ba46147b0.97888240.jpg
214933 https://img.rawpixel.com/s3fs-private/rawpixel_images/website_content/a019-jakubk-0393-pasta-asparagus.jpg?w=1200&h=1200&fit=clip&crop=default&dpr=1&q=75&vib=3&con=3&usm=15&cs=srgb&bg=F4F4F3&ixlib=js-2.2.1&s=7104f38452e51828c7f5c2a0d271922b
0 https://img.rawpixel.com/s3fs-private/rawpixel_images/website_content/a019-jakubk-0833-pasta-fusilli-prepared-for-cooking1.jpg?w=1200&h=1200&fit=clip&crop=default&dpr=1&q=75&vib=3&con=3&usm=15&cs=srgb&bg=F4F4F3&ixlib=js-2.2.1&s=6d8bcb2358053bd60bf1e0534bb31e14
0 https://img.rawpixel.com/s3fs-private/rawpixel_images/website_content/a019-jakubk-0406-foodiesfeed.com-pasta-photos-circles-3_low.jpg?w=1200&h=1200&fit=clip&crop=default&dpr=1&q=75&vib=3&con=3&usm=15&cs=srgb&bg=F4F4F3&ixlib=js-2.2.1&s=923b1e445174df1e101aaa5314393ee6
192641 https://img.rawpixel.com/s3fs-private/rawpixel_images/website_content/-a010-markuss-0545.jpg?w=1200&h=1200&fit=clip&crop=default&dpr=1&q=75&vib=3&con=3&usm=15&cs=srgb&bg=F4F4F3&ixlib=js-2.2.1&s=47aed21aad8fdf21db7ae586463b6373
306719 https://img.rawpixel.com/s3fs-private/rawpixel_images/website_content/a019-jakubk-0919-pasta-fusilli-prepared-for-cooking.jpg?w=1200&h=1200&fit=clip&crop=default&dpr=1&q=75&vib=3&con=3&usm=15&cs=srgb&bg=F4F4F3&ixlib=js-2.2.1&s=3777c35a83e6ac39e3505822fe2222e5
254318 https://img.rawpixel.com/s3fs-private/rawpixel_images/website_content/a019-jakubk-0875-pork-meat-with-green-vegetables.jpg?w=1200&h=1200&fit=clip&crop=default&dpr=1&q=75&vib=3&con=3&usm=15&cs=srgb&bg=F4F4F3&ixlib=js-2.2.1&s=5b12921f1ab9aea3b3fd4b63b824f08f
280162 https://img.rawpixel.com/s3fs-private/rawpixel_images/website_content/a019-jakubk-0943-pasta-tagliatelle-asparagus-tomatoes.jpg?w=1200&h=1200&fit=clip&crop=default&dpr=1&q=75&vib=3&con=3&usm=15&cs=srgb&bg=F4F4F3&ixlib=js-2.2.1&s=59f8072cca902a42d5bee6031e0795e1
147826 https://img.rawpixel.com/s3fs-private/rawpixel_images/website_content/a019-jakubk-0868-autumn-relax-with-waffle-and-coffee2.jpg?w=1200&h=1200&fit=clip&crop=default&dpr=1&q=75&vib=3&con=3&usm=15&cs=srgb&bg=F4F4F3&ixlib=js-2.2.1&s=67ab828e02cc115c6bb5e6e4c7c5af72
235220 https://img.rawpixel.com/s3fs-private/rawpixel_images/website_content/a019-jakubk-0888-pork-meat-with-green-vegetables1.jpg?w=1200&h=1200&fit=clip&crop=default&dpr=1&q=75&vib=3&con=3&usm=15&cs=srgb&bg=F4F4F3&ixlib=js-2.2.1&s=90c983931009e59c3c9aea520823c808
155887 https://img.rawpixel.com/s3fs-private/rawpixel_images/website_content/a019-jakubk-0684-bread-with-butter1.jpg?w=1200&h=1200&fit=clip&crop=default&dpr=1&q=75&vib=3&con=3&usm=15&cs=srgb&bg=F4F4F3&ixlib=js-2.2.1&s=f34e6dc09a162d26890da86377704c39
117126 https://img.rawpixel.com/s3fs-private/rawpixel_images/website_content/a010-markusspiske-oct18-033.jpg?w=1200&h=1200&fit=clip&crop=default&dpr=1&q=75&vib=3&con=3&usm=15&cs=srgb&bg=F4F4F3&ixlib=js-2.2.1&s=70487222d70c25760a26b47da2d91646
117126 https://img.rawpixel.com/s3fs-private/rawpixel_images/website_content/a010-markusspiske-oct18-033.jpg?w=1200&h=1200&fit=clip&crop=default&dpr=1&q=75&vib=3&con=3&usm=15&cs=srgb&bg=F4F4F3&ixlib=js-2.2.1&s=70487222d70c25760a26b47da2d91646
120970 https://img.rawpixel.com/s3fs-private/rawpixel_images/website_content/-a010-markuss-0159.jpg?w=1200&h=1200&fit=clip&crop=default&dpr=1&q=75&vib=3&con=3&usm=15&cs=srgb&bg=F4F4F3&ixlib=js-2.2.1&s=70ee16211abf08751df43d4ef96d2cbb
214985 https://img.rawpixel.com/s3fs-private/rawpixel_images/website_content/-a010-markuss-0308.jpg?w=1200&h=1200&fit=clip&crop=default&dpr=1&q=75&vib=3&con=3&usm=15&cs=srgb&bg=F4F4F3&ixlib=js-2.2.1&s=40111256e224ac932f446f66d9236129
147988 https://img.rawpixel.com/s3fs-private/rawpixel_images/website_content/-a010-markuss-0158.jpg?w=1200&h=1200&fit=clip&crop=default&dpr=1&q=75&vib=3&con=3&usm=15&cs=srgb&bg=F4F4F3&ixlib=js-2.2.1&s=81db7591c3f006b266037d363ff339d9
67532 https://my.site/wp-content/uploads/2023/08/8154069.jpg
189174 https://my.site/wp-content/uploads/2023/08/8mqow4dbbsg.jpg
0 https://s.w.org/patterns/files/2021/06/Mount-Fuji-From-Hakone-Hiroaki-Takahashi-scaled.jpg
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant