Installation
This guide will walk you through installing SPOC on your system.
Prerequisites
SPOC requires Python 3.13 or higher. Before installing, ensure you have a compatible Python version:
Python Version
SPOC is built to leverage the latest Python features and requires Python >= 3.13. If you need to upgrade Python, visit python.org.
Installation Methods
Using pip
The simplest way to install SPOC is using pip:
Using uv
uv is a fast Python package installer and resolver. To install SPOC with uv:
Downloaded 1 package in 100ms
Installed 1 package in 5ms
+ spoc==0.1.0
Why uv?
uv is significantly faster than pip and provides better dependency resolution. It's especially useful for large projects with many dependencies.
Development Installation
If you want to contribute to SPOC or modify it for your needs, you can install it from source:
-
Clone the repository:
git clone https://github.com/hlop3z/spoc.gitCloning into 'spoc'...
remote: Enumerating objects: 100, done.
remote: Counting objects: 100% (100/100), done.
remote: Compressing objects: 100% (75/75), done.
Receiving objects: 100% (100/100), done. -
Navigate to the project directory:
cd spoc -
Install in editable mode:
pip install -e .Obtaining file:///path/to/spoc
Installing collected packages: spoc
Running setup.py develop for spoc
Successfully installed spocOr with development dependencies:
pip install -e ".[dev]"Obtaining file:///path/to/spoc
Installing collected packages: spoc, pytest, ruff
Successfully installed spoc pytest-9.0.2 ruff-0.14.13
Editable Mode
The -e flag installs the package in editable mode, meaning changes to the source code are immediately reflected without reinstalling.
Verifying Installation
After installation, verify that SPOC is correctly installed by importing it in Python:
>>> import spoc
>>> print(spoc.__version__)
0.1.0
>>> print(spoc.__about__.__title__)
spoc
You can also verify the installation by checking the available modules:
>>> from spoc import Framework, Schema
>>> from spoc.components import component
>>> print("SPOC is ready to use!")
SPOC is ready to use!
If the import succeeds without errors, SPOC is successfully installed and ready to use!
Next Steps
Now that you have SPOC installed, you can:
- Follow the Quick Start guide to build your first SPOC application
- Learn about Configuration to set up your project
- Explore the Framework documentation to understand core concepts
Troubleshooting
Python Version Issues
If you encounter a version error:
You need to upgrade to Python 3.13 or higher. Check your Python version with python --version and install the required version.
Import Errors
If you get an import error after installation:
Ensure you're using the same Python environment where you installed SPOC. If you're using virtual environments, make sure it's activated.
Permission Errors
If you encounter permission errors during installation on Linux/macOS:
The --user flag installs the package in your user directory instead of system-wide.
Virtual Environments
We strongly recommend using a virtual environment to isolate your project dependencies:
Using venv
Using uv
Creating virtual environment at: .venv
Activate with: source .venv/bin/activatesource .venv/bin/activate # On Windows: .venv\Scripts\activate(.venv) $ uv pip install spoc
Resolved 1 package in 50ms
Installed 1 package in 5ms
+ spoc==0.1.0
Installation Complete
You're all set! SPOC is installed and ready to help you build modular monolith applications.