Python can be downloaded from their official website for macOS, Linux or Windows.
Use the latest Python 3 version available.
pkg
installer, e.g.: macOS 64-bit installer- Important: Make sure to add Python to your PATH.
- Installer, e.g.: Windows x86-64 executable installer
- Important: Make sure to add Python to your PATH.
- You can use your package manager to search and install it (Recommended)
- Debian/Ubuntu:
apt-get install python3
- Fedora:
dnf install python3
- Arch:
pacman -S python
- Optionally you can download the source and compile it from scratch.
-
macOS and Linux:
- Open a terminal and type
python
you should see something like this:Python 3.7.2 (default, Jan 10 2019, 23:51:51) [GCC 8.2.1 20181127] on linux Type "help", "copyright", "credits" or "license" for more information. >>>
- Open a terminal and type
-
Important: In some systems you should execute
python3
instead. -
Windows
- Open
cmd
by typingWindowsKey + r
, then writingcmd
andEnter
. - Type
python
orpython3
and you should see something like:Python 3.7.2 (default, Jan 10 2019, 23:51:51) [GCC 8.2.1 20181127] on linux Type "help", "copyright", "credits" or "license" for more information. >>>
- Open
It is recommendable to use virtualenv
to create a separate Python environment
where we can install packages freely, without affecting the installed modules
that are installed in the system.
- Install
virtualenv
pip install virtualenv
- Create a virtual environment:
virtualenv workshop
- Activate the virtual environment:
source workshop/bin/activate
- Verify where is your python executable. It should be inside the virtual environment.
which python > ~/workshop/bin/python
- Activate your virtual environment (optional)
- Install
PySide6
via pippip install PySide6
- Execute
python
and try to import the moduleimport PySide6
, if no error appeared, you successfully installed it. Something like this:>>> import PySide6 >>>