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 friday #1409

Merged
merged 8 commits into from
Nov 8, 2024
Merged

Fix friday #1409

merged 8 commits into from
Nov 8, 2024

Conversation

tomvanmele
Copy link
Member

What type of change is this?

  • Bug fix in a backwards-compatible manner.
  • New feature in a backwards-compatible manner.
  • Breaking change: bug fix or new feature that involve incompatible API changes.
  • Other (e.g. doc update, configuration, etc)

Checklist

Put an x in the boxes that apply. You can also fill these out after creating the PR. If you're unsure about any of them, don't hesitate to ask. We're here to help! This is simply a reminder of what we are going to look for before merging your code.

  • I added a line to the CHANGELOG.md file in the Unreleased section under the most fitting heading (e.g. Added, Changed, Removed).
  • I ran all tests on my computer and it's all green (i.e. invoke test).
  • I ran lint on my computer and there are no errors (i.e. invoke lint).
  • I added new functions/classes and made them available on a second-level import, e.g. compas.datastructures.Mesh.
  • I have added tests that prove my fix is effective or that my feature works.
  • I have added necessary documentation (if appropriate)

Copy link

codecov bot commented Nov 8, 2024

Codecov Report

Attention: Patch coverage is 40.74074% with 16 lines in your changes missing coverage. Please review.

Project coverage is 61.55%. Comparing base (1aabc04) to head (91b210d).
Report is 9 commits behind head on main.

Files with missing lines Patch % Lines
src/compas/datastructures/volmesh/volmesh.py 47.61% 11 Missing ⚠️
src/compas/scene/scene.py 16.66% 5 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1409      +/-   ##
==========================================
+ Coverage   61.39%   61.55%   +0.16%     
==========================================
  Files         207      207              
  Lines       22275    22272       -3     
==========================================
+ Hits        13675    13710      +35     
+ Misses       8600     8562      -38     

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

@tomvanmele
Copy link
Member Author

btw, @gonzalocasas the real changes to volmesh are in lines 1764 and onwards. the rest is just annoying code coverage feedabck because i added a few # type: ignore comments

@tomvanmele
Copy link
Member Author

tomvanmele commented Nov 8, 2024

the section i commented out is a function that is not only broken , but also doesn't seem to make much sense. will remove it if there is no objection...

Copy link
Contributor

@Licini Licini left a comment

Choose a reason for hiding this comment

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

LGTM

Copy link
Member

@gonzalocasas gonzalocasas left a comment

Choose a reason for hiding this comment

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

Tested is_halfface_on_boundary and it works, I'm worried about the deletion of public methods, because this is not going to be a new major release

nbr_halfface = self._cell[cell][v][u]
nbr_cell = self._plane[u][v][nbr_halfface]
return None if nbr_cell is None else self._cell[nbr_cell][v][u]
# def halfface_adjacent_halfface(self, halfface, halfedge):
Copy link
Member

Choose a reason for hiding this comment

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

This would be a breaking change

Copy link
Member Author

Choose a reason for hiding this comment

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

sure but the method absolutely doesn't work and i don't even know what it is supposed to do...

Copy link
Member

Choose a reason for hiding this comment

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

hehe ok, let's remove it, maybe adding a clear notice in the changelog

@@ -3108,37 +3111,6 @@ def halfface_opposite_halfface(self, halfface):
nbr = self._plane[w][v][u]
return None if nbr is None else self._cell[nbr][w][v]

def halfface_adjacent_halfface(self, halfface, halfedge):
Copy link
Member

Choose a reason for hiding this comment

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

This would be a breaking change, it shouldn't be included if this is going to be a patch release.

Copy link
Member Author

Choose a reason for hiding this comment

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

it can't be that anyone has been using this because the description is nonsensical and the implementation doesn't work. we can leave it in, but i don't know how to fix it because i don't even know what it is supposed to do...

src/compas/scene/meshobject.py Show resolved Hide resolved
src/compas/scene/scene.py Show resolved Hide resolved
### Removed

* Removed `VolMesh.halfface_adjacent_halfface` because of general nonsensicalness, and because it is (and probably always has been) completely broken.
Copy link
Member

Choose a reason for hiding this comment

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

😝

@tomvanmele tomvanmele merged commit 95eaa00 into main Nov 8, 2024
17 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.

3 participants