Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix offset of faces with holes #491

Merged
merged 4 commits into from
Jan 23, 2024
Merged

Fix offset of faces with holes #491

merged 4 commits into from
Jan 23, 2024

Conversation

jdegenstein
Copy link
Collaborator

Currently, offset of faces with holes can fail when the length of the inner wires reaches zero. This causes confusion for users especially with offsets of text that frequently contains holes.

This PR fixes that issue by silently deleting the inner wires if there is an exception while offsetting them. This example now works properly:

with BuildSketch() as s:
    t = Text("build", 20)
    offset(amount=5, mode=Mode.ADD)

image

Copy link

codecov bot commented Jan 23, 2024

Codecov Report

Attention: 3 lines in your changes are missing coverage. Please review.

Comparison is base (61a3610) 96.00% compared to head (9919882) 96.01%.

❗ Current head 9919882 differs from pull request most recent head 911e120. Consider uploading reports for the commit 911e120 to get more accurate results

Files Patch % Lines
src/build123d/operations_generic.py 57.14% 3 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##              dev     #491      +/-   ##
==========================================
+ Coverage   96.00%   96.01%   +0.01%     
==========================================
  Files          24       24              
  Lines        7458     7461       +3     
==========================================
+ Hits         7160     7164       +4     
+ Misses        298      297       -1     

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

@gumyr gumyr merged commit aeafb3a into gumyr:dev Jan 23, 2024
10 checks passed
@jdegenstein jdegenstein deleted the try_offset branch January 23, 2024 19:17
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.

2 participants