Skip to content

PyPrimeMesh fails on STEP files #1001

Open
@ThomasAuzinger

Description

@ThomasAuzinger

🔍 Before submitting the issue

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

🐞 Description of the bug

I am using PyPrimeMesh (i.e., from ansys.meshing import prime) in a Python script to mesh CAD models.

For an extremely simple model (i.e., a cube), this import works for an x_t file but does not for the corresponding STEP file.

While the x_t import happens rather quickly in a few seconds, the STEP import hangs for >1min and finally reports ansys.meshing.prime.internals.error_handling.PrimeRuntimeError: CAD import failed.

Note that the server, which I start with "%AWP_ROOT251%\meshing\Prime\runPrime.bat" server -np 1 --ip 127.0.0.1 --port 50057 is functional the whole time and does not crash. After the failed STEP import, I can still successfully import an x_t file without having to restart the server.

Could you perhaps send me a basic Python script that shows how to import a trivial cube model from a STEP file?

📝 Steps to reproduce

script-and-data.zip

  1. Add the Trivial_Slab.step and Trivial_Slab.x_t files into a ./data directory.
  2. Add the meshing_test.py file into a ./src dirctory.
  3. Run the script and see that it successfully import the .x_t CAD model but fails on the subsequent import of the 'identical' .step model.

💻 Which operating system are you using?

Windows

📀 Which ANSYS version are you using?

2025 R1

🐍 Which Python version are you using?

3.12

📦 Installed packages

aiohappyeyeballs==2.6.1
aiohttp==3.11.16
aiosignal==1.3.2
annotated-types==0.7.0
ansys-acp-core==0.1.0
ansys-additive-core==0.19.1
ansys-additive-widgets==0.2.1
ansys-api-acp==0.2.0
ansys-api-additive==2.2.1
ansys-api-dbu==0.3.13
ansys-api-dyna==0.4.2
ansys-api-edb==1.0.10
ansys-api-fluent==0.3.35
ansys-api-geometry==0.4.42
ansys-api-mapdl==0.5.2
ansys-api-mechanical==0.1.2
ansys-api-meshing-prime==0.1.4
ansys-api-modelcenter==0.3.1
ansys-api-platform-instancemanagement==1.1.2
ansys-api-pyensight==0.4.7
ansys-api-sherlock==0.1.35
ansys-api-systemcoupling==0.2.0
ansys-api-tools-filetransfer==0.1.1
ansys-api-workbench==0.2.0
ansys-conceptev-core==0.8
ansys-dpf-composites==0.6.2
ansys-dpf-core==0.13.4
ansys-dpf-post==0.9.2
ansys-dyna-core==0.7.1
ansys-dynamicreporting-core==0.9.0
ansys-edb-core==0.1.9
ansys-engineeringworkflow-api==0.1.0
ansys-fluent-core==0.29.0
ansys-geometry-core==0.9.1
ansys-grantami-bomanalytics==2.2.0
ansys-grantami-bomanalytics-openapi==3.1.0
ansys-grantami-jobqueue==1.1.0
ansys-grantami-recordlists==1.3.0
ansys-grantami-serverapi-openapi==4.0.0
ansys-hps-client==0.9.1
ansys-mapdl-core==0.68.6
ansys-mapdl-reader==0.54.2
ansys-math-core==0.2.2
ansys-mechanical-core==0.11.13
ansys-mechanical-env==0.1.9
ansys-mechanical-stubs==0.1.6
ansys-meshing-prime==0.7.0
ansys-modelcenter-workflow==0.1.1
ansys-motorcad-core==0.7.0
ansys-openapi-common==2.2.2
ansys-optislang-core==0.9.4
ansys-platform-instancemanagement==1.1.2
ansys-pyensight-core==0.9.10
ansys-pythonnet==3.1.0rc6
ansys-rocky-core==0.3.2
ansys-seascape==0.2.0
ansys-sherlock-core==0.8.2
ansys-simai-core==0.2.6
ansys-sound-core==0.1.3
ansys-systemcoupling-core==0.8.0
ansys-tools-filetransfer==0.1.1
ansys-tools-local-product-launcher==0.1.1
ansys-tools-path==0.7.1
ansys-tools-visualization-interface==0.8.3
ansys-turbogrid-api==0.4.4
ansys-turbogrid-core==0.4.1
ansys-units==0.4.0
ansys-workbench-core==0.8.0
anyio==4.9.0
appdirs==1.4.4
asgiref==3.8.1
asttokens==3.0.0
attrs==24.2.0
backoff==2.2.1
bcrypt==4.3.0
beartype==0.19.0
bleach==6.2.0
bokeh==3.4.3
build==1.2.2.post1
cachetools==5.5.2
certifi==2025.1.31
cffi==1.17.1
charset-normalizer==3.4.1
click==8.1.8
clr_loader==0.2.7.post0
colorama==0.4.6
contourpy==1.3.1
cryptography==44.0.2
cycler==0.12.1
dataclasses-json==0.6.7
decorator==5.2.1
defusedxml==0.7.1
Deprecated==1.2.18
dill==0.3.9
Django==4.2.20
django-guardian==2.4.0
djangorestframework==3.16.0
docker==7.1.0
elementpath==4.8.0
executing==2.2.0
fabric==3.2.2
filelock==3.18.0
flexcache==0.3
flexparser==0.4
fonttools==4.57.0
fpdf2==2.8.2
frozenlist==1.5.0
geomdl==5.3.1
google-api-core==2.24.2
google-api-python-client==2.166.0
google-auth==2.38.0
google-auth-httplib2==0.2.0
googleapis-common-protos==1.69.2
grpcio==1.67.1
grpcio-health-checking==1.62.3
grpcio-status==1.62.3
h11==0.14.0
hollerith==0.6.0
httpcore==1.0.7
httplib2==0.22.0
httpx==0.28.1
idna==3.10
importlib_metadata==8.6.1
invoke==2.2.0
ipython==9.0.2
ipython_pygments_lexers==1.1.1
jedi==0.19.2
Jinja2==3.1.6
joblib==1.4.2
jsonschema==4.23.0
jsonschema-specifications==2024.10.1
kiwisolver==1.4.8
linkify-it-py==2.0.3
lxml==5.3.1
Markdown==3.7
markdown-it-py==3.0.0
MarkupSafe==3.0.2
marshmallow==3.26.1
marshmallow-oneofschema==3.1.1
matplotlib==3.10.1
matplotlib-inline==0.1.7
mdit-py-plugins==0.4.2
mdurl==0.1.2
more-itertools==10.6.0
msal==1.32.0
msal-extensions==1.3.1
msgpack==1.1.0
multidict==6.2.0
mypy-extensions==1.0.0
networkx==3.4.2
nltk==3.9.1
numpy==2.2.4
overrides==7.7.0
packaging==24.2
pandas==2.2.3
panel==1.4.4
param==2.2.0
paramiko==3.5.1
parso==0.8.4
patsy==1.0.1
pillow==11.1.0
Pint==0.24.4
platformdirs==4.3.7
plumbum==1.9.0
pooch==1.8.2
prompt_toolkit==3.0.50
propcache==0.3.1
proto-plus==1.26.1
protobuf==4.25.6
psutil==7.0.0
pure_eval==0.2.3
pyaedt==0.15.0
pyansys==2025.1.3
pyansys-tools-report==0.8.2
pyansys-tools-variableinterop==0.1.1
pyansys-tools-versioning==0.6.0
pyasn1==0.6.1
pyasn1_modules==0.4.2
pycparser==2.22
pydantic==2.10.6
pydantic_core==2.27.2
pyedb==0.37.0
pygltflib==1.16.3
Pygments==2.19.1
pygranta==2025.1.0
pyiges==0.3.1
PyJWT==2.10.1
PyNaCl==1.5.0
pyparsing==3.2.3
pypiwin32==223
pypng==0.20220715.0
pyproject_hooks==1.2.0
Pyro5==5.15
pyspnego==0.11.2
python-dateutil==2.9.0.post0
python-dotenv==1.1.0
python-pptx==0.6.19
pytwin==0.7.0
pytz==2025.2
pyvista==0.44.2
pyviz_comms==3.0.4
pywin32==310
PyYAML==6.0.2
referencing==0.35.1
regex==2024.11.6
requests==2.32.3
requests-negotiate-sspi==0.5.2
requests-toolbelt==1.0.0
requests_ntlm==1.3.0
rpds-py==0.24.0
rpyc==6.0.1
rsa==4.9
rtree==1.4.0
scikit-rf==1.6.2
scipy==1.15.2
scooby==0.10.0
semver==3.0.4
serpent==1.41
setuptools==78.1.0
six==1.17.0
sniffio==1.3.1
sqlparse==0.5.3
sseclient-py==1.8.0
sspilib==0.2.0
stack-data==0.6.3
statsmodels==0.14.4
tabulate==0.9.0
toml==0.10.2
tomli==2.2.1
tomli_w==1.2.0
tornado==6.4.2
tqdm==4.67.1
traitlets==5.14.3
trame==3.8.1
trame-client==3.6.1
trame-server==3.4.0
trame-vtk==2.8.15
trame-vuetify==2.9.0
transformations==2025.1.1
truststore==0.10.1
typing-inspect==0.9.0
typing_extensions==4.13.1
tzdata==2025.2
tzlocal==5.3.1
uc-micro-py==1.0.3
uritemplate==4.1.1
urllib3==2.3.0
usd-core==24.8
vtk==9.3.1
wakepy==0.10.1
wcwidth==0.2.13
webencodings==0.5.1
websockets==15.0.1
wheel==0.45.1
WMI==1.5.1
wrapt==1.17.2
wslink==2.3.3
XlsxWriter==3.2.2
xmlschema==3.4.5
xyzservices==2025.1.0
yarl==1.18.3
zipp==3.21.0

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions