Hi everyone, a little question. Does pants changed...
# general
m
Hi everyone, a little question. Does pants changed goal is working at the file level or module level? If I import file a from some module and only file be changed will my app be triggered as changed or not?
b
File-level, but files within a modules often have 'unexpected' dependencies between them. For instance, if you have
Copy code
- module/
  - __init__.py
  - a.py
  - b.py
And
__init__.py
reexports a few things (to allow
from module import X, Y
):
Copy code
from a import X
from b import Y
__all__ = ['X', 'Y']
then
from module.a import something_else
will depend on
b
too. An import statement like that implies a dependencies on
__init__.py
, and
__init__.py
depends on
b
.
Does that answer your question?
m
thx for your answer, I didn’t fully understood your example
b
Okay, sorry. Feel free to ask questions to clarify