Skip to main content

PyRat


This repository contains the software used in the
computer science course at IMT Atlantique.


The course is available at this address:
https://hub.imt-atlantique.fr/ueinfo-fise1a.


The documentation is available at this address:
https://bastienpasdeloup.github.io/PyRat.


Prerequisites

  • This installation procedure assumes that you have basic knowledge about shell manipulation.

  • PyRat uses uv to manage Python and the libraries it needs.
    You do not need to install Python yourself: uv takes care of it, and PyRat workspaces are configured to use Python 3.13 (Python 3.12 is also supported).

  • Finally, we will test PyRat installation using Visual Studio Code (VSCode), as this is the main tool we use in the associated course. Please make sure it is already installed, or install it from the official website. Note that you can use a different tool if you want, but we just provide indications for that one here.

Install uv

If uv is not installed on your machine yet, install it as follows:

  • Linux: curl -LsSf https://astral.sh/uv/install.sh | sh.
  • MacOS: curl -LsSf https://astral.sh/uv/install.sh | sh.
  • Windows (PowerShell): powershell -ExecutionPolicy ByPass -c "irm https://astral.sh/uv/install.ps1 | iex".

Other installation methods are described in the uv documentation.
Then, close and reopen your terminal, and check that uv is available by running uv --version.

Setup your PyRat workspace

We are now going to create a workspace for PyRat.
This is a directory that contains minimal working examples to get started, and in which PyRat is installed.
To do so, follow these steps:

  1. Open a terminal, and navigate (use the cd command) to the directory where you want to create your PyRat workspace.
  2. Run the following command (it is the same on all systems): uvx --from pyrat-game pyrat-init.

You should see something like this:

Initialized project `pyrat-workspace` at `/path/to/pyrat_workspace`
Workspace initialized as a uv project using Python >=3.12,<3.14
Workspace created in /path/to/pyrat_workspace
Using CPython 3.13.13
Creating virtual environment at: .venv
Resolved 19 packages in 132ms
Installed 18 packages in 48ms
PyRat added to the dependencies of the workspace
Workspace added to Python path
Your workspace is ready! You can now start coding your players and run games.
To run a game, go to the workspace using 'cd pyrat_workspace', then use for instance 'uv run pyrat_workspace/games/sample_game.py'.

You should have a new directory called pyrat_workspace in the directory where you ran the command.
If you prefer another name, pass it to the command, as in uvx --from pyrat-game pyrat-init my_workspace.

Check your installation

Now, we are going to verify that PyRat works properly.
To do so, follow these steps:

  1. Open a terminal, and navigate to your workspace using cd pyrat_workspace.
  2. Run the sample game as follows: uv run pyrat_workspace/games/sample_game.py.

You can also run your games from VSCode.
To do so, follow these steps:

  1. Open VSCode, and add your pyrat_workspace directory in your VSCode workspace.
  2. Open the file sample_game.py in directory pyrat_workspace/games/.
  3. Make sure VSCode is using the interpreter located in the .venv directory of your workspace.
  4. Run sample_game.py.

In both cases, you should see something like this:

Add other libraries to your workspace

Your workspace is a uv project, so you can add any library you need to it.
To do so, run uv add from your workspace, as in uv add numpy.
The library is then available in your players and games, with no need to activate anything.

Troubleshooting

  • In case of a problem, please check the existing GitHub issues first.

  • If the problem persists, you can add an issue of your own.

  • For students at IMT Atlantique, you can also ask your questions on the Discord server of the course.

  • Finally, you can contact Bastien Pasdeloup directly.

Metadata

Release files for pyrat-game 6.4.2

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for pyrat-game 6.4.2
File Size Uploaded
pyrat_game-6.4.2.tar.gz 4.2 MB Details

Built distribution (wheel)

Table of built distributions (wheels) for pyrat-game 6.4.2
File Interpreter ABI Platform
pyrat_game-6.4.2-py3-none-any.whl Python 3 none any Details

Total release size: 8.5 MB

Release files / pyrat_game-6.4.2.tar.gz

Download URL pyrat_game-6.4.2.tar.gz
Size 4.2 MB
Tags Source
SHA-256 checksum
How to use checksums
6e93b622c17874e77a467fa0aa0c69c8e8dd4eb89f3fbe599638be3244ef8f9d
BLAKE2b-256 checksum
How to use checksums
63d299ac1093e2dbfc2d13c9dbf4762fa93f8c0deda28daf898e0473ab351b82
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Sep 22, 2026.

Transparency log

Release files / pyrat_game-6.4.2-py3-none-any.whl

Download URL pyrat_game-6.4.2-py3-none-any.whl
Size 4.3 MB
Tags Python 3
SHA-256 checksum
How to use checksums
281bf5862809c9aaa5051168a3036c8c10f7c4b74847874ab9a94e065ac7ca27
BLAKE2b-256 checksum
How to use checksums
2aa03c588e919cdf84cfee65744694d141eb7939f7f2fc3eb0a1dfca5a7f20b3
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Sep 22, 2026.

Transparency log

Release history Release notifications | RSS feed

6.7.0

2 release files

6.6.3

2 release files

6.6.2

2 release files

6.6.1

2 release files

6.6.0

2 release files

6.5.4

2 release files

6.5.3

2 release files

6.5.2

2 release files

6.5.1

2 release files

6.5.0

2 release files

6.4.10

2 release files

6.4.9

2 release files

6.4.8

2 release files

6.4.7

2 release files

6.4.6

2 release files

6.4.4

2 release files

6.4.3

2 release files

This release

6.4.2 This release

2 release files

6.4.1

2 release files

6.4.0

2 release files

6.3.1

2 release files

6.3.0

2 release files

6.2.14

2 release files

6.2.13

2 release files

6.2.9

2 release files

6.2.8

2 release files

6.2.7

2 release files

6.2.6

2 release files

6.2.5

2 release files

6.2.4

2 release files

6.2.3

2 release files

6.2.2

2 release files

6.2.1

2 release files

6.2.0

2 release files

6.1.2

2 release files

6.1.1

2 release files

6.1.0

2 release files

6.0.6

2 release files

6.0.5

2 release files

6.0.4

2 release files

6.0.3

2 release files

6.0.2

2 release files

6.0.1

2 release files

6.0.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page