Skip to content

fix(notebooks): return caller errors for client-caused notebook refusals - #512

Merged
Rodriguespn merged 4 commits into
mainfrom
fix/delete-notebook-caller-error
Nov 4, 2026
Merged

Rodriguespn merged 4 commits into
mainfrom
fix/delete-notebook-caller-error

Conversation

@Rodriguespn

@Rodriguespn Rodriguespn commented Nov 3, 2026 •

Copy link
Copy Markdown
Contributor

Client-caused notebook refusals were plain Errors, so hosts kept their traces as server faults (AI-1356). These are now ToolCallerErrors:

  • run_notebook when expected_updated_at doesn't match the notebook.
  • run_notebook with mutating cells, and delete_notebook, from a client without form elicitation.
  • A 4xx from the Management API v2, like notebook_disabled or a missing notebook. This also covers get_advisors(type: 'health'), which uses the same v2 client. A 429 or 5xx stays a plain Error, since a 429 can come from our own request volume.

Messages don't change.

Requested in review of supabase/platform#38799.

@Rodriguespn
Rodriguespn requested a review from a team as a code owner November 3, 2026 16:13
@Rodriguespn Rodriguespn changed the title fix(notebooks): return a caller error when delete_notebook can't confirm fix(notebooks): return caller errors for client-caused notebook refusals Nov 3, 2026
@coveralls

coveralls commented Nov 3, 2026 •

Copy link
Copy Markdown

Coverage Report for CI Build 41837374461

Coverage increased (+0.003%) to 97.698%

Details

  • Coverage increased (+0.003%) from the base build.
  • Patch coverage: 8 of 8 lines across 2 files are fully covered (100%).
  • No coverage regressions found.

Uncovered Changes

No uncovered changes found.

Coverage Regressions

No coverage regressions found.


Coverage Stats

Coverage Status
Relevant Lines: 5919
Covered Lines: 5813
Line Coverage: 98.21%
Relevant Branches: 1161
Covered Branches: 1104
Branch Coverage: 95.09%
Branches in Coverage %: Yes
Coverage Strength: 173.44 hits per line

💛 - Coveralls

@barryroodt barryroodt left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Thanks Pedro, looks good! I've left two non-blocking nits inline.

@Rodriguespn
Rodriguespn force-pushed the fix/delete-notebook-caller-error branch from 5d00844 to 864b938 Compare November 4, 2026 12:55
Rodriguespn and others added 4 commits November 4, 2026 13:21
A client without form elicitation causes this refusal, so it is a ToolCallerError and hosts sample its trace instead of keeping it as a server fault.
…_notebook errors

A stale expected_updated_at and a non-form client on a mutating notebook are
the caller's errors, so hosted samples their traces instead of keeping them.

Refs AI-1356

Co-authored-by: Claude Opus 5.5 <[email protected]>
…I v2 errors

A 4xx from a v2 endpoint, like notebook_disabled when notebooks aren't enabled
for the account, is the caller's error, so hosted samples its trace. 5xx and
unparsable responses stay plain Error.

Refs AI-1356

Co-authored-by: Claude Opus 5.5 <[email protected]>
@Rodriguespn
Rodriguespn force-pushed the fix/delete-notebook-caller-error branch from 864b938 to 7aedc08 Compare November 4, 2026 13:21
@Rodriguespn
Rodriguespn merged commit 5f0d393 into main Nov 4, 2026
5 checks passed
@supabase-releaser supabase-releaser Bot mentioned this pull request Nov 4, 2026
barryroodt pushed a commit that referenced this pull request Nov 5, 2026
🤖 I have created a release *beep* *boop*
---


<details><summary>mcp-server-supabase: 0.16.0</summary>

##
[0.16.0](mcp-server-supabase-v0.15.0...mcp-server-supabase-v0.16.0)
(2026-11-05)


### Features

* bound run_notebook cost
([#511](#511))
([e90d110](e90d110))
* **mcp-server-supabase:** run selected notebook cells
([#514](#514))
([8d04248](8d04248))
* **notebooks:** add delete_notebook tool with elicitation confirmation
([#510](#510))
([f36f74a](f36f74a))
* **notebooks:** enable create_notebook and run_notebook tools
([#509](#509))
([addc4e5](addc4e5))


### Bug Fixes

* **feedback:** accept null project_id and surface the feedback length
limit ([#521](#521))
([994f56c](994f56c))
* hint agents to re-copy malformed project refs
([#522](#522))
([0c650bf](0c650bf))
* **notebooks:** return caller errors for client-caused notebook
refusals ([#512](#512))
([5f0d393](5f0d393))
* **pg-meta:** report partition FKs once and add partition_of to
list_tables ([#508](#508))
([2c7fa82](2c7fa82))
* **pg-meta:** return complete check expressions for NOT VALID and NO
INHERIT constraints ([#517](#517))
([c54bb40](c54bb40))
* **sql:** skip destructive confirmation for planner-only EXPLAIN
([#519](#519))
([95745e5](95745e5))
* tolerate non-URL edge function paths in api platform
([#438](#438))
([00d07a4](00d07a4))
</details>

---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See
[documentation](https://github.com/googleapis/release-please#release-please).

Co-authored-by: supabase-releaser[bot] <223506987+supabase-releaser[bot]@users.noreply.github.com>
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.

3 participants