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

Added images #16

Merged
merged 3 commits into from
Jan 11, 2019
Merged

Added images #16

merged 3 commits into from
Jan 11, 2019

Conversation

bitofbreeze
Copy link
Contributor

I needed access to image thumbnails for my use case, so I added them with not too much work. Hope this helps!

@bitofbreeze bitofbreeze mentioned this pull request Jan 11, 2019
@coveralls
Copy link

Pull Request Test Coverage Report for Build 192

  • 6 of 6 (100.0%) changed or added relevant lines in 1 file are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage increased (+0.05%) to 98.773%

Totals Coverage Status
Change from base Build 182: 0.05%
Covered Lines: 161
Relevant Lines: 163

💛 - Coveralls

@tducret
Copy link
Owner

tducret commented Jan 11, 2019

Thank you very much for your help @CSFlorin !
I am making a few adjustments since I am sometimes getting image url with : data:image/webp;base64,UklGR[...many many characters]
I'll commit it soon.
I'll also implement a few tweak in the url to get an higher resolution image (as suggested by @DiReKToRje in issue #10)

@bitofbreeze
Copy link
Contributor Author

Sounds good! I think Amazon may just be a bit disorganized when giving the base64-encoded version or a url to the actual source.

That resizing thing is interesting. You can enter any dimension at the end and there are keys like US and QL to change the aspect ratio. They also seem to have some predefined sizes on the page as can be seen below from the first entry on this page.

<img src="https://images-na.ssl-images-amazon.com/images/I/514PIKUKSnL._AC_US218_.jpg" srcset="https://images-na.ssl-images-amazon.com/images/I/514PIKUKSnL._AC_US218_.jpg 1x, https://images-na.ssl-images-amazon.com/images/I/514PIKUKSnL._AC_US327_FMwebp_QL65_.jpg 1.5x, https://images-na.ssl-images-amazon.com/images/I/514PIKUKSnL._AC_US436_FMwebp_QL65_.jpg 2x, https://images-na.ssl-images-amazon.com/images/I/514PIKUKSnL._AC_US500_FMwebp_QL65_.jpg 2.2935x" width="218" height="218" alt="Coca-Cola, 7.5 fluid Ounces, 6 Pack" class="s-access-image cfMarker" data-search-image-load="">

@tducret tducret mentioned this pull request Jan 11, 2019
@tducret tducret merged commit 31e5684 into tducret:master Jan 11, 2019
@tducret
Copy link
Owner

tducret commented Jan 11, 2019

#17 closes this issue

@tducret
Copy link
Owner

tducret commented Jan 11, 2019

Everything is now in order :)
You may upgrade the pip package and docker image.

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

Successfully merging this pull request may close these issues.

None yet

3 participants