Bug Description
The backend application crashes or raises a ModuleNotFoundError when hitting the /export endpoint or when importing the export router. This happens because backend/export.py contains a bare/relative import on line 6:
from database import get_connection
Steps to Reproduce
- Start the FastAPI server using uvicorn backend.main:app or standard start scripts.
- Trigger the export endpoint via: curl http://localhost:8000/api/emails/export?format=csv
- Look at the traceback, it will fail with: ModuleNotFoundError: No module named 'database'
Suggested Fix
Change the import on line 6 of backend/export.py
Acceptance Criteria
- Import in backend/export.py is corrected to from backend.database import get_connection
- No ModuleNotFoundError is raised when starting the server or hitting /api/emails/export.
Bug Description
The backend application crashes or raises a
ModuleNotFoundErrorwhen hitting the/exportendpoint or when importing the export router. This happens becausebackend/export.pycontains a bare/relative import on line 6:Steps to Reproduce
Suggested Fix
Change the import on line 6 of backend/export.py
Acceptance Criteria