Skip to content

api: Fit the vector API in the size budget - #224

Draft
BenWestgate wants to merge 1 commit into
codex/49-vector-apifrom
claude/project-thread-b1oz3e
Draft

BenWestgate wants to merge 1 commit into
codex/49-vector-apifrom
claude/project-thread-b1oz3e

Conversation

@BenWestgate

Copy link
Copy Markdown
Owner

Before: #53 fails test_production_size_budgets_are_enforced on every CI job, with 5,207 installed logical lines against a limit below 5,200.

After: the package is at 5,199 lines. It keeps #53's public names without the leading _ and adds no compatibility notes, per the concept ACK/NACK on #53.

How:

  • Inline _ascii_lower, which had one caller, into chars_to_u5 and drop its two unused imports (−3).
  • checksum_for_body_length returns the checksum selected by checksum_for_encoded_length (−1). The behaviour is the same, including the 94/95 gap check.
  • Drop the docstrings on u5_to_chars, chars_to_u5 and Checksum, which repeat the name (−3). The ASCII-only note moves to docs/developer/api.md.
  • Remove the MismatchedProfile alias and its "compatibility name" comment. Callers and tests use MismatchedHrp (−1).

Validation: full pytest 960 passed, normally and under -O; ruff check, ruff format and mypy are clean.

Stacked on #53. It can be squashed into #53's refresh.


Generated by Claude Code

Inline the one-caller ASCII lowercase helper and drop its unused
imports, return the selected checksum directly, drop docstrings that
restate the helper names, and remove the MismatchedProfile alias in
favour of MismatchedHrp. Installed logical lines: 5207 -> 5199.

Claude-Session: https://claude.ai/code/session_01E75K4nCzge7jFwjwDgeBrR

This branch has not been deployed

No deployments
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