I'm trying to import another package from For example,
When I'm like this, If you want to import domain.py from quiz.py
from context.domain import data
I know this is how you do it, but I don't know if you'll find a problem if I just tell you which one I'm missing When I do from context, the context does not appear as a keyword
python
Although it belongs to the same dir, it is in different subdirectories, so you need to move the path.
dir
│
├ ├ a ━ aa.py
└ └ b ━ bb.py
# bb.py
from ..a.aa.py import aaa
© 2024 OneMinuteCode. All rights reserved.