운영 안정화와 화면 회귀 검증을 반영
Some checks failed
API contract / OpenAPI type drift (push) Failing after 6m2s

This commit is contained in:
Yun Chan 2026-10-20 16:33:48 +09:00
parent 6e3123091a
commit aeddaa6972
69 changed files with 3178 additions and 424 deletions

View file

@ -328,8 +328,8 @@ async def index_document(
chunks=[c.model_dump() for c in body.chunks],
)
try:
# 관리자 인덱싱은 RLS 미적용(쓰기 — kb 스키마 직접). role 주입 없이 acquire.
async with acquire() as conn:
# 관리자 RLS 컨텍스트를 주입해 kb 쓰기 정책을 충족한다.
async with acquire(role=principal.role.value, user_id=principal.user_id) as conn:
await rag.validate_index_source(conn, body.source_id)
result = await rag.index_document(conn, req)
except rag.IndexPolicyViolation as e:
@ -376,7 +376,7 @@ async def sync_live_coach_source_packs(
)
try:
async with acquire() as conn:
async with acquire(role=principal.role.value, user_id=principal.user_id) as conn:
result = await source_pack_sync.sync_repo_source_packs(
conn, apply=True, refresh=True
)