Python Forum
Strange issue with tkcalendar - Printable Version

+- Python Forum (https://python-forum.io)
+-- Forum: Python Coding (https://python-forum.io/forum-7.html)
+--- Forum: General Coding Help (https://python-forum.io/forum-8.html)
+--- Thread: Strange issue with tkcalendar (/thread-39734.html)



Strange issue with tkcalendar - dady - Apr-04-2023

Hi all,

Like it says in the subject i have a strange issue with tkcalendar.

I have this line of code on script 1.py:

result = subprocess.run(['python', '2.py'], capture_output=True, text=True)
which calls script 2.py

i get an error message on the script 2.py when i do debug :

Error:
(<class 'ModuleNotFoundError'>, ModuleNotFoundError("No module named 'tkcalendar'"), <traceback object at 0x000001CD2AFA7500>)
even though i have installed tkcalendar and i have the code on the script:
from tkcalendar import Calendar
Now for the strange thing. When i run the first script that calls the second one nothing happens and script 2 doesn't run.
When i run script 2 by itself, it runs perfectly.

The strangest thing is that i ran the same scripts on my work computer and they work fine.

I'm working with pycharm

So... any help will be appreciated.


RE: Strange issue with tkcalendar - dady - Apr-04-2023

OK, i managed to solve it.

It seems that the Python Interpreter on Pycharm was configured to a wrong path. Once i configured it to the right one and installed all packages everything was back to normal.

Strange it worked until now, but hey, now its fine :-)