Skip to content

db client fixes - #206

Merged
jamie-at-bunny merged 10 commits into
mainfrom
db-client-fixes
Sep 2, 2026
Merged

db client fixes#206
jamie-at-bunny merged 10 commits into
mainfrom
db-client-fixes

Conversation

@jamie-at-bunny

Copy link
Copy Markdown
Member

No description provided.

@bunnynet-devops

Copy link
Copy Markdown

@codex review

@changeset-bot

changeset-bot Bot commented Sep 2, 2026

Copy link
Copy Markdown

🦋 Changeset detected

Latest commit: 38ee000

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 15 packages
Name Type
@bunny.net/database-client Patch
@bunny.net/cli Patch
@bunny.net/database-adapter Patch
@bunny.net/database-shell Patch
@bunny.net/database-studio Patch
@bunny.net/cli-darwin-arm64 Patch
@bunny.net/cli-darwin-x64 Patch
@bunny.net/cli-linux-arm64 Patch
@bunny.net/cli-linux-x64 Patch
@bunny.net/cli-windows-x64 Patch
@bunny.net/database-shell-darwin-arm64 Patch
@bunny.net/database-shell-darwin-x64 Patch
@bunny.net/database-shell-linux-arm64 Patch
@bunny.net/database-shell-linux-x64 Patch
@bunny.net/database-shell-windows-x64 Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@greptile-apps

greptile-apps Bot commented Sep 2, 2026

Copy link
Copy Markdown

Greptile Summary

This PR hardens the Bunny Database client and migration transaction behavior.

  • Adds configurable transaction modes, guarded rollback handling, transaction-statement validation, and batch failure indexing.
  • Normalizes timeout, transport, and malformed-protocol failures as DatabaseError.
  • Improves numeric binding and typed SQL-template behavior.
  • Applies migrations with BEGIN IMMEDIATE and updates package documentation, tests, and build configuration.

Confidence Score: 5/5

The PR appears safe to merge.

No blocking failure remains; the current constructor preserves both positional forms described in the previous threads, including calls with an omitted code and a supplied status.

Important Files Changed

Filename Overview
packages/database-client/src/client.ts Adds transaction modes, guarded batch rollback, statement validation, timeout validation, and normalized transport errors without leaving a blocking issue.
packages/database-client/src/errors.ts Extends structured error metadata while preserving both previously reported positional constructor forms.
packages/database-client/src/protocol.ts Adds protocol validation and revised numeric binding behavior without an eligible blocking follow-up finding.
packages/cli/src/commands/db/migrations/client.ts Requests an immediate transaction for migration batches to acquire the write lock up front.
packages/database-client/src/client.test.ts Expands coverage for batch modes, rollback guards, constructor compatibility, malformed responses, and typed SQL templates.

Reviews (4): Last reviewed commit: "fix(database-client): keep status when t..." | Re-trigger Greptile

Comment thread packages/database-client/src/errors.ts

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 8abb3e3dd5

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread packages/database-client/src/protocol.ts Outdated
Comment thread packages/database-client/src/errors.ts Outdated
Comment thread packages/database-client/src/client.ts Outdated
Comment thread packages/database-client/package.json
Comment thread packages/database-client/src/errors.ts
@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review Completed 2026-09-02T10:11:31.403657Z 8abb3e3 Manual request
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

Comment thread packages/database-client/src/client.ts Fixed
…r constructor compat, declared cause, and keyword scan
Comment thread packages/database-client/src/errors.ts Outdated
@jamie-at-bunny
jamie-at-bunny merged commit d6b68a7 into main Sep 2, 2026
6 checks passed
@jamie-at-bunny
jamie-at-bunny deleted the db-client-fixes branch September 2, 2026 11:01
@github-actions github-actions Bot mentioned this pull request Sep 2, 2026
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.

4 participants