Skip to content

MeshedRegion deep_copy method needs to be refactored to handle PropertyFields in legacy gRPC servers #3236

@rafacanton

Description

@rafacanton

Before submitting the issue

  • I have checked for Compatibility issues
  • I have searched among the existing issues
  • I am using a Python virtual environment

Description of the bug

PR #3235 disables the MeshedRegion.deep_copy method test for legacy gRPC servers because the way eltype and connectivity was added to the mesh modifed on the fly line elements. This needs to be refactored to instead copy the PropertyFields directly.

In addition, the rest of the Mesh PropertyFields should we deep_copied, not just eltype and connectivity

Steps To Reproduce

model = dpf.core.Model(allkindofcomplexity, server=legacy_grpc_server)
mesh = model.metadata.meshed_region
copy = mesh.deep_copy()
assert np.allclose(copy.elements.element_types_field.data, mesh.elements.element_types_field.data)

Which Operating System causes the issue?

Windows

Which DPF/Ansys version are you using?

Ansys 2027 R1

Which Python version causes the issue?

3.11

Installed packages

.

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions