Artifact files are created as truncated or partial files when the worker is termineated during a sync.
The termination (or restart) of the worker process can result in a truncated or partial artifact files being created by the file storage backend. Subsequent sync(s) will silently create an Artifact in the DB that references the broken file. The only way to fix the situation is to delete the file in /var/lib/pulp/artifact and the Artifact in the DB.
This can be most easily reproduced with large files and a slow filesystem.
The regression was introduced: https://github.com/pulp/pulp/pull/3178. The problem is in django FileSystemStorage.
Please register to edit this issue