Skip to content

Build from Source

github-actions[bot] edited this page Apr 5, 2025 · 1 revision

csp-bot is written in Python and Javascript. While prebuilt wheels are provided for end users, it is also straightforward to build csp-bot from either the Python source distribution or the GitHub repository.

Table of Contents

Make commands

As a convenience, csp-bot uses a Makefile for commonly used commands. You can print the main available commands by running make with no arguments

> make

build                          build the library
clean                          clean the repository
fix                            run autofixers
install                        install library
lint                           run lints
test                           run the tests

Prerequisites

Clone

Clone the repo with:

git clone https://github.com/Point72/csp-bot.git
cd csp-bot

Install Python dependencies

Python build and develop dependencies are specified in the pyproject.toml, but you can manually install them:

make requirements

Note that these dependencies would otherwise be installed normally as part of PEP517 / PEP518.

Build

Build the python project in the usual manner:

make build

Lint and Autoformat

csp-bot has linting and auto formatting.

Language Linter Autoformatter Description
Python ruff ruff Style
Python ruff ruff Imports
Markdown prettier prettier Style

Python Linting

make lint

Python Autoformatting

make fix

Documentation Linting

We use prettier for our Markdown linting, so follow the above docs.

Testing

csp-bot has Python tests, which can be run via pytest. First, install the Python development dependencies with

make develop

Python

make test

Home

Get Started

For Developers

Coming soon!

For Contributors

Clone this wiki locally