Skip to content

Congaduto fix calibration points scaling in get_vacuum_points#76

Merged
sca075 merged 2 commits intomainfrom
dev
Mar 15, 2026
Merged

Congaduto fix calibration points scaling in get_vacuum_points#76
sca075 merged 2 commits intomainfrom
dev

Conversation

@sca075
Copy link
Copy Markdown
Owner

@sca075 sca075 commented Mar 15, 2026

fix(conga): fix calibration points scaling in get_vacuum_points

Summary by CodeRabbit

  • New Features

    • Compute and retrieve vacuum corner points from map data for calibration and display.
    • Handle map rotations (90°, 180°, 270°) and return standardized corner coordinates for consistent display.
  • Chores

    • Bumped package version to 0.3.1.

@sca075 sca075 self-assigned this Mar 15, 2026
@coderabbitai
Copy link
Copy Markdown

coderabbitai bot commented Mar 15, 2026

Caution

Review failed

Pull request was closed or merged during review

📝 Walkthrough

Walkthrough

Adds a new public method to CongaMapImageHandler that computes four rotation-aware vacuum corner coordinates from crop_area, applying CONGA_SCALE and offsets and permuting points for 90/180/270° rotations; also bumps package version to 0.3.1.

Changes

Cohort / File(s) Summary
Vacuum Corner Computation
SCR/valetudo_map_parser/conga_handler.py
Added get_vacuum_points(self, rotation_angle: int) -> list[dict[str, int]] to compute four corner vacuum coordinates from crop_area, scale by CONGA_SCALE, apply offset_x/offset_y, handle 90/180/270° rotations via point permutation, and return fallback four (0,0) points when crop_area is falsy.
Package Metadata
SCR/valetudo_map_parser/__init__.py, pyproject.toml
Bumped module docstring and package version from 0.3.0/0.3.0b2 to 0.3.1 (no behavioral changes).

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~10 minutes

Suggested labels

enhancement

Poem

I’m a rabbit, gray and spry,
I trace four corners with an eager eye,
Scaled and offset, turned just right,
Points align in morning light 🐇,
Calibration hops into flight! ✨

🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly describes the main change: adding/fixing the get_vacuum_points method with proper calibration points scaling, which aligns with the new method addition and version bump in the changeset.
Docstring Coverage ✅ Passed Docstring coverage is 100.00% which is sufficient. The required threshold is 80.00%.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
  • 📝 Generate docstrings (stacked PR)
  • 📝 Generate docstrings (commit on current branch)
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch dev
📝 Coding Plan
  • Generate coding plan for human review comments

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

Comment @coderabbitai help to get the list of available commands and usage tips.

@sca075 sca075 merged commit b22ac77 into main Mar 15, 2026
2 of 3 checks passed
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