# Shared family core — identity/session/auth/audit + the SQLAlchemy Base (Galena/Sygna/Counsel share
# it). Private repo pinned by tag; CI authenticates the clone with a read-only DREDD_CORE_TOKEN
# (see .github/workflows/ci.yml). Local co-dev: pip install -e ../dredd-core shadows the pin.
# v0.9.0 brought make_engine TLS (sslmode/sslrootcert), the family's TLS rule (require_verified_tls,
# DB_LOCAL_HOSTS), runtime_grants_sql and python -m dredd_core.managed (provision / check / emulate)
# for the family's shared managed PostgreSQL database (db/managed/README.md).
#
# v0.10.0 is what makes ONE ACCOUNT possible: the shared identity schema and its grant tiers
# (SHARED_IDENTITY_TABLES, shared_identity_grants_sql, create_identity_tables,
# assert_identity_schema, repoint_identity_fks_sql), the two administration tiers
# (dredd_core.moderation — ADMINISTRATOR platform-wide, MODERATOR per module), and
# AuthPolicy.identity_writes_enabled / local_login_enabled: the two flags that let a module refuse
# an account write or a local sign-in with a sentence at the edge, instead of letting a missing
# database grant surface as a 500 on an ordinary screen. Every default reproduces v0.9.0's
# behaviour, so a STANDALONE Counsel is unchanged by the bump; what uses the new surface is
# alembic/versions/0004_shared_identity.py, and it does nothing at all until IDENTITY_SCHEMA is set.
#
# v0.10.1 adds schema.migration_preflight_sql — the statement 0001 now runs FIRST, refusing a
# superuser, the platform admin or the runtime role BY NAME before anything is created. 0002's runtime
# grants already made the same two checks, but 0002 is only reached once 0001 has succeeded, so as the
# wrong role Counsel built every table first and nothing but Alembic's transaction undid it.
# Required, not optional: 0001 imports it.
#
# v0.11.0 is the second half of "one account": `module_moderator` becomes `module_permission`, one
# row per person per module carrying a `role` of 'user' or 'moderator' — and NO ROW MEANS NO ACCESS
# to that module. That fourth answer is the whole change: until it, anyone with a platform account
# could open any module and merely see nothing, which is not an access decision.
# `deps.get_current_user` now calls `moderation.assert_may_use`, `services/moderation.py` renames
# the two policy flags (`shared_permissions` / `permission_writes_enabled`), and
# `alembic/versions/0005_module_permission.py` carries the rename to databases whose 0001 ran under
# v0.10.x. A STANDALONE Counsel is unchanged: with no platform to be admitted to, core answers
# "user" for everybody and emits no SQL at all.
# dredd_core.search_contract, new in 0.17.0).
# v0.23.0 brings `dredd_core.stats_contract` (the Compass split's M4): `GET /stats`, Panorama's tiles
# (services/stats.py). 0.19.0-0.22.0 come along; their additions are opt-in (no table needed here).
dredd-core @ git+http://77.216.148.202:3000/Haski/dredd-core.git@v0.23.0

# Web framework
fastapi==0.162.2
uvicorn[standard]==0.54.0

# Validation / settings
pydantic==2.14.3
pydantic-settings==2.16.2
# email validation is done in-app via a regex validator (schemas.Email) — no email-validator dependency

# DB / ORM / migrations
SQLAlchemy==2.1.8
alembic==1.20.1
pg8000==1.31.6          # pure-Python PostgreSQL driver, BSD-3-Clause (no LGPL, no libpq)

# Auth
argon2-cffi==25.1.0

# OpenTelemetry (OTLP → OTel Collector) — versions move in lockstep: the 1.45.x api/sdk line
# pairs with the 0.66bx instrumentation/semantic-conventions line, so bump them together.
opentelemetry-sdk==1.45.2
opentelemetry-exporter-otlp-proto-grpc==1.45.2
opentelemetry-instrumentation-fastapi==0.66b2
opentelemetry-instrumentation-sqlalchemy==0.66b2
