Repository navigation
Conversation
A partitioned parent's SET TABLESPACE only sets the default for later partitions; "executed" alone read as if the table moved.
Codex Review Summary: ❌ FailedThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
|
🤖 Review 1/2 (correctness) of 19679f7: 1 blocking, 1 non-blocking. Inspected the whole change at CI at the time of posting: The change is correct as written. The field is set only when the planner routed a Invariants ( Blocking
Failing test, from the CI run at 19679f7 (not run here)The test is the one already in the repository; the job log of The diff that clears it: -...|TestMigrateSetTablespaceOnAPartitionedParentMovesNoPartition|...
+...|TestMigrateForcedSetTablespaceOnAnOrdinaryTableCarriesNoPartitionDefault|TestMigrateSetTablespaceOnAPartitionedParentMovesNoPartition|...Non-blocking
Test case: a plan with no tablespace decision leaves the verdict alone (not run)func TestDescribeParentTablespaceLeavesAnOrdinaryVerdictAlone(t *testing.T) {
plan, err := planner.Classify("ALTER TABLE app.events ADD COLUMN note text",
planner.Facts{Storage: planner.StorageHeap})
require.NoError(t, err)
v := verdict.Verdict{Outcome: verdict.OutcomeExecuted, Detail: "committed within budgets"}
describeParentTablespace(&v, plan)
assert.Empty(t, v.PartitionDefaultTablespace)
assert.Equal(t, "committed within budgets", v.Detail)
}I did not run it: the PR's own unit job shows Verified
This review was generated by Claude Code (claude-sonnet-5-5). |
|
🤖 Review 2/2 (OSS adoption and integration) of 19679f7: 0 blocking, 2 non-blocking. The PR-wide count is 1 blocking (the red Read the change from two seats: a host such as SchemaBot that decodes the verdict JSON and records what an apply did, and an operator or contributor who reads the verdict's Non-blocking
What reads well for adopters
This review was generated by Claude Code (claude-sonnet-5-5). |
aparajon
left a comment
There was a problem hiding this comment.
🤖 Stamping with comments: 1 blocking, 3 non-blocking (see the review comments above). The blocking one is the red test-own-server list: the new test needs adding to the -run list in the Makefile so the unit job and the PostgreSQL legs go green.
This stamp was left by Claude Code (claude-sonnet-5-5).
|
🤖 One CI blocker on The new forced plain-table control calls The full diff carries the planner's native partitioned-parent decision into the executed verdict and uses identifier quoting at the output boundary. The parent integration assertions check existing storage before and after, while the new control checks the heap move and omitted field. Review based on the full GitHub diff, PR discussion and reported checks. Builderbot and inline review threads were unavailable. I did not run tests locally. |
JashLal
left a comment
There was a problem hiding this comment.
🤖 Approved by Jash’s AI agent after reviewing 19679f7. The findings and verification limits in the review comment still apply.
The verdict for a partitioned table's
SET TABLESPACEnow carriespartition_default_tablespaceand says that no existing partition or index was moved.Why
On an ordinary table,
SET TABLESPACEmoves the table's data to another storage location. On a partitioned table it only records where partitions created later will go; every existing partition stays where it was. pg-sprite reported both as a plain "executed", so an operator or a host reading the verdict could think the data had moved when it had not.What
planner.DecisiongainsPartitionDefaultTablespace(not in the plan report). It is set only for a partitioned parent on the native route.verdict.Verdictgainspartition_default_tablespace(quoted identifier, omitted when empty).describeParentTablespacesets it on the executed verdict and adds to the detail: the parent now records the tablespace for partitions created later, and no existing partition or index was moved.format_version, and the plan report is unchanged.docs/schemabot-integration.mdand the partitioned-parentSET TABLESPACErow indocs/capabilities.mdandpkg/capabilities/capabilities.yaml.events_2024stays in its tablespace (reltablespace = 0). It fails without the change.SET TABLESPACEon a plain table, which moves the table and carries no field.Before / after
eventsis partitioned and has partitionevents_2024; the run sets its tablespace toarchive.