File tree Expand file tree Collapse file tree 4 files changed +21
-4
lines changed
Expand file tree Collapse file tree 4 files changed +21
-4
lines changed Original file line number Diff line number Diff line change @@ -16,3 +16,5 @@ __pycache__
1616
1717/org.md
1818/scratch. *
19+
20+ CLAUDE.md
Original file line number Diff line number Diff line change @@ -15,5 +15,5 @@ build-backend = "poetry.core.masonry.api"
1515[tool .pytest .ini_options ]
1616addopts = " -ra"
1717testpaths = [" tests" ]
18- timeout = 10
18+ timeout = 15
1919timeout_func_only = true
Original file line number Diff line number Diff line change 1+ {
2+ "venvPath" : " ." ,
3+ "venv" : " .venv" ,
4+ "extraPaths" : [" tests" ],
5+ "pythonVersion" : " 3.13" ,
6+ "typeCheckingMode" : " basic" ,
7+ "useLibraryCodeForTypes" : true
8+ }
Original file line number Diff line number Diff line change @@ -186,13 +186,20 @@ def wait_for_current_optime(self):
186186 status = self .pcsm .status ()
187187 assert status ["state" ] == PCSM .State .RUNNING , status
188188
189- curr_optime = self .source .server_info ()["$clusterTime" ]["clusterTime" ]
189+ result = self .source .admin .command (
190+ {"appendOplogNote" : 1 , "data" : {"msg" : "test:sync_point" }}
191+ )
192+ curr_optime = result ["$clusterTime" ]["clusterTime" ]
193+
190194 for _ in range (self .wait_timeout * 2 ):
191- if curr_optime <= self .last_applied_op :
195+ last_applied = self .last_applied_op
196+ if curr_optime <= last_applied :
197+ # Even though the oplog entry is replicated, PCSM may not have finished
198+ # writing to the target database. Add a small delay to ensure completion.
199+ time .sleep (0.3 )
192200 return
193201
194202 time .sleep (0.5 )
195- status = self .pcsm .status ()
196203
197204 raise WaitTimeoutError ()
198205
You can’t perform that action at this time.
0 commit comments