Repository navigation
Conversation
Queries converted catalog flags, row locations, transaction IDs, and WAL positions to text. Decode binary with FromSql instead.
serprex
commented
Nov 26, 2026
|
|
||
| /// `"char"` column at `idx` | ||
| pub fn char_at(row: &Row, idx: usize) -> char { | ||
| char::from(row.get::<_, i8>(idx) as u8) |
Member
Author
There was a problem hiding this comment.
really we should just return u8 & compare throughout codebase with b'x', but that'll be a separate PR
There was a problem hiding this comment.
Auto-approved by the AI review gate on af60149. Details in the approver's comment on this pull request.
AI review gate — auto-approved
History (latest 5 heads, newest first)
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Queries converted catalog flags, row locations, transaction IDs, and WAL positions to text. Decode binary with FromSql instead.
Note
Medium Risk
Changes how replication-critical metadata (WAL LSN, xids, ctid slots, catalog flags) is read from PostgreSQL; behavior should match but regressions would affect seeding, filtering, and resume positions.
Overview
Sidecar SQL now returns PostgreSQL values in native binary types instead of
::textcasts followed by manual parsing.src/pg.rsadds shared decoding:char_atfor"char"columns,FromSqlforxid8andtid, plusnext_xidandcurrent_wal_lsn.RawAttr::build()no longer validates single-character strings—it assumes types already decoded aschar.Call sites across bootstrap, catalog tracker, filter engine, introspect/preflight, stream session, shadow catalog, and TOAST landing drop helpers like
one_char,parse_ctid, and LSN/xid text hacks. TOAST index lookup uses a boundoid[]parameter instead of interpolated SQL. Integration tests use genericFromSqlscalars andXid8where appropriate.Reviewed by Cursor Bugbot for commit af60149. Bugbot is set up for automated code reviews on this repo. Configure here.