Skip to content

Add optional threadId to attempt history entries - #86

Open
alexshamrai wants to merge 1 commit into
ctrf-io:prep/0.3.0-09-version-preparationfrom
alexshamrai:feature/attempt-thread-id
Open

alexshamrai wants to merge 1 commit into
ctrf-io:prep/0.3.0-09-version-preparationfrom
alexshamrai:feature/attempt-thread-id

Conversation

@alexshamrai

@alexshamrai alexshamrai commented Oct 26, 2026 •

Copy link
Copy Markdown
Contributor

Adds optional threadId to attempt history entries, so each previous attempt can record the thread or worker that executed it (new section 11.12.1). Section 9.25 now says the Test-level threadId describes the final attempt represented by the test object.

Following the review in #74, the two fields share one contract, as Test and history attemptId do: an optional string at both levels, plus a SHOULD to qualify the value with the process or host when test cases run in more than one process or on more than one host. The change adds no rule for an attempt without threadId, and no serial-execution guarantee.

Adds threadId to the retry history of the standalone and inline comprehensive examples, a valid document whose previous and final attempts ran on different workers, and type cases rejecting non-string attempt values. Adds the changelog entries under Unreleased. Closes #74.

Part of the 0.3.0 stack (#75): this PR now targets prep/0.3.0-09-version-preparation (#84). The new fixtures use 0.3.0, and the changelog entries join the stack's Unreleased lists. I'm happy to rebase again if earlier stack branches change.

Validation: schema format/lint, 22 reference cases, 175 normative cases, all 9 standalone examples, all 10 complete inline examples and embedded-schema byte equality pass locally with sourcemeta/jsonschema v14.4.0. The informative-test directory is absent on the base branch.

Attempt history entries can record the thread or worker that executed
them, using the same contract as the Test threadId. The Test threadId
now explicitly describes the final attempt, and producers that run test
cases in more than one process or on more than one host are asked to
qualify threadId values.

No omission rule and no serial-execution guarantee are added.
@Ma11hewThomas

Copy link
Copy Markdown
Collaborator

Looks great! Happy with these changes. You can include this in the open stack, or I can merge it myself as part of the stack later. Thanks for the work!

Great to see you contributing to CTRF again!

@alexshamrai
alexshamrai changed the base branch from main to prep/0.3.0-09-version-preparation October 27, 2026 20:35
@alexshamrai
alexshamrai force-pushed the feature/attempt-thread-id branch from edeb775 to 18b98da Compare October 27, 2026 20:38
@alexshamrai

Copy link
Copy Markdown
Contributor Author

Looks great! Happy with these changes. You can include this in the open stack, or I can merge it myself as part of the stack later. Thanks for the work!

Great to see you contributing to CTRF again!

Thanks! I've moved it onto the stack: it now targets prep/0.3.0-09-version-preparation, resolves the overlaps with the stack, and uses 0.3.0 in the new fixtures. I hope I got your point correct.
Thank you for your time and effort!

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.

Proposal: Add optional threadId to retryAttempts entries

2 participants