You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I think that there is the need for a minimal change in media.py file or specify a new variable for the max_size parameter in media.prepare_image() and media.prepare_video() to mimic MediaRatios.reel and MediaRatios.standard.
At the moment an image with a good ratio, 1080:1920 is 0.5625, but it's resized because of the default max_size params has been set to (1080, 1350), instead it should be at least (1080, 1920) to support instagram stories.
Paste the output of python -V here: Python 3.7.1
Code:
# Example code that will produce the error reportedfrominstagram_web_api_extensionsimportmediaimg_path='image-story.jpg'eratio=MediaRatios.reelprint('ratio is: ', ratio)
image_data, image_size=media.prepare_image(img_path, aspect_ratios=ratio)
print('image size: {} with ratio of: {}'.format(image_size, image_size[0]/image_size[1]))
So what are your suggestions, create a new variable like MediaRatios to configure properly the size when prepare a media? Or just change that max_size=(1080, 1350) to a better max_size=(1080, 1920)?
However, thanks for your work ! :)
The text was updated successfully, but these errors were encountered:
Before submitting this issue I have:
Describe the Bug/Error:
It was referenced on b3nab/instapy-cli#37
I think that there is the need for a minimal change in media.py file or specify a new variable for the max_size parameter in media.prepare_image() and media.prepare_video() to mimic MediaRatios.reel and MediaRatios.standard.
At the moment an image with a good ratio, 1080:1920 is 0.5625, but it's resized because of the default max_size params has been set to
(1080, 1350)
, instead it should be at least(1080, 1920)
to support instagram stories.Paste the output of
python -V
here:Python 3.7.1
Code:
Error/Debug Log:
So what are your suggestions, create a new variable like MediaRatios to configure properly the size when prepare a media? Or just change that
max_size=(1080, 1350)
to a bettermax_size=(1080, 1920)
?However, thanks for your work ! :)
The text was updated successfully, but these errors were encountered: