Skip to content

Commit

Permalink
Fix for flaky test_pause_on_disk_full
Browse files Browse the repository at this point in the history
  • Loading branch information
alexole committed Aug 19, 2022
1 parent 55a4886 commit 7e713c6
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions test/util.py
Expand Up @@ -31,4 +31,9 @@ def switch_wal(connection):
cur.execute("SELECT pg_switch_wal()")
else:
cur.execute("SELECT pg_switch_xlog()")
# This should fix flaky tests, which expect a specific number of WAL files which never arrive.
# Quite often the last WAL would not be finalized by walreceiver unless there is some extra activity after
# switching, the bug should be fixed in PG 15
# https://github.com/postgres/postgres/commit/596ba75cb11173a528c6b6ec0142a282e42b69ec
cur.execute("SELECT txid_current()")
cur.close()

0 comments on commit 7e713c6

Please sign in to comment.