feat: More contextual promotion embeds + navigation clean-up #9295
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Server | |
on: | |
push: | |
branches: ["main"] | |
pull_request: | |
types: [opened, synchronize] | |
jobs: | |
linters: | |
name: "Server: Linters 📝" | |
timeout-minutes: 15 | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/cache@v4 | |
with: | |
path: | | |
server/.mypy_cache | |
key: mypy-${{ runner.os }}-${{ github.sha }} | |
restore-keys: | | |
mypy-${{ runner.os }}- | |
mypy- | |
- name: Install uv | |
uses: astral-sh/setup-uv@v3 | |
with: | |
enable-cache: true | |
- name: Set up Python | |
uses: actions/setup-python@v5 | |
with: | |
python-version-file: "server/.python-version" | |
- name: 🔧 uv install | |
working-directory: ./server | |
run: uv sync --dev | |
- name: 🐶 Lint Server (ruff) | |
working-directory: ./server | |
run: uv run task lint_check | |
- name: 🛟 Type Check Server (mypy) | |
working-directory: ./server | |
run: uv run task lint_types | |
test: | |
name: "Server: Tests 🐍" | |
runs-on: ubuntu-latest | |
timeout-minutes: 15 | |
services: | |
postgres: | |
image: postgres:15.1-bullseye | |
env: | |
POSTGRES_USER: polar | |
POSTGRES_PASSWORD: polar | |
POSTGRES_DB: polar_test | |
POSTGRES_PORT: 5432 | |
options: >- | |
--health-cmd pg_isready | |
--health-interval 10s | |
--health-timeout 5s | |
--health-retries 5 | |
ports: | |
- 5432:5432 | |
minio: | |
image: bitnami/minio:2024.5.28 | |
ports: | |
- 9000:9000 | |
- 9001:9001 | |
env: | |
MINIO_ROOT_USER: polar | |
MINIO_ROOT_PASSWORD: polarpolar | |
options: >- | |
--health-cmd "curl -I http://127.0.0.1:9000/minio/health/live" | |
--health-interval 10s | |
--health-timeout 5s | |
--health-retries 5 | |
steps: | |
- uses: actions/checkout@v4 | |
- name: 💿 MinIO Setup | |
working-directory: ./server/.minio | |
env: | |
MINIO_HOST: 127.0.0.1 | |
MINIO_ROOT_USER: polar | |
MINIO_ROOT_PASSWORD: polarpolar | |
ACCESS_KEY: polar-development | |
SECRET_ACCESS_KEY: polar123456789 | |
BUCKET_NAME: polar-s3 | |
BUCKET_TESTING_NAME: testing-polar-s3 | |
POLICY_FILE: policy.json | |
run: bash github.sh | |
- name: Install uv | |
uses: astral-sh/setup-uv@v3 | |
with: | |
enable-cache: true | |
- name: Set up Python | |
uses: actions/setup-python@v5 | |
with: | |
python-version-file: "server/.python-version" | |
- name: 🔧 uv install | |
working-directory: ./server | |
run: | | |
uv sync --dev | |
uv run task generate_dev_jwks | |
- name: ⚗️ alembic migrate | |
working-directory: ./server | |
env: | |
POLAR_ENV: testing | |
run: uv run task db_migrate | |
- name: ⚗️ alembic check | |
working-directory: ./server | |
env: | |
POLAR_ENV: testing | |
run: uv run alembic check | |
- name: 🐍 Run tests (pytest) | |
working-directory: ./server | |
run: uv run pytest -n auto --no-cov |