-
Notifications
You must be signed in to change notification settings - Fork 48
Open
Description
Purpose of the improvement
This refers to point 5.1 in the documentation https://iffmd.fz-juelich.de/zXxTrardSNaJc4a22gNypw?view
When it comes to importing, wildcard import sign is used in all init.py, such as this line in
Line 15 in c28d5b8
| from .subclasses import * |
Example from fine/init.py
from .subclasses import *
from .IOManagement import *
from .aggregations import *
This can cause the following issues:
- Makes it unclear which symbols are exported
- Can lead to namespace pollution
- Harder to track where imports come from
- Ruff linter specifically ignores F403 (wildcard import warnings) in config
Proposal
Hence, fixing this is desirable (if necessary) and could be done by doing so:
- Define explicit all lists in each module
- Or migrate to explicit imports in init.py files
- Note: This is a large refactor affecting the entire project structure
NOTES:
Do we want to prevent wildcard imports?
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels