The Transkribus import can skip a folder when a different folder's name contains its name
Found while troubleshooting #175 (closed). When a folder already appears to be imported, it is entirely skipped. I didn't want to wait for the RQ worker to clean up the folder to restart the import to try a dumb workaround, so I just tried to rename the folder, but it didn't work. The code that checks for an existing folder relies on the name
filter of ListElements
, which is not name = 'thing'
but LOWER(name) LIKE LOWER('%thing%')
.
Let's say you have a Transkribus project, and the folders in it are named like so:
- Something
- Thing
- Some
The only folder that will be imported is Something
, and the other folders will be skipped, because Something
contains both Thing
and Some
(case-insensitive).
The Transkribus import should instead iterate over .paginate('ListElements', ...)
and look for any result whose name matches exactly the folder's name.