Skip to content

Commit

Permalink
fix new mypy 1.5.0 errors
Browse files Browse the repository at this point in the history
  • Loading branch information
alexfikl authored and inducer committed Aug 12, 2023
1 parent 86da3c1 commit 366eefb
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions meshmode/mesh/processing.py
Original file line number Diff line number Diff line change
Expand Up @@ -1429,12 +1429,14 @@ def compute_new_map(old_map: AffineMap) -> AffineMap:
for old_fagrp_list in mesh.facial_adjacency_groups:
fagrp_list = []
for old_fagrp in old_fagrp_list:
if hasattr(old_fagrp, "aff_map"):
new_fields = {"aff_map": compute_new_map(old_fagrp.aff_map)}
if isinstance(old_fagrp,
(InteriorAdjacencyGroup, InterPartAdjacencyGroup)):
new_fagrp: FacialAdjacencyGroup = replace(
old_fagrp, aff_map=compute_new_map(old_fagrp.aff_map))
else:
new_fields = {}
new_fagrp = old_fagrp

fagrp_list.append(replace(old_fagrp, **new_fields))
fagrp_list.append(new_fagrp)
facial_adjacency_groups.append(fagrp_list)

else:
Expand Down

0 comments on commit 366eefb

Please sign in to comment.