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
I am using the latest version of PyMAPDL and its dependencies (fully updated virtual environment). You can update them using pip install --upgrade --upgrade-strategy eager ansys-mapdl-core in your activated virtual environment.
🔍 Description of the bug
I have tried on different PCs with different versions of the package (0.69.dev0, 0.68.4, 0.67) to use MapdlPool and it works but some client processes do not connect. I have provided a sharepoint link to the code for a minimally working example.
🕵️ Steps To Reproduce
Run impedance_conductivities.py on this folder ... (ask for link)
It relies on input files (exp_plan.csv, dura_thickness_0.33585088029503823.cdb) and 2 helper classes (FieldComputer.py and ExperiencePlanManager.py).
Give it some time, it might work at first but it will fail at some point and console will show output in logger
File "C:\Users\tletutou\OneDrive - ANSYS, Inc\issue_pool_mapdl\venv\Lib\site-packages\ansys\mapdl\core\mapdl_grpc.py", line 525, in _multi_connect
ansys.mapdl.core.errors.MapdlConnectionError: Unable to connect to MAPDL gRPC instance at dns:///127.0.0.1:50052.
Reached either maximum amount of connection attempts (5) or timeout (45 s).The MAPDL process seems to be alive (PID: 32808) but PyMAPDL cannot connect to it.
During handling of the above exception, another exception occurred:
raise MapdlConnectionError(
Traceback (most recent call last):
ansys.mapdl.core.errors.MapdlConnectionError: Unable to connect to MAPDL gRPC instance at dns:///127.0.0.1:50054.
Reached either maximum amount of connection attempts (5) or timeout (45 s).The MAPDL process seems to be alive (PID: 32736) but PyMAPDL cannot connect to it.
File "C:\Users\tletutou\AppData\Local\Programs\Python\Python311\Lib\threading.py", line 1045, in _bootstrap_inner
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "C:\Users\tletutou\AppData\Local\Programs\Python\Python311\Lib\threading.py", line 1045, in _bootstrap_inner
self.run()
File "C:\Users\tletutou\AppData\Local\Programs\Python\Python311\Lib\threading.py", line 982, in run
self.run()
File "C:\Users\tletutou\AppData\Local\Programs\Python\Python311\Lib\threading.py", line 982, in run
self._target(*self._args, **self._kwargs)
File "C:\Users\tletutou\OneDrive - ANSYS, Inc\issue_pool_mapdl\venv\Lib\site-packages\ansys\mapdl\core\pool.py", line 907, in _spawn_mapdl
self._target(*self._args, **self._kwargs)
File "C:\Users\tletutou\OneDrive - ANSYS, Inc\issue_pool_mapdl\venv\Lib\site-packages\ansys\mapdl\core\pool.py", line 907, in _spawn_mapdl
self._instances[index] = launch_mapdl(
^^^^^^^^^^^^^
File "C:\Users\tletutou\OneDrive - ANSYS, Inc\issue_pool_mapdl\venv\Lib\site-packages\ansys\mapdl\core\launcher.py", line 1831, in launch_mapdl
self._instances[index] = launch_mapdl(
^^^^^^^^^^^^^
lic_check.check()
File "C:\Users\tletutou\OneDrive - ANSYS, Inc\issue_pool_mapdl\venv\Lib\site-packages\ansys\mapdl\core\launcher.py", line 1831, in launch_mapdl
File "C:\Users\tletutou\OneDrive - ANSYS, Inc\issue_pool_mapdl\venv\Lib\site-packages\ansys\mapdl\core\licensing.py", line 191, in check
lic_check.check()
raise LicenseServerConnectionError("\n".join(self._license_file_msg))
File "C:\Users\tletutou\OneDrive - ANSYS, Inc\issue_pool_mapdl\venv\Lib\site-packages\ansys\mapdl\core\licensing.py", line 191, in check
ansys.mapdl.core.errors.LicenseServerConnectionError: Exceeded 10 seconds while waiting for D:\temp\.ansys\licdebug.AAP7yAvfo5sR80r.FEAT_ANSYS.241.out to exist.
raise LicenseServerConnectionError("\n".join(self._license_file_msg))
ansys.mapdl.core.errors.LicenseServerConnectionError: Exceeded 10 seconds while waiting for D:\temp\.ansys\licdebug.AAP7yAvfo5sR80r.FEAT_ANSYS.241.out to exist.
Exception in main loop
Traceback (most recent call last):
File "c:\Users\tletutou\OneDrive - ANSYS, Inc\issue_pool_mapdl\ExperiencePlanManager.py", line 75, in run_parallel_in_mapdl_pool
pool = MapdlPool(n_instances=n_instances, nproc=cores_per_instance, run_location=run_location, cleanup_on_exit=True, override=True, remove_temp_files=True, wait=True)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\tletutou\OneDrive - ANSYS, Inc\issue_pool_mapdl\venv\Lib\site-packages\ansys\mapdl\core\pool.py", line 374, in __init__
raise TimeoutError(
TimeoutError: Only 1 of 3 could be started.
Creating Pool: 33%|█████████████████████████████████▋ | 1/3 [01:18<02:36, 78.30s/it]
Creating Pool: 67%|███████████████████████████████████████████████████████████████████▎ | 2/3 [00:25<00:11, 11.10s/it]Exception in thread Instance_0:
Traceback (most recent call last):
File "C:\Users\tletutou\OneDrive - ANSYS, Inc\issue_pool_mapdl\venv\Lib\site-packages\ansys\mapdl\core\launcher.py", line 1808, in launch_mapdl
mapdl = MapdlGrpc(
^^^^^^^^^^
File "C:\Users\tletutou\OneDrive - ANSYS, Inc\issue_pool_mapdl\venv\Lib\site-packages\ansys\mapdl\core\mapdl_grpc.py", line 429, in __init__
raise err # Raise original error if we couldn't catch it in post-mortem analysis
^^^^^^^^^
File "C:\Users\tletutou\OneDrive - ANSYS, Inc\issue_pool_mapdl\venv\Lib\site-packages\ansys\mapdl\core\mapdl_grpc.py", line 421, in __init__
self._multi_connect(timeout=timeout)
File "C:\Users\tletutou\OneDrive - ANSYS, Inc\issue_pool_mapdl\venv\Lib\site-packages\ansys\mapdl\core\mapdl_grpc.py", line 525, in _multi_connect
raise MapdlConnectionError(
ansys.mapdl.core.errors.MapdlConnectionError: Unable to connect to MAPDL gRPC instance at dns:///127.0.0.1:50055.
Reached either maximum amount of connection attempts (5) or timeout (45 s).The MAPDL process seems to be alive (PID: 35024) but PyMAPDL cannot connect to it.
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "C:\Users\tletutou\AppData\Local\Programs\Python\Python311\Lib\threading.py", line 1045, in _bootstrap_inner
self.run()
File "C:\Users\tletutou\AppData\Local\Programs\Python\Python311\Lib\threading.py", line 982, in run
self._target(*self._args, **self._kwargs)
File "C:\Users\tletutou\OneDrive - ANSYS, Inc\issue_pool_mapdl\venv\Lib\site-packages\ansys\mapdl\core\pool.py", line 907, in _spawn_mapdl
self._instances[index] = launch_mapdl(
^^^^^^^^^^^^^
File "C:\Users\tletutou\OneDrive - ANSYS, Inc\issue_pool_mapdl\venv\Lib\site-packages\ansys\mapdl\core\launcher.py", line 1831, in launch_mapdl
lic_check.check()
File "C:\Users\tletutou\OneDrive - ANSYS, Inc\issue_pool_mapdl\venv\Lib\site-packages\ansys\mapdl\core\licensing.py", line 191, in check
raise LicenseServerConnectionError("\n".join(self._license_file_msg))
ansys.mapdl.core.errors.LicenseServerConnectionError: Exceeded 10 seconds while waiting for D:\temp\.ansys\licdebug.AAP7yAvfo5sR80r.FEAT_ANSYS.241.out to exist.
Exception in main loop
Traceback (most recent call last):
File "c:\Users\tletutou\OneDrive - ANSYS, Inc\issue_pool_mapdl\ExperiencePlanManager.py", line 75, in run_parallel_in_mapdl_pool
pool = MapdlPool(n_instances=n_instances, nproc=cores_per_instance, run_location=run_location, cleanup_on_exit=True, override=True, remove_temp_files=True, wait=True)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\tletutou\OneDrive - ANSYS, Inc\issue_pool_mapdl\venv\Lib\site-packages\ansys\mapdl\core\pool.py", line 374, in __init__
raise TimeoutError(
TimeoutError: Only 2 of 3 could be started.
****
The text was updated successfully, but these errors were encountered:
If you can launch some but not all MAPDL instances, I suspect it is either a license issue (I dont this is the case because you are Ansys employee, so you should have enough licenses) or a timeout issue. In the last case, you could try to increase the time out (start_timeout) to something like 100s.
You will get more useful printout. From the logging output, look for the directory where PyMAPDL is trying to launch MAPDL. Go to those directories and try to find any useful information in the .out and .err files.
The logging will also print the command line used to launch MAPDL, you could go the corresponding directory, open a terminal and issue the same command to launch MAPDL. Keep an eye on the terminal to look for any error print out.
🤓 Before submitting the issue
pip install --upgrade --upgrade-strategy eager ansys-mapdl-core
in your activated virtual environment.🔍 Description of the bug
I have tried on different PCs with different versions of the package (0.69.dev0, 0.68.4, 0.67) to use MapdlPool and it works but some client processes do not connect. I have provided a sharepoint link to the code for a minimally working example.
🕵️ Steps To Reproduce
Run impedance_conductivities.py on this folder ... (ask for link)
It relies on input files (exp_plan.csv, dura_thickness_0.33585088029503823.cdb) and 2 helper classes (FieldComputer.py and ExperiencePlanManager.py).
Give it some time, it might work at first but it will fail at some point and console will show output in logger
💻 Which Operating System are you using?
Windows
🐍 Which Python version are you using?
3.11
💾 Which MAPDL version are you using?
24.1
📝 PyMAPDL Report
Show the Report!
📝 Installed packages
Show the installed packages!
📝 Logger output file
Show the logger output file.
The text was updated successfully, but these errors were encountered: