Skip to content

πŸ§‘β€πŸ’» Lower error level for auto-reconnecting websocket #3527

πŸ§‘β€πŸ’» Lower error level for auto-reconnecting websocket

πŸ§‘β€πŸ’» Lower error level for auto-reconnecting websocket #3527

Workflow file for this run

name: Froide CI
on:
push:
branches: [main]
pull_request:
branches: [main]
jobs:
lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Install pnpm
uses: pnpm/action-setup@v4
with:
version: 9
- uses: actions/setup-node@v4
with:
node-version: 20
cache: 'pnpm'
- name: Install dependencies
run: pnpm install
- uses: pre-commit/[email protected]
test:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ['3.10', '3.12']
steps:
- uses: actions/checkout@v4
- name: Setup uv
uses: astral-sh/setup-uv@v2
with:
enable-cache: true
cache-dependency-glob: |
requirements*.txt
pyproject.toml
- name: Install pnpm
uses: pnpm/action-setup@v4
with:
version: 9
- uses: actions/setup-node@v4
with:
node-version: 20
cache: 'pnpm'
- name: Install system-level dependencies
run: sudo apt-get update && sudo apt-get install libxml2-dev libxslt1-dev libgdal-dev gdal-bin libmagic-dev libmagickwand-dev libpoppler-cpp-dev
- name: Setup venv
run: |
uv venv --python ${{ matrix.python-version }}
source .venv/bin/activate
echo PATH=$PATH >> $GITHUB_ENV
- name: Install dependencies
run: |
uv pip sync requirements-test.txt
uv pip install -e . --no-deps
playwright install --with-deps chromium
pnpm install
- name: Build frontend
run: pnpm run build
- name: Run tests
run: |
coverage run --branch -m pytest froide/
coverage report --format=markdown >> $GITHUB_STEP_SUMMARY
env:
DATABASE_URL: postgis://postgres:postgres@localhost/froide
services:
postgres:
image: postgis/postgis:16-3.4
env:
POSTGRES_USER: postgres
POSTGRES_PASSWORD: postgres
POSTGRES_DB: froide
ports:
- 5432:5432
# needed because the postgres container does not provide a healthcheck
options: --health-cmd pg_isready --health-interval 10s --health-timeout 5s --health-retries 5
elasticsearch:
image: docker.elastic.co/elasticsearch/elasticsearch:8.11.3
options: -e "discovery.type=single-node" -e "xpack.security.enabled=false" --expose 9200 --health-cmd "curl localhost:9200/_cluster/health" --health-interval 10s --health-timeout 5s --health-retries 10
ports:
- '9200:9200'