Skip to content

fix(python): drop unneeded WebAssembly lint allowances on index paths - #442

Merged
giswqs merged 1 commit into
mainfrom
chore/pyodide-index-lint-allowances
Oct 31, 2026
Merged

giswqs merged 1 commit into
mainfrom
chore/pyodide-index-lint-allowances

Conversation

@giswqs

@giswqs giswqs commented Oct 31, 2026

Copy link
Copy Markdown
Member

Removes two allow(unused_mut, unused_variables) attributes on protected_paths in raster_index and vector_index, flagged in review on #441 after that PR had merged. No behavior change: the attributes only apply on WebAssembly, where protected_paths is used and mutated. Validation: cargo check -p terrio-py --target wasm32-unknown-emscripten shows no terrio-py warnings without them.

@coderabbitai

coderabbitai Bot commented Oct 31, 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 20 minutes.

Check out review usage here.

View limit details

Limit details: You’ve used all 2 included reviews 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: Organization UI
  • Review profile: ASSERTIVE
  • Plan: Advanced
  • Run ID: 3fab5510-88fc-4287-8f2d-3c7cac019323
Commits

Reviewing files that changed from the base of the PR and between 80804f7 and 20dcc06.

Files selected for processing: 1
  • python/src/tile_index.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

@github-actions

Copy link
Copy Markdown
Contributor

Code review

Bugs: None found. The change removes allow(unused_mut, unused_variables) from protected_paths in raster_index and vector_index. On wasm, protected_paths.push(...) runs before the wasm-only return Err(...), so the variable is used and mutably borrowed. The later read, for path in protected_paths, is compiled out on wasm, but that does not produce an unused-variable warning. The allow(unused_mut) on index stays, which is correct because index.protect_source_path is also compiled out on wasm. Confidence: high.

Security: None found. Confidence: high.

Performance: None found. Confidence: high.

Quality: None found. The remaining cfg_attr lines match the surrounding style, and no sibling allowances were left in python/src. Confidence: high.

CLAUDE.md / AGENTS.md: No violations found. The change is a lint-attribute cleanup in one file, with no shared algorithm, binding surface, or I/O change, so the workspace-wide checks in the contributor guide do not change the verdict.

Not verified: The PR says cargo check -p terrio-py --target wasm32-unknown-emscripten shows no terrio-py warnings without the attributes. I could not run it here because I have no build tool, so I checked the claim by reading the code only. The non-wasm build is unaffected because the attributes are gated on target_family = "wasm".

No inline comments were posted because I had no specific finding to anchor.

Change size

Compared: the whole PR against main (merge base 80804f7 to PR head 20dcc06).

Measure Value
Files changed 1 (added 0, modified 1, removed 0, renamed 0)
Size before 15.4 KB
Size after 15.2 KB
Total size change -154 B
Path Before After Change
python/src/tile_index.rs 15.4 KB 15.2 KB -154 B

@giswqs
giswqs enabled auto-merge (squash) October 31, 2026 16:47
@giswqs
giswqs disabled auto-merge October 31, 2026 19:01
@giswqs
giswqs merged commit d987600 into main Oct 31, 2026
19 checks passed
@giswqs
giswqs deleted the chore/pyodide-index-lint-allowances branch October 31, 2026 19:01
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