docs(skill): note create/resume wire-builder duplication pitfall#138
Merged
Conversation
Add Common Pitfall #6 to the update-upstream skill: session.create and session.resume build wire params in separate functions that share several sub-shapes (tool defs, system message, provider, MCP servers, custom agents, commands). A new field on a shared shape must land in both builders or be funneled through a named *->wire helper, otherwise it ships on create and silently vanishes on resume. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Contributor
There was a problem hiding this comment.
Pull request overview
Adds a new “Common Pitfall” entry to the update-upstream skill documentation to prevent create/resume drift when constructing wire params for shared sub-shapes (e.g., tools, system message, provider, MCP servers).
Changes:
- Document pitfall #6:
session.createandsession.resumebuild wire params in separate builders; shared sub-shapes should be funneled through named*->wirehelpers to avoid silent omissions.
Show a summary per file
| File | Description |
|---|---|
.github/skills/update-upstream/SKILL.md |
Adds Common Pitfall #6 describing the create/resume wire-param builder drift hazard and recommended refactoring pattern. |
Copilot's findings
- Files reviewed: 1/1 changed files
- Comments generated: 0
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.
Adds Common Pitfall #6 to the
update-upstreamskill.This pitfall surfaced while porting the
:defertool option (#137).session.createandsession.resumebuild their wire params in two separate functions (build-create-session-params/build-resume-session-params) that share several sub-shapes — tool defs, system message, provider, MCP servers, custom agents, commands. A new field added to a shared shape in only one builder ships on create and silently vanishes on resume.The existing pitfall #1 covers declaration sites (specs,
:opt-un, public sets, docstrings); this is the distinct construction trap. The guidance: funnel each shared sub-shape through one named*->wirehelper rather than duplicating acond->inline.Skill-maintenance only — no SDK code changes.