I just installed Python 3.9.9 and Sublime on my Windows laptop. I set up and configured the program as specified in “Python Crash Course, 2nd Ed.” Yet when I try to run my hello_world.py file it gives me an error message that reads as “No Build System.” How can I fix this? I would greatly appreciate any help.
When I click ctrl-b it returns "No Build System" as response
Conditions that can cause this message to appear are:
-
In
Tools > Build System
, there is nothing selected (no build, notAutomatic
, just nothing). If that’s the case, select an appropriate build from the menu or set it toAutomatic
to let Sublime try to decide. -
In
Tools > Build System
, the setting isAutomatic
but based on the current type of file there is no suitable build system. If that’s the case you would need to install a package or set up a build for the appropriate case. Or, if you created your own build, it might not have the metadata required to allow Sublime to select it, in which case pick your custom build from the menu. -
In
Tools > Build System
the setting is a specific build you set up. If that’s the case, then thesublime-build
file isn’t valid JSON and Sublime can’t parse it. Items appear in the menu based on their file name but are not loaded until you try to actually build with them.
Thank you. I have it set for Tools > Build System > Python3. What do I need to do?
In that case your problem sounds like #3 ; open the build and then paste the contents of it into a checker like jsonlint.com to see if it has any errors that are stopping it from being valid JSON.
When I type: print(“Hello world!”)
I get this message:
Error: Parse error on line 1:
print(“Hello world!”
^
Expecting ‘STRING’, ‘NUMBER’, ‘NULL’, ‘TRUE’, ‘FALSE’, ‘{’, ‘[’, got ‘undefined’
The book I’m working with has not yet mentioned the need to define variables as strings or numbers etc. I thought the quotation marks allowed the compiler to understand that it was supposed to print a series of string variables or a list of string variables. What am I missing?
That looks like you pasted your Python code into the JSON lint tool. You want to open the Python3.sublime-build
file (the extension is always sublime-build
because it’s a build system, and Python3
comes from the name of the build system in the menu.
You can use View Package File
from the command palette to find and open that file, which should be in your User
package most likely.
No build system.
{
“cmd”: [“HTML”, “$file”],
“selector”: “source.HTML”,
}(yy.sublime-build)
i have just two files one is yy.sublime-build and index.html
how can i show output in google chrome. is there any other way of running code
probably easier for you to use something like https://packagecontrol.io/packages/View%20In%20Browser than some fictional HTML
command line tool and a build system selector which won’t match
Is there any other option to run code except writing commands. Why it is so difficult to run in sublime text 3