cockpit-server: retire simplify_cells as a production symbol - #141
Conversation
query_tile_geometry (the JSON wire) does its own tile_to_lonlat
projection over query_tile_shapes's output, and the binary wire
(encode_tile_bin) projects to tile-relative pixels instead — neither
calls simplify_cells. It has had no production caller since that
split landed, only three tests, and its doc comment ("the JSON wire's
view") no longer describes anything real.
Move the wrapper into the test module as a private helper with a
corrected comment, so a reader doesn't mistake it for wired-in
production code. Pure relocation: same signature, same body, same
call sites (all three tests already refer to it by name and resolve
unchanged via mod tests's `use super::*`).
Could not verify with cargo check/test: cargo check -p cockpit-server
--bin q2-cockpit currently fails independent of this change (E0599,
lance-graph-ogar references a ConceptDomain::Weather variant that
does not exist in the current OGAR checkout — confirmed pre-existing
via git stash). Filed as a separate blocker; reviewed this diff by
hand (module-scope resolution, no other call sites) since compiling
it end-to-end isn't possible right now.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01NMeiLmtDKhomJNSo2ecbJw
|
Important Review available on request
Reviews should be triggered manually for repositories with fewer than 10 stars. Select Trigger review above or comment ⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Plus Run ID: 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. Comment |
Bugbot couldn't run - usage limit reachedBugbot is counted against Cursor usage for this user or team, and this run hit a usage or spend limit. A user or team admin can review and increase usage limits in the Cursor dashboard. (requestId: serverGenReqId_0148ec9d-b8a9-4b1d-8172-5d0677bd139e) |
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
Summary
Follow-up to #140 (merged):
simplify_cells(the lon/lat-projecting wrapper aroundsimplify_cells_raw) had already lost its only production caller oncequery_tile_geometrywas refactored to project lon/lat inline overquery_tile_shapes's output — andencode_tile_bin(the binary wire) projects to tile-relative pixels instead, never calling it either. It sat at module scope with a doc comment claiming to be "the JSON wire's view," but only 3 tests ever called it.Moved it into the test module as a private helper with a corrected comment, so a reader doesn't mistake it for wired-in production code. Pure relocation: same signature, same body, same call sites (all three tests already refer to it by name and resolve unchanged via
mod tests'suse super::*).Test plan
cargo check -p cockpit-server --bin q2-cockpit— clean.cargo check -p cockpit-server --bin q2-cockpit --tests— clean (covers the relocated test module and its 3 call sites — full type-check + borrow-check).cargo test/cargo nextest runfor this crate could not complete in this session: the final link step for theq2-cockpittest binary (which transitively links nearly the entire q2 workspace — lance/arrow/datafusion/geo/aws-sdk/opendal/tree-sitter/wasmtime/mlua/…) exceeded this container's disk allowance twice in a row (ENOSPC, then a linker SIGBUS), even after fully cleaningtarget/immediately beforehand. Both failures were at the linker stage, not compilation — unrelated to this change. Given the change is a pure mechanical relocation (identical signature/body) andcargo check --testsalready proves it resolves and type-checks correctly at all three call sites, this is reported honestly as a compile-verified-but-not-executed change rather than claimed as a full test pass.🤖 Generated with Claude Code
Generated by Claude Code