valhallasw added a comment.
I tried the following...
# this image is https://flic.kr/p/t2nWxA wget https://farm9.staticflickr.com/8880/17737230072_d678b9f089_o_d.jpg
# then python pwb.py shell
and then in the python shell
import pywikibot site = pywikibot.Site('commons', 'commons') site.login() # site.upload does not do this itself for some reason site.upload(pywikibot.FilePage(site, "File:Ryanair, EI-DWP, Boeing 737-8AS (17737230072).jpg"), source_filename="17737230072_d678b9f089_o_d.jpg", comment="Testing [[phab:T99366]] / [[Commons:Bots|Bot]]: Uploading files from Flickr", ignore_warnings=False)
which allows me to reproduce the issue -- in Python 2, at least. In Python 3, the upload magically works: https://commons.wikimedia.org/wiki/File:Ryanair,_EI-DWP,_Boeing_737-8AS_(177...
TASK DETAIL https://phabricator.wikimedia.org/T99366
EMAIL PREFERENCES https://phabricator.wikimedia.org/settings/panel/emailpreferences/
To: zhuyifei1999, valhallasw Cc: valhallasw, XZise, Aklapper, zhuyifei1999, jayvdb, pywikipedia-bugs