Skip to content

Local development

Work on SPAPI as an installable library — no Docker or SAM required for day-to-day development.

Prerequisites

Requirement Notes
Python 3.8 Matches production consumers
Git Private deps (fs_obs) need GitHub access
Redis (optional) Token cache and Taboola meta cache tests

Setup

cd skynet-provider-api
python3 -m venv env
source env/bin/activate
pip install --upgrade pip
pip install -r requirements.txt
pip install -e .
pip install -r requirements_dev.txt

For pre-commit hooks:

pre-commit install

Run tests

pytest

HTML reports land in test-reports/ (coverage, junit, logs).

Run a single module:

pytest tests/test_taboola.py -q

IDE debugging

Field Value
Working directory Repo root
Python path Editable install (pip install -e .)
Test runner pytest with testpaths = tests from pyproject.toml

Set breakpoints in provider or entity modules under src/spapi/.

Token files locally

Providers read OAuth tokens from Redis (when redis_settings is passed) or from a local *_token.txt file in the working directory. Token file names are set per provider via set_token_file_name().

Warning

*_token.txt files are gitignored. Never commit credentials.

Legacy Sphinx docs

The repo still ships Sphinx sources (docs/conf.py, Makefile). The portal builds MkDocs only. To preview Sphinx locally:

pip install -r requirements_dev.txt
cd docs && make html
open _build/html/index.html

Branches

Branch Role
stage Integration — feature PRs target here
master Production lineage

Install as dependency elsewhere

pip install git+https://github.com/frontstory/skynet-provider-api.git@<ref>

Or pin in requirements.txt (CodeCommit / GitHub URL per your environment).