Sublime Forum

Python Build Error

#1

I am unable to get a Python system to build on a friends computer which runs Windows XP SP3 using Sublime Text 2. We reinstalled Python 2.7.3 and also Sublime Text 2 and still are having trouble with this. Our “Python.sublime-build” file says:

{ "cmd": "C:\\Python27\\python.exe", "-u", "$(FULL_CURRENT_PATH)"], "file_regex": "^ ]*File \"(...*?)\", line ([0-9]*)", "selector": "source.python" }

When we try to build simple Python programs, such as:

2 * 2

Sublime Text will not build the system, and will instead spit out:

C:\Python27\python.exe: can't find '__main__' module in '' [Finished in 0.1s with exit code 1]

It would be wonderful if I could get some help with this. Thank you so much whoever assists me with this!

0 Likes

#2

{ "cmd": "C:\\Python27\\python.exe", "-u", "$file"], "file_regex": "^ ]*File \"(...*?)\", line ([0-9]*)", "selector": "source.python" }

This is what my new code for the Python build file looks like, yet it still does not work.

0 Likes