It seems impossible to upload the jpeg versions of TIFFs using ignore_warnings set to ['exists-normalized']. This is when using site.upload() with the defaults and source_url correctly set, source_filename = None and chunk_size = 1048576.
Examining pywikibot.site, the upload function runs one-time but then falls over at
raise ValueError('Can request stash information only when 'using a file name.')as on the second pass offset is True.
I'd appreciate either a fix, or advice on how to work-around if this is a known error. I tried debugging this and working-around it for a while, but I find the design non-intuitive, so I may be missing the point of some part of it. It could be that the issue is how parameters get dropped/passed on (especially ignore_warnings) as it iterates, but I'm finding it hard to visualize.
As an example, in the NYPL I'm attempting to upload a jpeg when a TIFF exists under the same name:
- TIFF: File:Con razon ó sin ella (NYPL b14923839-1109923).tiff
- jpeg: File:Con razon ó sin ella (NYPL b14923839-1109923).jpg
- NYPL source for jpeg: source_url = http://images.nypl.org/index.php?id=1109923&t=g&download=1&suffix=510d47dc-8968-a3d9-e040-e00a18064a99.001