Skip to content
This repository was archived by the owner on Mar 6, 2026. It is now read-only.

Commit 7c060ea

Browse files
committed
Fix script runtime comparison error
1 parent ef5aa53 commit 7c060ea

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

tap_postgres/sync_strategies/logical_replication.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -432,7 +432,7 @@ def sync_tables(conn_info, logical_streams, state, end_lsn):
432432
keep_alive_time = 0.001
433433
begin_ts = datetime.datetime.now()
434434
add_tables = []
435-
max_run_time = conn_info['max_script_run_time'] or 1800 #max script run time for the extractor script
435+
max_run_time = int(conn_info['max_script_run_time'] or 1800) #max script run time for the extractor script
436436

437437
for s in logical_streams:
438438
sync_common.send_schema_message(s, ['lsn'])
@@ -501,7 +501,7 @@ def sync_tables(conn_info, logical_streams, state, end_lsn):
501501
state["lsn_to_flush"] = end_lsn
502502
break
503503

504-
script_run_time = (datetime.datetime.now() - START_TIME).total_seconds()
504+
script_run_time = int((datetime.datetime.now() - START_TIME).total_seconds())
505505
if script_run_time > max_run_time:
506506
if not last_lsn_processed:
507507
terminated_with_no_changes = True

0 commit comments

Comments
 (0)