Skip to content

fix(sdk): preserve workflow step types - #158

Draft
Ehsan-hash wants to merge 1 commit into
jamjet-labs:mainfrom
Ehsan-hash:fix/workflow-step-typing
Draft

Ehsan-hash wants to merge 1 commit into
jamjet-labs:mainfrom
Ehsan-hash:fix/workflow-step-typing

Conversation

@Ehsan-hash

Copy link
Copy Markdown

Summary

Preserve function signatures through both @workflow.step and @workflow.step(...). Installed SDK users currently see Any for decorated functions, losing editor completions and invalid-argument diagnostics. This adds overloads and the package typing marker without changing runtime behavior.

Related

Addresses #5. Explicit state parameter annotations already work; this change addresses the information lost by the decorator.

Changes

  • Bug fix
  • Tests

Testing

  • New pytest-collected mypy regression covers synchronous/asynchronous functions and both decorator forms. It fails on current main with 10 relevant diagnostics and passes with this patch.
  • Locked Python environment: 24 focused tests pass; full SDK suite has 1,609 passes, one skip and one xpass. Python format, lint and CI-scoped cloud mypy checks pass.
  • Built and installed baseline/final wheels in an isolated environment. Actual VS Code/Pylance changes Any into the expected signatures and reports the invalid integer arguments.
  • Rust formatting and default workspace tests pass. Local all-feature clippy fails in existing optional ort integration after fresh resolution selects rc.15; upstream main CI is green. Keeping this draft until this PR's CI is reconciled.

Checklist

  • Relevant regression and integration tests run
  • All required CI checks pass
  • No runtime API behavior or documentation changes needed
  • Changelog follows the project's release-PR process
  • No significant design change requiring an RFC
  • AI assistance disclosed: developed with Codex assistance and validated with the checks above.

@coderabbitai

coderabbitai Bot commented Oct 23, 2026

Copy link
Copy Markdown

Important

Draft PR not reviewed

Draft PRs are not automatically reviewed by default.

  • Trigger a manual review

To automatically review draft PRs, update your CodeRabbit configuration:

reviews:
  auto_review:
    drafts: true
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

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

This branch has not been deployed

No deployments
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.

1 participant