Skip to content

Commit 5dcfb40

Browse files
SwiftWing21claude
andcommitted
fix(ci): handle Windows SQLite WAL lock on test DB cleanup
test_comms.py tearDown: catch PermissionError on os.unlink — Windows holds WAL handles after SQLite close, causing WinError 32 in CI. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
1 parent 4c73e04 commit 5dcfb40

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

tests/test_comms.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,10 @@ def tearDown(self):
3030
except Exception:
3131
pass
3232
os.environ.pop("FLEET_TEST_DB", None)
33-
os.unlink(self.tmp.name)
33+
try:
34+
os.unlink(self.tmp.name)
35+
except PermissionError:
36+
pass # Windows: SQLite WAL may still hold the file
3437

3538

3639
class TestWrapMessage(CommsTestBase):

0 commit comments

Comments
 (0)