Conversation
Detect PostgreSQL command tags (INSERT, UPDATE, DELETE, CREATE TABLE, etc.)
in parseCSVToQueryResult instead of misinterpreting them as CSV headers.
JSON mode now outputs { columns, rows, rowCount, commandTag } instead of
just the rows array.
📝 WalkthroughWalkthroughVersion 0.47.14 release modifying JSON output semantics for Changes
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~25 minutes Poem
🚥 Pre-merge checks | ✅ 2 | ❌ 1❌ Failed checks (1 inconclusive)
✅ Passed checks (2 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Inline comments:
In `@CLAUDE.md`:
- Around line 231-235: The docs claim that `spindb create` provisions
engine-specific credentials (e.g., MongoDB admin user, QuestDB creds) but the
code paths (the engine startup/load routines for MongoDB and QuestDB) only load
configs at start and do not provision during `create`; either update the
CLAUDE.md section to state this is planned work (remove/annotate the claim about
create-time provisioning and SETUP_FIRST_ENGINES removal) or implement actual
provisioning in the CLI: add create-time handlers invoked by `spindb create`
that write MongoDB admin credentials and QuestDB config files (matching the
formats used by the startup code) so that `spindb start` can read them
immediately; reference the `spindb create`/`spindb start` commands and the
SETUP_FIRST_ENGINES behavior when making the doc or code change.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
Run ID: af989e2b-f1ce-4532-a11e-901c620dd6b7
📒 Files selected for processing (6)
CHANGELOG.mdCLAUDE.mdcli/commands/query.tscore/query-parser.tspackage.jsontypes/index.ts
| **Current state:** `spindb create` + `spindb start` are separate steps. Some engines (SurrealDB, InfluxDB, Weaviate, MongoDB, QuestDB) need config files (credential files, admin tokens, auth env) written BEFORE the first `start`. Layerbase Cloud's `setup-database.sh` fills this gap via `SETUP_FIRST_ENGINES`. | ||
|
|
||
| **Target:** `spindb create --username X --password Y` writes all engine-specific config files during create (admin-token.json for InfluxDB, weaviate.env for Weaviate, `--user/--pass` persistence for SurrealDB). Then `spindb start` reads the config and works correctly from the first call. | ||
| **Target:** `spindb create --username X --password Y` writes all engine-specific config files during create (admin-token.json for InfluxDB, weaviate.env for Weaviate, `--user/--pass` persistence for SurrealDB, admin user for MongoDB). Then `spindb start` reads the config and works correctly from the first call. | ||
|
|
||
| **Impact:** Eliminates `SETUP_FIRST_ENGINES` / `setupHandlesStart` in Layerbase Cloud. Simplifies `setup-database.sh` to just `spindb create --username X --password Y --bind 127.0.0.1` + health check. | ||
| **Impact:** Eliminates `SETUP_FIRST_ENGINES` in Layerbase Cloud. Simplifies `setup-database.sh` to just `spindb create --username X --password Y --bind 127.0.0.1` + health check. |
There was a problem hiding this comment.
Doc behavior does not match current MongoDB/QuestDB implementation
This section states create-time credential/config provisioning (including MongoDB admin user creation) as current/target behavior, but the referenced engine code paths only show credential loading and startup, not provisioning during create. Please either update docs to mark this as planned work or land the implementation before documenting it as expected behavior.
Suggested doc correction
-**Current state:** `spindb create` + `spindb start` are separate steps. Some engines (SurrealDB, InfluxDB, Weaviate, MongoDB, QuestDB) need config files (credential files, admin tokens, auth env) written BEFORE the first `start`. Layerbase Cloud's `setup-database.sh` fills this gap via `SETUP_FIRST_ENGINES`.
+**Current state:** `spindb create` + `spindb start` are separate steps. Some engines (SurrealDB, InfluxDB, Weaviate) need config files (credential files, admin tokens, auth env) written BEFORE the first `start`. MongoDB and QuestDB currently load saved/default credentials during runtime but do not yet provision create-time auth artifacts. Layerbase Cloud's `setup-database.sh` fills this gap via `SETUP_FIRST_ENGINES`.
-**Target:** `spindb create --username X --password Y` writes all engine-specific config files during create (admin-token.json for InfluxDB, weaviate.env for Weaviate, `--user/--pass` persistence for SurrealDB, admin user for MongoDB). Then `spindb start` reads the config and works correctly from the first call.
+**Target:** `spindb create --username X --password Y` writes all engine-specific config files during create (admin-token.json for InfluxDB, weaviate.env for Weaviate, `--user/--pass` persistence for SurrealDB, and planned MongoDB/QuestDB create-time auth provisioning). Then `spindb start` reads the config and works correctly from the first call.🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.
In `@CLAUDE.md` around lines 231 - 235, The docs claim that `spindb create`
provisions engine-specific credentials (e.g., MongoDB admin user, QuestDB creds)
but the code paths (the engine startup/load routines for MongoDB and QuestDB)
only load configs at start and do not provision during `create`; either update
the CLAUDE.md section to state this is planned work (remove/annotate the claim
about create-time provisioning and SETUP_FIRST_ENGINES removal) or implement
actual provisioning in the CLI: add create-time handlers invoked by `spindb
create` that write MongoDB admin credentials and QuestDB config files (matching
the formats used by the startup code) so that `spindb start` can read them
immediately; reference the `spindb create`/`spindb start` commands and the
SETUP_FIRST_ENGINES behavior when making the doc or code change.
Summary by CodeRabbit
Bug Fixes
spindb query --jsonoutput to return the complete result object (columns, rows, rowCount, commandTag) instead of only rows.Chores