Skip to content

Add a schedule feature test for ErrScheduleAlreadyRunning#799

Merged
lina-temporal merged 1 commit intomainfrom
sched-already-running-test
Apr 8, 2026
Merged

Add a schedule feature test for ErrScheduleAlreadyRunning#799
lina-temporal merged 1 commit intomainfrom
sched-already-running-test

Conversation

@lina-temporal
Copy link
Copy Markdown
Contributor

What was changed

  • Added a new feature test asserting a specific error for duplicate schedules.

Why?

  • This specific error is special-cased in the SDK to translate from WorkflowExecutionAlreadyStarted into the application-level error.
  • Broke when CHASM changed to a different AlreadyExists type.

@Sushisource
Copy link
Copy Markdown
Member

This specific error is special-cased in the SDK to translate from WorkflowExecutionAlreadyStarted into the application-level error.

Did you check if this exists in other SDKs? I'm confused what broke if this is adding a new test?

@lina-temporal
Copy link
Copy Markdown
Contributor Author

Did you check if this exists in other SDKs?

Yes, it does - TypeScript example.

I'm confused what broke if this is adding a new test?

There wasn't coverage testing the full E2E of duplicate errors (including the SDK piece), so when the error in server changed, nothing showed us that the translation in SDK was no longer working (e.g., we didn't realize we'd broken things). This will also validate the fix PR as features will run against that PR's commits, including w/ CHASM enabled.

@lina-temporal lina-temporal merged commit 0e2e288 into main Apr 8, 2026
65 of 68 checks passed
@lina-temporal lina-temporal deleted the sched-already-running-test branch April 8, 2026 18:07
@Sushisource
Copy link
Copy Markdown
Member

Sushisource commented Apr 8, 2026

@lina-temporal OK, makes sense - can we add other languages then? Super easy to do with coding agents these days and really helps our coverage to have more than just Go

@lina-temporal
Copy link
Copy Markdown
Contributor Author

@lina-temporal OK, makes sense - can we add other languages then? Super easy to do with coding agents these days and really helps our coverage to have more than just Go

Sure, I'll add them as well now that this has landed for the fix. Indeed, the Go test was also written with a coding agent, but I opted to reduce the review surface since it's an active incident.

lina-temporal added a commit to temporalio/temporal that referenced this pull request Apr 8, 2026
…ateSchedule duplicate paths (#9866)

## What changed?
- Restored previous WorkflowExecutionAlreadyStarted error handling.
`CreateSchedule` is special-cased in the SDK such that that specific
error is wrapped into an application-level `ScheduleAlreadyExists`
error.
- CHASM handler still returns `AlreadyExists`, which is translated at
the frontend handler level.

## Why?
- Broke backwards compatibility with the SDK

## How did you test it?
**New feature test to accompany this PR**:
temporalio/features#799

- [x] built
- [x] run locally and tested manually
- [ ] covered by existing tests
- [x] added new unit test(s)
- [x] added new functional test(s)
- [x] added new feature test(s)
tdyas pushed a commit to temporalio/temporal that referenced this pull request Apr 8, 2026
…ateSchedule duplicate paths (#9866)

## What changed?
- Restored previous WorkflowExecutionAlreadyStarted error handling.
`CreateSchedule` is special-cased in the SDK such that that specific
error is wrapped into an application-level `ScheduleAlreadyExists`
error.
- CHASM handler still returns `AlreadyExists`, which is translated at
the frontend handler level.

## Why?
- Broke backwards compatibility with the SDK

## How did you test it?
**New feature test to accompany this PR**:
temporalio/features#799

- [x] built
- [x] run locally and tested manually
- [ ] covered by existing tests
- [x] added new unit test(s)
- [x] added new functional test(s)
- [x] added new feature test(s)
temporal-cicd bot pushed a commit to temporalio/temporal that referenced this pull request Apr 8, 2026
…ateSchedule duplicate paths (#9866)

## What changed?
- Restored previous WorkflowExecutionAlreadyStarted error handling.
`CreateSchedule` is special-cased in the SDK such that that specific
error is wrapped into an application-level `ScheduleAlreadyExists`
error.
- CHASM handler still returns `AlreadyExists`, which is translated at
the frontend handler level.

## Why?
- Broke backwards compatibility with the SDK

## How did you test it?
**New feature test to accompany this PR**:
temporalio/features#799

- [x] built
- [x] run locally and tested manually
- [ ] covered by existing tests
- [x] added new unit test(s)
- [x] added new functional test(s)
- [x] added new feature test(s)
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.

3 participants