Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix for TypeError: _NamespacePath object is not reversible #1406

Merged
merged 1 commit into from
Mar 7, 2023

Conversation

tejalprabhu01
Copy link
Collaborator

Most files in optiSLang are encrypted while shipping to pye. To handle imports in these files pye_loader is used. This lead to the error shown be while in meshing mode via encrypted python scripts in optiSLang environment. The similar issue from solver was fixed as a part of this PR #700:

File "C:\Program Files\Dynardo\ANSYS optiSLang\2023 R2\lib\python3.7\lib\site-packages\ansys\fluent\core\session_meshing.py", line 46, in workflow
return super(Meshing, self).workflow if not self.switched else None
File "C:\Program Files\Dynardo\ANSYS optiSLang\2023 R2\lib\python3.7\lib\site-packages\ansys\fluent\core\session_pure_meshing.py", line 39, in workflow
return self._base_meshing.workflow
File "C:\Program Files\Dynardo\ANSYS optiSLang\2023 R2\lib\python3.7\lib\site-packages\ansys\fluent\core\session_base_meshing.py", line 92, in workflow
self.workflow = WorkflowWrapper(self.workflow_se, self.meshing)
File "C:\Program Files\Dynardo\ANSYS optiSLang\2023 R2\lib\python3.7\lib\site-packages\ansys\fluent\core\session_base_meshing.py", line 71, in meshing
self.tui,
File "C:\Program Files\Dynardo\ANSYS optiSLang\2023 R2\lib\python3.7\lib\site-packages\ansys\fluent\core\session_base_meshing.py", line 44, in tui
f"ansys.fluent.core.meshing.tui
{self.version}"
File "C:\Program Files\Dynardo\ANSYS optiSLang\2023 R2\lib\python3.7\lib\importlib_init
.py", line 127, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
File "", line 1006, in _gcd_import
File "", line 983, in _find_and_load
File "", line 963, in _find_and_load_unlocked
File "", line 902, in _find_spec
File "", line 876, in _find_spec_legacy
File "pye_loader.py", line 39, in find_module
TypeError: '_NamespacePath' object is not reversible

@seanpearsonuk
Copy link
Collaborator

Thank you, @tejalprabhu01

@tejalprabhu01 tejalprabhu01 merged commit 308e234 into main Mar 7, 2023
@tejalprabhu01 tejalprabhu01 deleted the fix_pye_loader_error branch March 7, 2023 13:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants