Repository navigation
fix(server): omit task artifacts from ListTasks unless asked - #447
Merged
muscariello merged 1 commit intoNov 2, 2026
Merged
muscariello merged 1 commit into
muscariello merged 1 commit into
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
muscariello
force-pushed
the
stack/08-list-tasks-include-artifacts
branch
2 times, most recently
from
November 2, 2026 12:02
6f7895e to
07fee30
Compare
ListTasks returned every stored artifact whatever includeArtifacts said. Section 3.1.4 of the spec makes the default false and says the artifacts field MUST be omitted entirely then. DefaultRequestHandler::list_tasks now drops them unless the request sets includeArtifacts to true, next to the historyLength trim, so any TaskStore gets the same behaviour. Signed-off-by: gulldan <5641375+gulldan@users.noreply.github.com>
muscariello
force-pushed
the
stack/08-list-tasks-include-artifacts
branch
from
November 2, 2026 14:28
07fee30 to
7a822de
Compare
msardara
approved these changes
Nov 2, 2026
Open
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.
Fixes #417. Replaces #418. Stacked on #446: review only the last commit.
Cause:
includeArtifactsreachesListTasksRequeston every binding, but nothing read it, soListTasksreturned every stored artifact. §3.1.4 sets the default tofalse, and thenartifactsMUST be omitted.Fix:
DefaultRequestHandler::list_tasksclearsartifactsunless the request setsincludeArtifacts: true, in the loop that already applieshistoryLength. Doing it in the handler gives everyTaskStore, not onlyInMemoryTaskStore, the behavior the spec requires.Behavior change: callers that relied on
ListTasksreturning artifacts now have to ask for them withincludeArtifacts: true.Tests: new
test_list_tasks_includes_artifacts_only_on_request: a stored task with an artifact is listed with the flag unset,falseandtrue.Unproven: that the test fails on
mainwas not run locally. CI is the check.