Skip to content

feat: raw content statuses, renderer fallback and configurable body limit - #128

Merged
sahenjp merged 7 commits into
mainfrom
feat/raw-content-statuses
Nov 8, 2026
Merged

sahenjp merged 7 commits into
mainfrom
feat/raw-content-statuses

Conversation

@sahenjp

@sahenjp sahenjp commented Nov 8, 2026

Copy link
Copy Markdown
Owner

概要:include_raw_content=1 の結果に、本文の有無と理由を分かる形で返し、レンダラー失敗時や大きなページでも困らないようにします。

変更:各結果に raw_content_status(ok / not_requested / too_large / fetch_failed / robots_blocked / extract_failed / render_failed / unknown)と短い raw_content_error を追加。レンダラー失敗時は既定で静的HTMLの本文を保持する page_renderer_fallback を追加。本文上限を raw_content_max_bytes(既定4MiB・上限32MiB)として設定可能に。

検証:cargo test --all-features(新規テスト含む)と cargo check がすべて合格。

注意点:既定は 4 MiB と static のままなので、既存クライアントと設定の挙動は変わりません。

Closes #120, closes #121, closes #122

@sahenjp
sahenjp enabled auto-merge (squash) November 8, 2026 13:39
…imit

- report raw_content_status (ok, not_requested, too_large, fetch_failed,
  robots_blocked, extract_failed, render_failed, unknown) and a short
  raw_content_error on every include_raw_content result, so clients can
  decide retry or give-up from the response alone
- keep the static page text when the JavaScript renderer fails
  (page_renderer_fallback = static, default) and say what happened
- expose the decoded body limit as raw_content_max_bytes (default 4 MiB,
  bounded at 32 MiB) for large public documents

Closes #120, closes #121, closes #122
@sahenjp
sahenjp force-pushed the feat/raw-content-statuses branch from fbe4413 to ea83c34 Compare November 8, 2026 13:48
@sahenjp
sahenjp merged commit b893f1d into main Nov 8, 2026
14 checks passed
@sahenjp
sahenjp deleted the feat/raw-content-statuses branch November 8, 2026 14:16
sahenjp pushed a commit that referenced this pull request Nov 8, 2026
🤖 I have created a release *beep* *boop*
---


##
[0.31.0](v0.30.0...v0.31.0)
(2026-11-08)


### Features

* raw content statuses, renderer fallback and configurable body limit
([#128](#128))
([b893f1d](b893f1d))


### Bug Fixes

* **release:** recover image publishing for already-published releases
([#117](#117))
([5535a15](5535a15))

---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See
[documentation](https://github.com/googleapis/release-please#release-please).

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

1 participant