Skip to content

feat(go-sdk): use generic methods starting Go 1.27 - #4645

Open
mnafees wants to merge 4 commits into
mainfrom
nafees/go-sdk-go127
Open

mnafees wants to merge 4 commits into
mainfrom
nafees/go-sdk-go127

Conversation

@mnafees

@mnafees mnafees commented Aug 9, 2026 •

Copy link
Copy Markdown
Member

Description

Start using generic methods starting from Go 1.27 in SDK runnables.

Type of change

  • New feature (non-breaking change which adds functionality)

Checklist

Changes have been:

  • Tested (unit, integration, or manually with steps specified)
  • Linted and formatted

🤖 AI Disclosure

No AI

@mnafees mnafees self-assigned this Aug 9, 2026
@mnafees mnafees added the sdk-go Related to the Go SDK label Aug 9, 2026
@vercel

vercel Bot commented Aug 9, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
hatchet-docs Ready Ready Preview Aug 31, 2026 1:06pm

Request Review

@mnafees mnafees changed the title feat: use generic methods starting Go 1.27 for Go SDK feat(go-sdk): use generic methods starting Go 1.27 Aug 30, 2026
@mnafees
mnafees marked this pull request as ready for review August 30, 2026 23:35
@greptile-apps

greptile-apps Bot commented Aug 30, 2026

Copy link
Copy Markdown
Contributor

Greptile Summary

This PR introduces build-tagged generic Go 1.27 task constructors while retaining reflection-based constructors for earlier toolchains, and simplifies internal declaration invocation.

  • Adds typed workflow, durable, and standalone task constructors for Go 1.27.
  • Moves pre-Go-1.27 reflection-based constructors into fallback files.
  • Replaces reflective declaration calls with typed wrappers.
  • Simplifies standalone option splitting and failure-handler wrapping.

Confidence Score: 4/5

The PR should not merge until OnFailure either rejects durable context handlers or restores conversion to the accepted context type; the SDK release metadata and comments also need non-blocking cleanup.

OnFailure validation still admits DurableContext handlers, but the changed invocation supplies a plain Context and will panic when such a failure handler runs; the remaining findings concern required release metadata and repository comment conventions.

Files Needing Attention: sdks/go/workflow.go, sdks/go/task_constructors_go127.go

Reviews (1): Last reviewed commit: "bad main merge" | Re-trigger Greptile

Comment thread sdks/go/workflow.go Outdated
Comment thread sdks/go/task_constructors_go127.go
Comment thread sdks/go/task_constructors_go127.go Outdated
@github-actions github-actions Bot added documentation Improvements or additions to documentation github_actions Pull requests that update GitHub Actions code engine Related to the core Hatchet engine labels Aug 31, 2026
@github-actions

Copy link
Copy Markdown
Contributor

⚠️ Optional test failure: The load-deadlock job failed on this PR (optimistic-scheduling=true). This check is non-mandatory and does not block merging, but may be worth investigating. View logs

This branch was successfully deployed

1 active deployment
Preview — 70f95f00 Deployed Aug 31, 2026 by vercel[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Improvements or additions to documentation engine Related to the core Hatchet engine github_actions Pull requests that update GitHub Actions code sdk-go Related to the Go SDK

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant