Commit afa4fe8
committed
fix: remove artifact.file.close() that causes seek-of-closed-file error
The explicit close() on main_artifact.file broke the fallback path in
_process_metadata_batch, which calls artifact_to_metadata_artifact()
for the final batch — that function calls artifact.file.seek(0) on
the already-closed handle.
Removing the close is safe: the file handle is released when the
batch flushes and references are cleared. The temp file cleanup
(os.unlink) still happens immediately.
JIRA: PULP-15731 parent a92fa57 commit afa4fe8
1 file changed
Lines changed: 1 addition & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
142 | 142 | | |
143 | 143 | | |
144 | 144 | | |
145 | | - | |
| 145 | + | |
146 | 146 | | |
147 | 147 | | |
148 | | - | |
149 | 148 | | |
150 | 149 | | |
151 | 150 | | |
| |||
0 commit comments