![]() ![]() As a general rule, when installing pre-release versions of Python in a system that has older production versions and an existing py launcher, don't install the py launcher for the pre-release version. This behavior can lead to some problems if you install a pre-release version of Python. But if you upgraded your Python 3.8 installation afterward, py wouldn’t be touched since the installer would detect that a newer version already existed. Upgrade py with new versions of PythonĪn important thing to keep in mind about the py launcher and upgrading Python versions: whenever a new version of Python is installed, the py launcher will be updated, as long as the Python version being installed is newer than the py launcher.įor instance, if you installed Python 3.8 and then Python 3.9, then 3.9 would upgrade py. If you use just -2 or -3 as the version switch, Python will launch the most recent version of Python 2.x or Python 3.x, as indicated. In the above example, only the 64-bit version is installed, so if you type py -3.10, you'll get the 64-bit version of Python 3.10. If you don’t specify a bitness, and only one bitness of a particular version is installed, that bitness will be loaded by default. IDGįour examples of the py launcher in action. So if you just typed py -3.9, you’d get the 64-bit version of Python 3.9. On a 64-bit machine, that would be the 64-bit edition. Note that if you provide only a version number, and not a bitness indicator, you’ll default to whichever version of Python is native to your machine’s processor type. For instance, to launch the 64-bit edition of Python 3.9, you would type py -3.9-64. To invoke a specific edition of Python, type py followed by the switch in the left-hand column for the appropriate version. The interpreter marked with an asterisk is the default. You’ll be presented with a list of all the known interpreters in the system, their version numbers, and their full paths. To see which versions of Python are available to py, type py -0p. py by itself will drop you into the Python REPL, which you can exit as you normally would by typing quit() or hitting Ctrl-Z. When you type py at the command line, the launcher invokes the current default Python interpreter. In the next screen, make sure you've checked the 'py launcher' option. ![]() When installing Python on Windows, select the 'Customize installation' option during setup. You can always run the Python interpreter directly instead, and py doesn’t interfere with other behaviors. The py launcher is installed directly into the Windows system directory, so it's always available. There is no downside to having py installed.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |