Skip to content

Accept Shape in Solid.fillet/chamfer - #2105

Open
DavidMStraub wants to merge 3 commits into
CadQuery:masterfrom
DavidMStraub:fix-fillet-chamfer-shape-arg
Open

DavidMStraub wants to merge 3 commits into
CadQuery:masterfrom
DavidMStraub:fix-fillet-chamfer-shape-arg

Conversation

@DavidMStraub

Copy link
Copy Markdown
Contributor

Mixin3D.fillet/chamfer now take edgeList: Shape | Iterable[Edge]. A Shape is normalized with _get_edges(edges.edges()), as the free functions do. This fixes mypy/Pyright errors when passing Shape.edges(...) and a runtime crash when the selection is a single Edge.

Fixes #2104

Mixin3D.fillet/chamfer now take edgeList: Shape | Iterable[Edge]. A Shape
is normalized with _get_edges(edges.edges()), as the free functions do.
This fixes mypy/Pyright errors when passing Shape.edges(...) and a runtime
crash when the selection is a single Edge.

Fixes CadQuery#2104

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@codecov

codecov Bot commented Oct 2, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 95.80%. Comparing base (c11b3f9) to head (dc97bc3).

Additional details and impacted files
@@           Coverage Diff           @@
##           master    #2105   +/-   ##
=======================================
  Coverage   95.80%   95.80%           
=======================================
  Files          30       30           
  Lines        9589     9593    +4     
  Branches     1439     1440    +1     
=======================================
+ Hits         9187     9191    +4     
  Misses        247      247           
  Partials      155      155           

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@adam-urbanczyk adam-urbanczyk left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks, tweaked naming to match existing helpers.

Comment thread cadquery/occ_impl/shapes.py Outdated
Comment thread cadquery/occ_impl/shapes.py Outdated
Co-authored-by: AU <adam-urbanczyk@users.noreply.github.com>
Comment thread cadquery/occ_impl/shapes.py Outdated

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.

Solid.fillet/chamfer reject Shape.edges(...) under mypy

2 participants