Skip to content

feat(mcp): add include_user_stories option to list_milestones/get_milestone - #275

Closed
yakky wants to merge 5 commits into
issue/mcp-optional-project-paramfrom
issue/mcp-milestone-user-stories-toggle
Closed

yakky wants to merge 5 commits into
issue/mcp-optional-project-paramfrom
issue/mcp-milestone-user-stories-toggle

Conversation

@yakky

@yakky yakky commented Sep 14, 2026

Copy link
Copy Markdown
Member

Description

Adds an include_user_stories option (default True) to the MCP server's
list_milestones and get_milestone tools. Milestone.user_stories is always
fully expanded by python-taiga's parser into complete UserStory objects, which
the MCP server's to_jsonable() then serializes in full — making the embedded
field potentially large. Passing include_user_stories=False strips that key
from each returned milestone via a new _strip_user_stories() helper. Default
behavior (and output shape) is unchanged for existing callers.

Also updates docs/mcp.rst to document the new flag.

Builds on issue/mcp-optional-project-param (project-parameter optionality fix
for list_milestones/list_wiki_pages) — this PR is stacked on that branch.

References

No linked issue (minor/internal MCP server improvement).

Checklist

  • I have read the contribution guide
  • Code lint checked via inv lint
  • changes file included — skipped: no GitHub issue number exists for this minor change, and changes/<issue>.<type> fragment names must reference one per CONTRIBUTING.rst
  • Usage documentation added in case of new features
  • Tests added

AI usage

Model: Claude Sonnet 5 (Claude Code), via the /nephila-flow company lifecycle command.

Scope: Full implementation — design discussion (bounded-path brainstorming),
TDD implementation, an independent code-review subagent pass, documentation sync,
and a rubric-scored evaluation (94%, artifacts/evaluations/2026-09-14-mcp-milestone-user-stories-toggle.md).

Prompts (faithful summary): "add to taiga.mcp_server.server.list_milestones
the option to return the full taiga response for the given endpoint or to remove
user_stories attribute from returned data" — refined through clarifying questions
into the include_user_stories toggle described above, then implemented and
reviewed per the standard flow, with the human author approving the design, the
branch, each commit, and the push at every gate.

Agent usage

Stage Agent/skill Tokens Time
Review superpowers:requesting-code-review (general-purpose subagent) ~70k ~60s

yakky and others added 5 commits September 14, 2026 14:55
…estone

Milestone.user_stories is always fully expanded by python-taiga's parser,
making the embedded field potentially large. Add include_user_stories
(default True, preserving current output) to both tools so callers can
opt into a trimmed response with that key stripped.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
…tests

Minor code-review follow-ups: replace the Any -> Any signature with the
actual dict[str, Any] | list[dict[str, Any]] shape it's always called
with, and add unit tests exercising the helper directly (dict, list,
and no-op-when-absent cases) rather than only through list_milestones/
get_milestone.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
…es toggle

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
@codecov

codecov Bot commented Sep 14, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 97.69%. Comparing base (b0043c2) to head (1547d81).

Additional details and impacted files
@@                         Coverage Diff                          @@
##           issue/mcp-optional-project-param     #275      +/-   ##
====================================================================
+ Coverage                             97.68%   97.69%   +0.01%     
====================================================================
  Files                                    12       12              
  Lines                                  1340     1346       +6     
  Branches                                 94       95       +1     
====================================================================
+ Hits                                   1309     1315       +6     
  Misses                                   20       20              
  Partials                                 11       11              
Flag Coverage Δ
unittests 97.69% <100.00%> (+0.01%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@coveralls

Copy link
Copy Markdown

Coverage Status

coverage: 98.514% (+0.007%) from 98.507% — issue/mcp-milestone-user-stories-toggle into issue/mcp-optional-project-param

@yakky yakky closed this Sep 16, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants