Skip to content

fix: publish the agent's answer verbatim in summary - #20

Merged
PunGrumpy merged 2 commits into
mainfrom
fix/summary-verbatim
Oct 18, 2026
Merged

PunGrumpy merged 2 commits into
mainfrom
fix/summary-verbatim

Conversation

@PunGrumpy

Copy link
Copy Markdown
Owner

Description

parseSummary tried to JSON.parse the agent's answer and, when it was an object with a response, summary, result, output, or text field, published only that field. That was a leftover from the CLI's --output-format json days; the SDK returns the final message as plain text, so a workflow asking for a JSON answer silently lost every other field. summary is now the answer verbatim, trimmed, with terminal colour codes stripped.

Related Issues

None.

Checklist

  • I've reviewed my code
  • I've written tests (skip if not applicable, e.g. .github/–only changes)
  • I've added a changeset when the change affects the published action or release notes (skip for .github/–only community or template updates)
  • I've updated the docs, if necessary

Screenshots (if applicable)

N/A

Additional Notes

The five tests that asserted the unwrapping are replaced by one that asserts a JSON-shaped answer comes through unchanged. dist/ is rebuilt. The behaviour only changes for answers that happen to be JSON objects, which is what the docs already described.

The unwrapping of response, summary, result, output and text fields was a leftover from the CLI's --output-format json days. The SDK returns the final message as plain text, so a JSON answer lost every field but one.
@changeset-bot

changeset-bot Bot commented Oct 18, 2026

Copy link
Copy Markdown

🦋 Changeset detected

Latest commit: a5e4bf0

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
@pungrumpy/cursor-action Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@vercel

vercel Bot commented Oct 18, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
cursor-action Ready Ready Preview Oct 18, 2026 10:47am UTC

@coderabbitai

coderabbitai Bot commented Oct 18, 2026

Copy link
Copy Markdown

Warning

Review limit reached

You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository.

Next included review available in 59 minutes.

Check out review usage here.

View limit details

Limit details: You’ve used the included review currently available.

Learn how review limits work.

Review configuration:

⚙️ Run configuration
  • Configuration used: Organization UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 5d5c3069-0cb2-4348-aabf-28fa0eac4bf6
📥 Commits

Reviewing files that changed from the base of the PR and between 6d67266 and a5e4bf0.

⛔ Files ignored due to path filters: 1
  • dist/index.mjs is excluded by !**/dist/**
📒 Files selected for processing: 4
  • .changeset/summary-verbatim.md
  • __tests__/output.test.ts
  • docs/content/behaviour.mdx
  • src/output.ts
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@PunGrumpy
PunGrumpy merged commit 5bbf814 into main Oct 18, 2026
12 of 13 checks passed

This branch was successfully deployed

1 active deployment
Preview — a5e4bf08 Deployed Oct 18, 2026 by vercel[bot]
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.

1 participant