Skip to content

Fix debug logger fallback to cap total output bytes#1907

Merged
siddseethepalli merged 1 commit into
mainfrom
swarm/task-3
Feb 14, 2026
Merged

Fix debug logger fallback to cap total output bytes#1907
siddseethepalli merged 1 commit into
mainfrom
swarm/task-3

Conversation

@siddseethepalli
Copy link
Copy Markdown
Contributor

@siddseethepalli siddseethepalli commented Feb 14, 2026

Summary

  • Replace cut -c1-$MAX_OUTPUT with head -c $MAX_OUTPUT in the debug prompt logger's jq-missing fallback path
  • cut -c truncates each line independently, so multi-line input could exceed the 200KB cap
  • head -c truncates the total byte stream, correctly enforcing the intended limit

Addresses review feedback on #1902.


Open with Devin

Replace `cut -c1-$MAX_OUTPUT` with `head -c $MAX_OUTPUT` so the
200KB cap applies to the entire output stream instead of truncating
each line independently, which could allow multi-line input to
exceed the intended limit.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@siddseethepalli siddseethepalli self-assigned this Feb 14, 2026
@siddseethepalli siddseethepalli merged commit 9fd0cc6 into main Feb 14, 2026
1 check passed
@siddseethepalli siddseethepalli deleted the swarm/task-3 branch February 14, 2026 17:56
Copy link
Copy Markdown
Contributor

@devin-ai-integration devin-ai-integration Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ Devin Review: No Issues Found

Devin Review analyzed this PR and found no potential bugs to report.

View in Devin Review to see 2 additional findings.

Open in Devin Review

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