Get Started¶
It is highly recommended to install in a virtual environment to keep your system in order.
Installing with uv (recommended)¶
The following command installs the latest stable version of the library:
uv pip install aresilient
To install the latest development version from GitHub:
uv pip install git+https://github.com/durandtibo/aresilient.git
To install a specific version:
uv pip install aresilient==0.3.0
Installing with pip¶
The following command installs the latest stable version of the library:
pip install aresilient
To install the latest development version from GitHub:
pip install git+https://github.com/durandtibo/aresilient.git
To install a specific version:
pip install aresilient==0.3.0
Verifying Installation¶
After installation, you can verify that aresilient is correctly installed by running:
python -c "import aresilient; print(aresilient.__version__)"
Or try a simple example:
from aresilient import get
# Make a simple GET request (this is a safe example that won't actually execute)
# response = get("https://api.example.com/data")
# print(response.json())
# Verify the module is properly imported
print("aresilient imported successfully!")
Testing Async Support¶
To verify async support is working:
import asyncio
from aresilient import get_async
async def test_async():
print("Async support is working!")
return True
result = asyncio.run(test_async())
print(f"Test result: {result}")
Installing from source¶
To install aresilient from source, you can follow the steps below.
Prerequisites¶
This project uses uv for dependency management. Please refer to
the uv installation documentation for
installation instructions.
Clone the Repository¶
git clone git@github.com:durandtibo/aresilient.git
cd aresilient
Create a Virtual Environment¶
It is recommended to create a Python 3.10+ virtual environment:
make setup-venv
This command creates a virtual environment using uv and installs all dependencies including
development tools.
Alternatively, you can create a conda virtual environment:
make conda
conda activate aresilient
make install
Install Dependencies¶
To install only the core dependencies:
make install
To install all dependencies including documentation tools:
make install-all
Verify Installation¶
You can test the installation with the following command:
make unit-test-cov
This will run the test suite with coverage reporting.
Development Setup¶
If you plan to contribute to aresilient, please also install the development tools.
Using uv:
uv pip install -e ".[dev,docs]"
Using pip:
pip install -e ".[dev,docs]"
Then install the pre-commit hooks:
pre-commit install
See CONTRIBUTING.md for more information about contributing.