Hi

I noticed an incorrect comment in report_sequence_errors() in sequencesync.c.

The function comment describes case (c) as:

```
* c) missing sequences on the subscriber
```

However, the actual warning message emitted and the logic that
populates missing_seqs_idx both refer to sequences that are missing on
the publisher side, not the subscriber.

The fix is to replace "subscriber" with "publisher" in that comment line.

Thanks
Imran Zaheer
From 9836e8db869932fab8aabbbe5211a54676287bc2 Mon Sep 17 00:00:00 2001
From: Imran Zaheer <[email protected]>
Date: Sun, 7 Jun 2026 19:07:56 +0500
Subject: [PATCH v1] Fix wrong comment in report_sequence_errors()

The comment described case (c) as "missing sequences on the subscriber",
but the actual warning message and the logic that populates
missing_seqs_idx both refer to sequences missing on the publisher side.

Correct the comment to say "missing sequences on the publisher".
---
 src/backend/replication/logical/sequencesync.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/backend/replication/logical/sequencesync.c b/src/backend/replication/logical/sequencesync.c
index e2ff8d77b16..3046f4d6d96 100644
--- a/src/backend/replication/logical/sequencesync.c
+++ b/src/backend/replication/logical/sequencesync.c
@@ -167,7 +167,7 @@ get_sequences_string(List *seqindexes, StringInfo buf)
  * the publisher and subscriber. Emits warnings for:
  * a) mismatched definitions or concurrent rename
  * b) insufficient privileges
- * c) missing sequences on the subscriber
+ * c) missing sequences on the publisher
  * Then raises an ERROR to indicate synchronization failure.
  */
 static void
-- 
2.34.1

Reply via email to