Skip to content

query results: review follow-ups for #85 - #86

Merged
rahuldotiyer merged 1 commit into
query-latest-resultfrom
query-latest-result-review
Nov 30, 2026
Merged

rahuldotiyer merged 1 commit into
query-latest-resultfrom
query-latest-result-review

Conversation

@rahuldotiyer

Copy link
Copy Markdown
Contributor

Follow-ups from @norbertdurcansk's review on #85:

  • -o json now prints the result and still returns the error for a failed stored run, matching create-and-run.
  • When rows are withheld, the command prints the header and the notice without the empty table and 0 of 0 rows.

Tests cover both cases and fail without the fix. go test ./... passes.

@norbertdurcansk norbertdurcansk 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.

Approved. Both new assertions fail against the pre-fix code and pass with it, and the -o json path now matches create-and-run. One question inline.

Comment thread cmd/query/result_preview.go Resolved
@rahuldotiyer
rahuldotiyer merged commit da1b13c into query-latest-result Nov 30, 2026
6 checks passed
rahuldotiyer added a commit that referenced this pull request Nov 30, 2026
* Add dune query results for the MCP's getLatestQueryResult

core#8349/#8443 added getLatestQueryResult to the Dune MCP server: a saved
query's latest stored result, without running it. 'dune query results
<query-id>' calls it, shows when the run happened and its parameters, and
prints the tool's notice when no result is stored or rows are withheld for
licensed datasets. It goes through the MCP, not the REST results endpoint,
so the MCP's licensed-data withholding applies.

Co-authored-by: Amp <amp@ampcode.com>
Amp-Thread-ID: https://ampcode.com/threads/T-01a2147b-3c2e-76b3-aeaf-0aafbe53d879

* query results: fail -o json on a failed run, skip the empty table when rows are withheld (#86)

Amp-Thread-ID: https://ampcode.com/threads/T-01a2147b-3c2e-76b3-aeaf-0aafbe53d879

Co-authored-by: Amp <amp@ampcode.com>

---------

Co-authored-by: Amp <amp@ampcode.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.

2 participants