[Tutor] Regarding importing from a sub-directory

Cameron Simpson cs at cskk.id.au
Sat Feb 10 19:52:13 EST 2024


On 11Feb2024 06:53, Phil <phillor9 at gmail.com> wrote:
>On 10/2/24 19:19, Alan Gauld via Tutor wrote:
>>I suspect the real solution is for you to modify the PYTHONPATH
>>or sys.path values to include ~/Python.
>
>This is another of my messages that I wish I could have cancelled.
>
>I found the problem shortly after posting my plea for help and it's 
>IDLE. The library is found if I run my project from the command line 
>and VS Code has no problem finding the library.

IMO, cancelling the message isn't a great choice. Better to just 
followup to it saying: "solved! this is how I fixed my problem" and 
describing what you did. That way people can benefit from what you 
learnt and possibly suggest a better approach if there is one.

There's no shame in encountering a problem and initially being stumped 
by it.


More information about the Tutor mailing list