Skip to content

feat: add WithInvocationID run option#815

Open
quoral wants to merge 1 commit into
google:mainfrom
freda-ab:with-invocation-id
Open

feat: add WithInvocationID run option#815
quoral wants to merge 1 commit into
google:mainfrom
freda-ab:with-invocation-id

Conversation

@quoral
Copy link
Copy Markdown

@quoral quoral commented May 12, 2026

Problem:
InvocationID was not able to be set from the callers of the ADK. This did not match the adk-python implementation. This has made us not being able to follow the resume functionality within the adk-python guide here.

Solution:
This adds a RunOption that lets a caller pass an existing invocation ID into
runner.Run. When set, the invocation context uses the supplied ID
instead of generating a fresh one.

Testing Plan

Unit Tests:

  • I have added or updated unit tests for my change.
  • All unit tests pass locally.

Please include a summary of passed go test results.

Manual End-to-End (E2E) Tests:

I have started and run our adk-go Agent with these fixes, and ensured that there are no regressions in other behaviors.

Checklist

  • I have read the CONTRIBUTING.md document.
  • I have performed a self-review of my own code.
  • I have commented my code, particularly in hard-to-understand areas.
  • I have added tests that prove my fix is effective or that my feature works.
  • New and existing unit tests pass locally with my changes.
  • I have manually tested my changes end-to-end.
  • Any dependent changes have been merged and published in downstream modules.

Adds a RunOption that lets a caller pass an existing invocation ID into
runner.Run. When set, the invocation context uses the supplied ID
instead of generating a fresh one.

Pure plumbing in this PR: the option is wired through runOptions and
the InvocationContextParams. Callers that omit it keep the existing
auto-generated behaviour.
@radhus
Copy link
Copy Markdown

radhus commented May 12, 2026

@mazas-google tagging you 🙏

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