Skip to content

fix(atlas-search): escape U+007F in pyjson ensure_ascii mode (#5404) - #5405

Merged
dezren39 merged 1 commit into
mainfrom
creator-b/5404-pyjson-del-escape
Nov 4, 2026
Merged

dezren39 merged 1 commit into
mainfrom
creator-b/5404-pyjson-del-escape

Conversation

@dezren39

@dezren39 dezren39 commented Nov 4, 2026 •

Copy link
Copy Markdown
Member

Fixes #5404

py_string's ensure_ascii escape arm used (c as u32) > 0x7f, so U+007F (DEL) — the one character CPython's ASCII encoder escapes inside the ASCII range (its escape set is everything outside 0x20..=0x7e) — was emitted raw by dumps_compact, breaking the --text fragments' byte parity with the Python CLI.

One-boundary fix (>= 0x7f) plus compact_escapes_del_like_cpython, which pins DEL in both modes and the neighbouring boundaries (U+007E raw, U+0080 escaped).

Verified on the laptop: cargo test -p atlas-search — 15 unit + 4 cli_parity tests pass, including the 4 pyjson tests.


Autofix with [code]smith
Open in [code]smith · Need help on this PR? Tag @codesmith-bot with what you need.

@dezren39
dezren39 requested a review from a team as a code owner November 4, 2026 11:00
@coderabbitai

coderabbitai Bot commented Nov 4, 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 13 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
  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: defaults
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 23788a6d-6c9e-4cac-ac9e-d1fc4f440019
Commits

Reviewing files that changed from the base of the PR and between d85411b and 153c98a.

Files selected for processing: 1
  • pkgs/atlas-search/crates/atlas-search/src/pyjson.rs
  • 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

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Nov 4, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-11-04T11:02:28.048574Z 153c98a PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

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.

atlas-search(pyjson): dumps_compact emits U+007F (DEL) raw — CPython ensure_ascii escapes it as \u007f, breaking --text byte parity

1 participant