Artifacts locking based on CouchDB may fail if checkout takes too much time
A similar problem was observed for builds, but I just tried a checkout from scratch (which took ages to install the miniconda environment) and the checkout jobs failed because the connection to the database expired.
We need to rework https://gitlab.cern.ch/lhcb-core/nightly-builds/lb-nightly-scheduler/-/blob/86a6f24cee942634b797fd2b57eedda6200b907c/lb/nightly/scheduler/_types.py#L53-83 so that we re-connect before trying to delete the lock entry.
Edited by Maciej Pawel Szymanski