Skip to content

Haskell acceptance tests and admin database parser changes - #1354

Merged
levkk merged 7 commits into
mainfrom
levkk-add-basic-haskell
Aug 13, 2026
Merged

Haskell acceptance tests and admin database parser changes#1354
levkk merged 7 commits into
mainfrom
levkk-add-basic-haskell

Conversation

@levkk

@levkk levkk commented Aug 12, 2026

Copy link
Copy Markdown
Collaborator

Tests

Added a short Haskell integration tests suite.

Admin database

Changed how we parse commands (and created a bit of a mess). We first attempt to detect SET and SHOW using the pg parser. If that fails, we fallback to string interpolation.

This allows us to respond to common commands executed by database drivers, e.g., SHOW server_version (which now returns the parser version we get from pg_raw_parse).

This also allows us to parse and respond to multi-statement SET queries, e.g.:

SET application_name TO 'persistent'; SET client_encoding TO 'utf8';

without those getting mangled by our "string parser". We don't do anything if we see a variable we don't recognize, by the way.

To add to the complexity, we have some commands that would match the show branch but not be valid SHOW commands, e.g., SHOW CLIENTS <column list>. Handling for these is duplicated because apparently that's the best I can come up with today.

@codecov

codecov Bot commented Aug 12, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 98.24561% with 2 lines in your changes missing coverage. Please review.

Files with missing lines Patch % Lines
pgdog/src/admin/show_guc.rs 85.71% 2 Missing ⚠️

📢 Thoughts on this report? Let us know!

@levkk
levkk force-pushed the levkk-add-basic-haskell branch from ab5cbbf to ef8678f Compare August 13, 2026 19:16
@levkk levkk changed the title feat: haskell acceptance tests Haskell acceptance tests and admin database parser changes Aug 13, 2026
@levkk
levkk marked this pull request as ready for review August 13, 2026 19:22
@levkk
levkk merged commit 4bafac9 into main Aug 13, 2026
29 checks passed
@levkk
levkk deleted the levkk-add-basic-haskell branch August 13, 2026 23:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant