You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Say I create a simple 1d mesh topo, geom = mesh.rectilinear([[0,1,2]])
this then has the default boundary tags 'left' and 'right', these can then be called by domain.boundary['right']
which returns StructuredTopology<>
If I make a typo and e.g. call domain.boundary['rigth']
or would call any non-existent boundary, this returns the error message KeyError: ('right',)
So far so good, but if I would now call both boundaries, including the typo, domain.boundary['left,rigth']
this throws no error message, and it simply returns the correctly spelled boundary, ignoring the typo-related boundary. This means I can also do operations like domain.boundary['left,rigth,SomeBoundaryThatDoesNotExist'].integral(myfunction,degree=1234)
and the only way for me to figure out that I have made the typo is by hoping the simulation will not crash and returns a solution where the error is observable near the correct boundary.
I'm using nutils version 6.2, in case that's relevant.
I think this is a bug.
The text was updated successfully, but these errors were encountered:
While this is indeed unfortunate behaviour, there are reasons why it is difficult to raise the appropriate exception if a group does not exists, related to the topology's current design. A planned redesign should fix this and other problems but is a long term programming effort. Until that is completed we will keep this issue open.
Say I create a simple 1d mesh
topo, geom = mesh.rectilinear([[0,1,2]])
this then has the default boundary tags 'left' and 'right', these can then be called by
domain.boundary['right']
which returns
StructuredTopology<>
If I make a typo and e.g. call
domain.boundary['rigth']
or would call any non-existent boundary, this returns the error message
KeyError: ('right',)
So far so good, but if I would now call both boundaries, including the typo,
domain.boundary['left,rigth']
this throws no error message, and it simply returns the correctly spelled boundary, ignoring the typo-related boundary. This means I can also do operations like
domain.boundary['left,rigth,SomeBoundaryThatDoesNotExist'].integral(myfunction,degree=1234)
and the only way for me to figure out that I have made the typo is by hoping the simulation will not crash and returns a solution where the error is observable near the correct boundary.
I'm using nutils version 6.2, in case that's relevant.
I think this is a bug.
The text was updated successfully, but these errors were encountered: