Closed ksraichur closed 8 months ago
Hi @ksraichur
Can you try again but logging to a file?
from ansys.mapdl.core import LOG
LOG.setLevel("DEBUG")
LOG.log_to_file("mylog.log")
from ansys.mapdl.core import launch_mapdl
mapdl = launch_mapdl(loglevel="DEBUG")
Reference: https://mapdl.docs.pyansys.com/version/dev/user_guide/troubleshoot.html#debug-in-pymapdl
Update: Launching a gRPC MAPDL session (ansys232 -grpc) and then connecting to it seems to be working fine.
Interesting...
Let's try to run the following.
Create a directory somewhere.
Open the terminal, and go inside that directory
Run the following command:
"C:\Program Files\ANSYS Inc\v231\ansys\bin\winx64\ansys231.exe" -j file -np 2 -port 50052 -grpc
this should print something in the terminal. Copy/paste it here please.
@germa89 I don't have v231 on my computer. Only v222, 232, and 241. Below is the output from the above command: "The system cannot find the path specified."
Interesting... that's the issue. From the log file you posted, it seems PyMAPDL is trying to start the 231 version, but you are right, it does not exist.
The solution would be then:
mapdl = launch_mapdl(exec_file ="C:\\Program Files\\ANSYS Inc\\v231\\ansys\\bin\\winx64\\ansys231.exe")
I wonder why MAPDL is trying to start v231.... Do you have any PYMAPDL_***
en vars?? Like PYMAPDL_MAPDL_EXEC
, or PYMAPDL_MAPDL_VERSION
. Can you post them here?
@germa89 - There are no environment variables starting with "py". And v232 works (see image below).
Perfect then. I feel curious to know why it was trying another version of PyMAPDL... Anyways, I'm closing this issue. Thank you for posting it!
π€ Before submitting the issue
pip install --upgrade --upgrade-strategy eager ansys-mapdl-core
in your activated virtual environment.π Description of the bug
PyMAPDL fails to launch and gives the following traceback.
Click to add a cell.
π΅οΈ Steps To Reproduce
π» Which Operating System are you using?
Windows
π Which Python version are you using?
3.10
π PyMAPDL Report
Show the Report!
```text PyMAPDL Software and Environment Report Packages Requirements ********************* Core packages ------------- ansys.mapdl.core : 0.67.0 numpy : 1.26.3 platformdirs : 4.1.0 scipy : 1.12.0 grpc : Package not found ansys.api.mapdl.v0 : Package not found ansys.mapdl.reader : 0.53.0 google.protobuf : Package not found Optional packages ----------------- matplotlib : 3.8.2 pyvista : 0.43.2 pyiges : 0.3.1 tqdm : 4.66.1 Ansys Installation ****************** Version Location ------------------ 222 C:\Program Files\ANSYS Inc\v222 232 C:\Program Files\ANSYS Inc\v232 241 C:\Program Files\ANSYS Inc\v241 Ansys Environment Variables *************************** ANSYS211_PRODUCT_NO mech_2 ANSYS222_DIR C:\Program Files\ANSYS Inc\v222\ANSYS ANSYS232_DIR C:\Program Files\ANSYS Inc\v232\ANSYS ANSYS241_DIR C:\Program Files\ANSYS Inc\v241\ANSYS ANSYSCLOUDCLI_ROOT C:\Program Files\ANSYS Inc\ANSYS Cloud\ANSYS Cloud CLI\ ANSYSELECTRON_ROOT C:\Program Files\ANSYS Inc\ANSYS Cloud\ANSYS Electron\ ANSYSEM_ROOT232 C:\Program Files\AnsysEM\v232\Win64 ANSYSEM_ROOT241 C:\Program Files\AnsysEM\v241\Win64 ANSYSGPU_OVERRIDE 1 ANSYSLIC_DIR C:\Program Files\ANSYS Inc\Shared Files\Licensing ANSYSLI_ELASTIC 1 ANSYSLI_LCP 1 ANSYSLI_TIMEOUT_TCP 300 ANSYS_ELASTIC_PROJECT Test_Project ANSYS_SYSDIR winx64 ANSYS_SYSDIR32 win32 AWP_LOCALE222 en-us AWP_LOCALE232 en-us AWP_LOCALE241 en-us AWP_ROOT222 C:\Program Files\ANSYS Inc\v222 AWP_ROOT232 C:\Program Files\ANSYS Inc\v232 AWP_ROOT241 C:\Program Files\ANSYS Inc\v241 CADOE_LIBDIR222 C:\Program Files\ANSYS Inc\v222\CommonFiles\Language\en-us CADOE_LIBDIR232 C:\Program Files\ANSYS Inc\v232\CommonFiles\Language\en-us CADOE_LIBDIR241 C:\Program Files\ANSYS Inc\v241\CommonFiles\Language\en-us ```π Installed packages
Show the installed packages!
```text ansys-api-mapdl==0.5.1 ansys-api-platform-instancemanagement==1.0.0 ansys-mapdl-core==0.67.0 ansys-mapdl-reader==0.53.0 ansys-math-core==0.1.3 ansys-platform-instancemanagement==1.1.2 ansys-tools-path==0.4.1 anyio==4.2.0 appdirs==1.4.4 argon2-cffi==23.1.0 argon2-cffi-bindings==21.2.0 arrow==1.3.0 asttokens==2.4.1 async-lru==2.0.4 attrs==23.2.0 Babel==2.14.0 beautifulsoup4==4.12.3 bleach==6.1.0 certifi==2023.11.17 cffi==1.16.0 charset-normalizer==3.3.2 click==8.1.7 colorama==0.4.6 comm==0.2.1 contourpy==1.2.0 cycler==0.12.1 debugpy==1.8.0 decorator==5.1.1 defusedxml==0.7.1 exceptiongroup==1.2.0 executing==2.0.1 fastjsonschema==2.19.1 fonttools==4.47.2 fqdn==1.5.1 geomdl==5.3.1 grpcio==1.60.0 idna==3.6 importlib-metadata==7.0.1 ipykernel==6.29.0 ipython==8.20.0 isoduration==20.11.0 jedi==0.19.1 Jinja2==3.1.3 json5==0.9.14 jsonpointer==2.4 jsonschema==4.21.1 jsonschema-specifications==2023.12.1 jupyter-events==0.9.0 jupyter-lsp==2.2.2 jupyter_client==8.6.0 jupyter_core==5.7.1 jupyter_server==2.12.5 jupyter_server_terminals==0.5.2 jupyterlab==4.0.11 jupyterlab_pygments==0.3.0 jupyterlab_server==2.25.2 kiwisolver==1.4.5 MarkupSafe==2.1.4 matplotlib==3.8.2 matplotlib-inline==0.1.6 mistune==3.0.2 nbclient==0.9.0 nbconvert==7.14.2 nbformat==5.9.2 nest-asyncio==1.6.0 notebook_shim==0.2.3 numpy==1.26.3 overrides==7.6.0 packaging==23.2 pandocfilters==1.5.1 parso==0.8.3 pillow==10.2.0 platformdirs==4.1.0 pooch==1.8.0 prometheus-client==0.19.0 prompt-toolkit==3.0.43 protobuf==3.20.3 psutil==5.9.8 pure-eval==0.2.2 pyansys-tools-versioning==0.5.0 pycparser==2.21 Pygments==2.17.2 pyiges==0.3.1 pyparsing==3.1.1 python-dateutil==2.8.2 python-json-logger==2.0.7 pyvista==0.43.2 pywin32==306 pywinpty==2.0.12 PyYAML==6.0.1 pyzmq==25.1.2 referencing==0.32.1 requests==2.31.0 rfc3339-validator==0.1.4 rfc3986-validator==0.1.1 rpds-py==0.17.1 scipy==1.12.0 scooby==0.9.2 Send2Trash==1.8.2 six==1.16.0 sniffio==1.3.0 soupsieve==2.5 stack-data==0.6.3 terminado==0.18.0 tinycss2==1.2.1 tomli==2.0.1 tornado==6.4 tqdm==4.66.1 traitlets==5.14.1 types-python-dateutil==2.8.19.20240106 typing_extensions==4.9.0 uri-template==1.3.0 urllib3==2.1.0 vtk==9.3.0 wcwidth==0.2.13 webcolors==1.13 webencodings==0.5.1 websocket-client==1.7.0 zipp==3.17.0 ```π Logger output file
Show the logger output file.
```text # PASTE HERE THE CONTENT OF THE LOGGER OUTPUT FILE. ```