Skip to content

fix(cli): add automatic payload truncation for large sessions#5

Merged
sungmanch merged 1 commit intomainfrom
feat/stage1-value-enhancement
Jan 17, 2026
Merged

fix(cli): add automatic payload truncation for large sessions#5
sungmanch merged 1 commit intomainfrom
feat/stage1-value-enhancement

Conversation

@sungmanch
Copy link
Copy Markdown
Collaborator

Summary

  • Adds automatic payload truncation when session data exceeds Vercel's 4.5MB limit
  • Truncation strategy: full → truncate content (150KB/session) → drop oldest sessions
  • Notifies users via progress callback when truncation occurs

Problem

Users with extensive Claude Code session histories were getting 413 Request Entity Too Large errors because the compressed payload exceeded Vercel's serverless function limits.

Test plan

  • Run npx no-ai-slop with a large session history
  • Verify analysis completes without 413 errors
  • Check truncation message appears when payload is reduced

🤖 Generated with Claude Code

When session data exceeds Vercel's 4.5MB payload limit, the uploader now:
1. First attempts full payload
2. If too large, truncates each session to 150KB (keeping recent messages)
3. If still too large, drops oldest sessions until it fits

This prevents 413 "Request Entity Too Large" errors for users with
extensive Claude Code session histories.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
@vercel
Copy link
Copy Markdown

vercel bot commented Jan 17, 2026

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

Project Deployment Review Updated (UTC)
no-more-ai-slop Ready Ready Preview, Comment Jan 17, 2026 10:30am

Request Review

@sungmanch sungmanch merged commit 52c648f into main Jan 17, 2026
2 checks passed
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