Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

Python IDLE

Yosef Fastow
Yosef Fastow
18,526 Points

Using IDLE on command prompt on PC?

I tried to run python files I created on command prompt and it gives an error that idle_test.py doesn't exist. The only way I could figure out how to run the file is by doing like the lesson by directly on the IDLE file by pressing on Run ont he top and then pressing on Run Module.

So I guess what I am wondering is if it possible to run files created from IDLE either through command prompt or the python shell like we do in in the workspace by typing "python idle_test.py" or does it only work by going to the file?

1 Answer

Yosef Fastow
Yosef Fastow
18,526 Points

Don't worry I found out the problem. It is possible to use IDLE like we used it on treehouse workspace. The problem was I saved the file in Documents so I needed to type "cd ./Documents" so we are zoomed into that folder and then type "python idle_test.py"