diff --git a/services/billing/app/main.py b/services/billing/app/main.py index 41debb3..c075b4a 100644 --- a/services/billing/app/main.py +++ b/services/billing/app/main.py @@ -11,9 +11,16 @@ The webhook endpoint is exposed WITHOUT ForwardAuth so Stripe can reach it. from __future__ import annotations import logging +import sys from contextlib import asynccontextmanager +from pathlib import Path from typing import AsyncGenerator +# Ensure the repo root is on sys.path so "shared" is importable in local dev. +_repo_root = str(Path(__file__).resolve().parents[3]) +if _repo_root not in sys.path: + sys.path.insert(0, _repo_root) + from fastapi import FastAPI from fastapi.middleware.cors import CORSMiddleware