Repository navigation
Correct upload_asset examples in shared chart prompts - #79899
Conversation
Co-authored-by: copilot-swe-agent[bot] <[email protected]>
Co-authored-by: copilot-swe-agent[bot] <[email protected]>
|
✅ Test Quality Sentinel completed test quality analysis. Test Quality SentinelOutcome: The agent completed and reported no action. A no-op output alone does not verify that all required work was completed or that publication was possible. Agent messages are omitted from this comment. The category uses structured run status, not interpretation of agent prose.
|
|
✅ PR Specification Reviewer completed successfully! PR Specification ReviewerOutcome: The agent completed and reported one or more actions. The no-op output is a completion signal, not a claim that no action was taken. Agent messages are omitted from this comment. The category uses structured run status, not interpretation of agent prose.
|
|
✅ PR Code Quality Reviewer completed the code quality review. PR Code Quality ReviewerOutcome: The agent completed and reported one or more actions. The no-op output is a completion signal, not a claim that no action was taken. Agent messages are omitted from this comment. The category uses structured run status, not interpretation of agent prose.
|
|
✅ Ponytail Reviewer completed successfully! Ponytail ReviewerOutcome: The agent completed and reported no action. A no-op output alone does not verify that all required work was completed or that publication was possible. Agent messages are omitted from this comment. The category uses structured run status, not interpretation of agent prose.
|
|
🧠 Matt Pocock Skills Reviewer has completed the skills-based review. ✅
|
Comment MemoryPeek at saved memory (pr-code-quality-reviewer)Note This comment is managed by comment memory.Expand the saved memory block to view or edit the persistent context for this thread.
|
There was a problem hiding this comment.
Found one documentation correctness issue: the new note describes rejection, while gh-aw sanitizes unknown arguments by stripping them. See the inline comment; please align wording with runtime behavior.
🔎 Code quality review by PR Code Quality Reviewer · copilot · gpt50 · ~3 AIC · ⌖ ~2 AIC · ⊞ 1.6K
Comment /review to run again
| **Upload**: | ||
| 1. `plt.savefig('/tmp/gh-aw/python/charts/my_chart.png', dpi=300, bbox_inches='tight')` | ||
| 2. `{ "type": "upload_asset", "path": "/tmp/gh-aw/python/charts/my_chart.png" }` | ||
| 2. `{ "path": "/tmp/gh-aw/python/charts/my_chart.png" }` — do not include a `type` field; the tool rejects it. |
There was a problem hiding this comment.
The new note says upload_asset rejects a type field, but gh-aw's strict-argument sanitizer strips unknown keys before invocation; this inaccurate claim can mislead workflow authors about what failure to expect.
💡 Make the guidance match runtime behavior
Please say that type must be omitted (or that unknown keys are stripped), unless this prompt is specifically documenting a downstream direct-tool validation path. Apply the same wording correction in trending-charts-simple.md.
There was a problem hiding this comment.
Updated both prompt notes: omit type; the schema accepts path plus optional secrecy and integrity. Commit: 7c7f32c7.
Comment MemoryPeek at saved memory (spec-review-history)History |
Comment MemoryPeek at saved memory (review-history)History |
There was a problem hiding this comment.
Skills-Based Review 🧠
Applied /diagnosing-bugs to the prompt changes. The payload fix is correct, but the stated reason is wrong, so requesting changes to the wording.
📋 Key Findings
Issues
- Incorrect rationale (both files): The new notes say the tool "rejects" a
typefield. It does not. The strict-schema wrapper insafe_outputs_tools_loader.cjs(sanitizeArgsBySchema) silently strips unknown keys, and a probe confirmed the handler receives onlypath. The PR body repeats the claim ("can cause avoidable validation failures"). Agents reading this prompt will believe a call withtypefails when it actually succeeds.
Positive Highlights
- ✅ Removing
typefrom the examples matches the schema (required: ["path"]). - ✅ Both stale examples are updated; no other
"type": "upload_asset"examples remain in prompts.
Uncertainties
- The pre-fetched file list includes several
.lock.ymlchanges unrelated toupload_asset. I could not verify them because the local git fetch failed.
Update the wording in both prompt files and in the PR body to say the field is ignored, or simply omit the note. @copilot please address the review comments above.
🧠 Reviewed using Matt Pocock's skills by Matt Pocock Skills Reviewer · copilot · routed: haiku55 xhigh · ~6 AIC · ⌖ ~2 AIC · ⊞ 6.6K
Comment /matt to run again
| **Upload**: | ||
| 1. `plt.savefig('/tmp/gh-aw/python/charts/my_chart.png', dpi=300, bbox_inches='tight')` | ||
| 2. `{ "type": "upload_asset", "path": "/tmp/gh-aw/python/charts/my_chart.png" }` | ||
| 2. `{ "path": "/tmp/gh-aw/python/charts/my_chart.png" }` — do not include a `type` field; the tool rejects it. |
There was a problem hiding this comment.
[/diagnosing-bugs] The stated reason is wrong: upload_asset silently drops a stray type (see sanitizeArgsBySchema in safe_outputs_tools_loader.cjs) rather than rejecting it.
💡 Suggested wording
Replace the note with: Omit type; the schema accepts only path, plus optional secrecy and integrity.
I confirmed with a probe that the handler receives only path. The payload fix is correct; only the explanation needs correcting here and in the PR body.
@copilot please address this.
There was a problem hiding this comment.
Updated both prompt notes to explain that type should be omitted and the schema accepts path plus optional secrecy and integrity. Commit: 7c7f32c7. I couldn’t edit the PR description with the available tools.
| { "path": "/tmp/gh-aw/python/charts/trend.png" } | ||
| ``` | ||
|
|
||
| Do not include a `type` field; the `upload_asset` tool rejects it. |
There was a problem hiding this comment.
[/diagnosing-bugs] Same incorrect claim as in python-dataviz.md: the tool drops type rather than rejecting it. Use the same corrected wording in both files.
💡 Suggested wording
Replace the sentence with: Omit type; the schema accepts only path, plus optional secrecy and integrity.
@copilot please address this.
There was a problem hiding this comment.
Updated both prompt notes: omit type; the schema accepts path plus optional secrecy and integrity. Commit: 7c7f32c7.
There was a problem hiding this comment.
🔵 Needs a closer look
Human review is needed because protected shared workflow prompts and generated locks affect multiple scheduled workflows, with a missing transitive lock and incomplete validation due to unavailable scanners and unrelated compilation failures.
No open issues 🎉
What changed in this PR
This pull request corrects shared upload_asset examples so agents provide only the supported path argument, preventing avoidable tool-validation failures. It also updates generated workflow locks for affected consumers.
Changes:
- Removed the invalid
typefield from both shared chart prompt examples. - Added guidance that
upload_assetrejects thetypefield. - Refreshed dependent workflow lock metadata; two locks also include PageIndex dependency and cache changes.
| File | Description |
|---|---|
| .github/workflows/spec-librarian.lock.yml | Updates generated PageIndex dependency-installation and cache-invalidation data alongside workflow lock metadata. |
| .github/workflows/shared/trending-charts-simple.md | Corrects the chart upload example to use a path-only payload and documents the rejected type field. |
| .github/workflows/shared/python-dataviz.md | Corrects the shared upload_asset example to use the supported path-only payload and adds explanatory guidance. |
| .github/workflows/org-health-report.lock.yml | Refreshes generated workflow metadata for the updated shared chart prompts. |
| .github/workflows/github-mcp-structural-analysis.lock.yml | Refreshes generated workflow metadata for the updated shared chart prompts. |
| .github/workflows/daily-spending-forecast.lock.yml | Refreshes generated workflow metadata for the updated shared chart prompts. |
| .github/workflows/daily-security-observability.lock.yml | Refreshes generated workflow metadata for the updated shared chart prompt imports. |
| .github/workflows/daily-experiment-report.lock.yml | Refreshes generated workflow metadata for the updated shared chart prompts. |
| .github/workflows/daily-doc-updater.lock.yml | Updates generated PageIndex dependency-installation and cache-invalidation data alongside workflow lock metadata. |
| .github/workflows/copilot-pr-nlp-analysis.lock.yml | Refreshes generated workflow metadata for the updated shared chart prompts. |
Review effort: Lite (adaptive)
|
🍳 A little prep to help this PR along! Copilot assignment requested for the following outstanding work:
Keeping the changes focused; human review and CI get the final taste test. No merging or CI triggering. Structured data{
"completed_task": 0,
"head": "810af263e3488310f680ff955a0f68b6907ad8f1",
"kind": "requested",
"schema_version": "1",
"state": "f4be16d2ff64da6265130e13c5bc927abeb9b6ed221db8f00397d36684f9beb2",
"work": [
"090f8b49139c68f62513737d54cf8f37622f75085d715bc26d7f0a24015d038e",
"3ffc2d9f52f59e31a5765888764c2530099d2d11a8fcfa999f96a1294ef6b892",
"ccfe662b3345669978b0ed39ad8d85036e441c7202fa66a161fd9574942ea8c1"
],
"workflow": "pr-sous-chef"
}
|
Co-authored-by: copilot-swe-agent[bot] <[email protected]>
…-safe-output-usage # Conflicts: # .github/workflows/daily-spending-forecast.lock.yml Co-authored-by: copilot-swe-agent[bot] <[email protected]>
Merged the latest |
Two shared chart prompts included a
typefield inupload_assetarguments, which the tool rejects and can cause avoidable validation failures.typefrom both examples and note that the tool rejects it.{ "path": "/tmp/gh-aw/python/charts/trend.png" }