This repo includes exercises to accompany Skiller Whale sessions on the core features of Python 3
During each session you'll be asked to write and edit code in some of the files.
-
Clone the repository at
https://github.com/skiller-whale/core-python.git
onto your computer. -
If this isn't your first Core Python session, then navigate to the exercises you cloned last time, and ensure you have the latest code by running
git pull
. -
Open the repository directory in a code editor, and replace the contents of the
attendance_id
file, so that it just contains your unique id for the session. -
In a terminal, navigate to the directory of the repository you just cloned, then run the following two commands:
docker compose up --build -d
docker compose run exercises
The very first time you run this it might take a while to download and build some docker images, but the future times you run it should be quicker.
Python is installed inside the Docker container you downloaded, so you won't need to separately install it, and running the exercises won't affect any other local Python installations.
The docker compose up
process will continue running in the background, and watch for any file changes in the repo.
Make sure your Python version is >= 3.10
. You can check the version you have installed by running:
python3 --version
-
Clone the repository at
https://github.com/skiller-whale/core-python.git
onto your computer. -
In a terminal, navigate to the
core-python
directory you cloned. -
Make sure you have the
requests
package installed in a Python 3 environment. You could do that by running these two commands:
python3 -m ensurepip
python3 -m pip install requests
-
To check this is all set up, run
python3 sync.py
and enter your unique user id when prompted. You shouldn't see any errors. -
When you need to stop the sync script, you can terminate it with
Ctrl + C
.