Repository navigation
[miniflare] Add workflow introspection for exported Workflows - #17016
Conversation
🦋 Changeset detectedLatest commit: 50c300a The changes in this PR will be included in the next version bump. This PR includes changesets to release 8 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
@cloudflare/autoconfig
@cloudflare/build-output-utils
@cloudflare/codemods
@cloudflare/config
@cloudflare/containers-shared
create-cloudflare
@cloudflare/deploy-helpers
@cloudflare/kv-asset-handler
miniflare
@cloudflare/pages-functions
@cloudflare/pages-shared
@cloudflare/runtime-types
@cloudflare/unenv-preset
@cloudflare/vite-plugin
@cloudflare/vitest-plugin
@cloudflare/workers-auth
@cloudflare/workers-editor-shared
@cloudflare/workers-utils
wrangler
commit: |
|
Codeowners approval required for this PR:
Show detailed file reviewers
|
There was a problem hiding this comment.
Superseded by the review of
7920aaed.
This review, of 161ab5dd
✅ Approved — No issues found. The new exported-Workflow introspection methods are small and checked against the Worker's exports, and they come with tests.
The decision is advisory: this review is a comment and never approves, blocks or requests changes on the pull request.
✅ All checks passed
🔒 Security: ✅ LGTM
No issues found.
📖 AGENTS.md: ✅ LGTM
No issues found.
📋 Code Quality: ✅ LGTM
No issues found.
⚡ Performance: ✅ LGTM
No issues found.
📝 Documentation: ✅ LGTM
No issues found.
Reviewed commit: 161ab5dd
161ab5d to
7920aae
Compare
There was a problem hiding this comment.
Superseded by the review of
50c300a1.
This review, of 7920aaed
✅ Approved — No issues found. The new exported-Workflow introspection methods are small and checked against the Worker's exports, and they come with tests.
The decision is advisory: this review is a comment and never approves, blocks or requests changes on the pull request.
✅ All checks passed
🔒 Security: ✅ LGTM
No issues found.
📖 AGENTS.md: ✅ LGTM
No issues found.
📋 Code Quality: ✅ LGTM
No issues found.
⚡ Performance: ✅ LGTM
No issues found.
📝 Documentation: ✅ LGTM
No issues found.
Reviewed commit: 7920aaed — same changes as 161ab5dd, so this is that commit's review (no new review was run; line numbers are as of 161ab5dd)
…owInstance() for exported Workflows Node.js could only introspect a Workflow through an `env` binding from getBindings(), so a Workflow only on `ctx.exports` couldn't be introspected. Each exported Workflow now has a proxy binding, found by its Worker and class name.
7920aae to
50c300a
Compare
There was a problem hiding this comment.
✅ Approved — No issues found. The new exported-Workflow introspection methods are small and checked against the Worker's exports, and they come with tests.
The decision is advisory: this review is a comment and never approves, blocks or requests changes on the pull request.
✅ All checks passed
🔒 Security: ✅ LGTM
No issues found.
📖 AGENTS.md: ✅ LGTM
No issues found.
📋 Code Quality: ✅ LGTM
No issues found.
⚡ Performance: ✅ LGTM
No issues found.
📝 Documentation: ✅ LGTM
No issues found.
Reviewed commit: 50c300a1 — same changes as 161ab5dd, so this is that commit's review (no new review was run; line numbers are as of 161ab5dd)
petebacondarwin
left a comment
There was a problem hiding this comment.
Codeowners bypass
workers-devprod
left a comment
There was a problem hiding this comment.
Codeowners reviews satisfied
Part of RM-31812. The cf test harness (#16798) is stacked on this.
Adds
unsafeIntrospectWorkflow(workerName, className)andunsafeIntrospectWorkflowInstance(workerName, className, instanceId), so Node.js code can introspect a Workflow that a Worker exports, including one only onctx.exports, without anenvbinding. Introspection through a binding, as in the Vitest plugin, is unchanged.unsafeMiniflare methods for the cf test harness