mirror of
https://github.com/openclaw/openclaw.git
synced 2026-07-21 19:51:36 +00:00
* fix(mantis): bound upload error response bodies Replace unbounded response.text() on non-ok upload error paths with readBoundedResponseText (64 KiB cap). Only swallow the size-exceeded diagnostic; propagate signal aborts and other failures so timeouts during body reading are not masked as generic upload failures. - Import shared readBoundedResponseText from scripts/lib/bounded-response.mjs - Add MANTIS_UPLOAD_ERROR_BODY_MAX_BYTES constant (64 KiB) - Catch only size-exceeded errors; re-throw timeouts and stream errors - Add test: oversized body bounded at 64 KiB - Add test: signal abort during body read propagates correctly - Add test: small error body within bound reads normally * fix(mantis): contextualize bounded upload failures Co-authored-by: 胡根深 0668000903 <hu.genshen@xydigit.com> --------- Co-authored-by: Peter Steinberger <steipete@gmail.com>