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

import Ansys in __init__.py files causing circular import #80

Open
2 tasks done
klmcadams opened this issue Oct 21, 2024 · 0 comments
Open
2 tasks done

import Ansys in __init__.py files causing circular import #80

klmcadams opened this issue Oct 21, 2024 · 0 comments
Labels
bug Something isn't working

Comments

@klmcadams
Copy link
Collaborator

🔍 Before submitting the issue

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

🐞 Description of the bug

import Ansys was added to __init__.py files containing code, which causes a circular import of the autocomplete. This import statement is required for type hints to work in the submodules

📝 Steps to reproduce

See Ansys/ACT/Automation/Mechanical/__init__.py, containing code and import Ansys

When doing autocomplete, this circular import will happen:

Ansys.ACT.Automation.Mechanical.Ansys...

  • import pattern will begin from the top: Ansys -> ACT or Mechanical, etc.

💻 Which operating system are you using?

Windows

📀 Which ANSYS version are you using?

N/A

🐍 Which Python version are you using?

3.10

📦 Installed packages

N/A
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant