Skip to content

Dune Go SDK client setup, plan init APP-7344#1

Merged
ivpusic merged 2 commits into
mainfrom
client_setup
Mar 3, 2026
Merged

Dune Go SDK client setup, plan init APP-7344#1
ivpusic merged 2 commits into
mainfrom
client_setup

Conversation

@ivpusic
Copy link
Copy Markdown
Member

@ivpusic ivpusic commented Mar 2, 2026

Dune Go SDK client setup, plan init

@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented Mar 2, 2026

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 6bc76b0 and 6dc3be3.

⛔ Files ignored due to path filters (1)
  • go.sum is excluded by !**/*.sum
📒 Files selected for processing (5)
  • config/config.go
  • go.mod
  • internal/cli/root.go
  • models/error.go
  • plan/query-commands.md
💤 Files with no reviewable changes (2)
  • models/error.go
  • config/config.go

📝 Walkthrough

Walkthrough

This pull request migrates the CLI from local configuration and error handling to an external duneapi-client-go SDK dependency. Configuration and error types are removed, dependencies are updated, and the command root is refactored to construct and use a Dune client instead of managing local environment configuration.

Changes

Cohort / File(s) Summary
Configuration Removal
config/config.go
Entire file deleted; removed DefaultHost constant, Env struct, FromEnvVars(), and FromAPIKey() functions along with internal environment variable helpers.
Error Model Removal
models/error.go
Entire file deleted; removed APIError struct and its Error() method.
SDK Integration
go.mod, internal/cli/root.go
Added direct dependency on github.com/duneanalytics/duneapi-client-go v0.4.0. Updated CLI root command to construct a DuneClient from SDK config and store it in context under clientKey instead of storing Env under envKey. Renamed public helper from EnvFromCmd to ClientFromCmd with updated return type.
Query Operations Documentation
plan/query-commands.md
Comprehensive update shifting to SDK-centric architecture. Documents new Query CRUD methods (CreateQuery, GetQuery, UpdateQuery, ArchiveQuery) and updated execution flow (RunQuery, QueryExecute, RunSQL) with corresponding request/response types (CreateQueryRequest, GetQueryResponse, ExecuteRequest, ExecuteSQLRequest) and new QueryParameter model. Outlines new file dune/query.go and updated DuneClient interface.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~12 minutes

Possibly related PRs

🚥 Pre-merge checks | ✅ 2 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 50.00% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (2 passed)
Check name Status Explanation
Title check ✅ Passed The title concisely describes the main change: introducing Dune Go SDK client setup and initializing the execution plan.
Description check ✅ Passed The description is minimal but directly related to the changeset, mentioning execution plan updates and SDK client setup.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

Warning

There were issues while running some tools. Please review the errors and either fix the tool's configuration or disable the tool if it's a critical failure.

🔧 golangci-lint (2.5.0)

Error: can't load config: unsupported version of the configuration: "" See https://golangci-lint.run/docs/product/migration-guide for migration instructions
The command is terminated due to an error: can't load config: unsupported version of the configuration: "" See https://golangci-lint.run/docs/product/migration-guide for migration instructions


Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link
Copy Markdown
Member Author

ivpusic commented Mar 2, 2026

@ivpusic ivpusic changed the title Update execution plan Dune Go SDK client setup, plan init Mar 3, 2026
@ivpusic ivpusic marked this pull request as ready for review March 3, 2026 08:38
@cursor
Copy link
Copy Markdown

cursor Bot commented Mar 3, 2026

PR Summary

Cursor Bugbot is generating a summary for commit 6dc3be3. Configure here.

@ivpusic ivpusic requested a review from va3093 March 3, 2026 08:39
@ivpusic ivpusic changed the title Dune Go SDK client setup, plan init Dune Go SDK client setup, plan init APP-7344 Mar 3, 2026
@linear
Copy link
Copy Markdown

linear Bot commented Mar 3, 2026

@ivpusic ivpusic merged commit d53e561 into main Mar 3, 2026
2 checks passed
This was referenced Mar 5, 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.

2 participants