Add workflow-streams sample#470
Open
brianstrauch wants to merge 14 commits into
Open
Conversation
Ports the five scenarios from samples-python/workflow_streams to TypeScript, using the @temporalio/workflow-streams contrib package (currently on the contrib/pubsub branch of sdk-typescript). Covers basic publish/subscribe, reconnecting subscriber, external (non-Activity) publisher, bounded log via truncate(), and LLM token streaming with retry handling. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This was referenced Jun 3, 2026
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Resolves semgrep supply-chain findings (CVE-2021-23566, CVE-2024-55565) flagged on the workflow-streams sample, which was missing from the workspace lockfile. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
- Add workflow-streams to list-of-samples.json so the pre-push hook's copy-shared-files script no longer prompts on every push. - Exclude workflow-streams from .eslintrc.js sync (it adds src/llm-workflows.ts to the workflow lint rules) and from .post-create sync (its run command is `npm run workflow.publisher`). - Skip the /dev/tty redirect in the pre-push hook when no terminal is attached, so pushes from IDE integrations and CI don't fail with "/dev/tty: Device not configured". Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
# Conflicts: # pnpm-lock.yaml
brianstrauch
commented
Jun 9, 2026
brianstrauch
commented
Jun 9, 2026
The lockfile had pinned next@16.3.0-preview.0 (briefly published as "latest"), whose @next/swc-* binaries were never published, causing a 404 during next build in CI. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
xumaple
approved these changes
Jun 12, 2026
xumaple
left a comment
There was a problem hiding this comment.
Generally LGTM, but can you add some tests?
# Conflicts: # pnpm-lock.yaml
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Mirrors the Go sample's coverage: time-skipping unit tests for the order, pipeline, hub, ticker, and llmStreaming workflows, plus a dev-server integration test that subscribes to the order workflow's status and progress topics end to end. Runs in CI. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
samples-python/workflow_streamsto TypeScript, using the experimental@temporalio/workflow-streamscontrib package on thecontrib/pubsubbranch ofsdk-typescript.truncate(), and LLM token streaming with retry handling.@temporalio/workflow-streams/workflow; client/activity/runner files import from@temporalio/workflow-streams/client. The split keeps the workflow bundle free ofcrypto/@temporalio/activity/@temporalio/client.Test plan
contrib/pubsubsplit-entrypoints work)🤖 Generated with Claude Code