Skip to content

fix: CORS headers, error handling, and all 61 tests passing - #5

Merged
Hiteshsai007 merged 6 commits into
masterfrom
main
Mar 18, 2026
Merged

fix: CORS headers, error handling, and all 61 tests passing#5
Hiteshsai007 merged 6 commits into
masterfrom
main

Conversation

@Hiteshsai007

Copy link
Copy Markdown
Owner

No description provided.

Hitesh added 6 commits March 18, 2026 14:56
- Complete README with architecture, setup, API docs
- Backend .env.example with all environment variables
- Frontend .env.example with VITE_API_URL
- No secrets exposed - all placeholder values
Phase 1 - Clean Up:
- Remove empty backend/api/backend/ folder
- Delete multiple venv folders (.venv, venv, etc.)
- Move root test files to backend/tests/
- Move pytest.ini to backend/
- Delete temp files (probe_credential.py, run.bat, run.sh)
- Update .gitignore with better venv patterns

Phase 2 - Organize Backend:
- Create config.py with centralized configuration management
- Add Python logging to main.py
- Create schemas/ package (backward-compatible with models.py)
- Create migrations/ folder for SQL migrations

All changes maintain backward compatibility - existing imports work.
- Uses try/except to handle both import styles
- Works with: cd backend && python main.py
- Works with: python -m backend.main
- Fixed port to 8013 in __main__ block
All API, engine, services, and db files now use absolute imports.
This allows running:
- cd backend && python main.py
- python -m backend.main

Fixed import issues that prevented direct execution.
- Add CORS middleware with allow_origins=['*'] for all responses
- Add custom middleware to ensure CORS headers on all endpoints
- Fix supabase_client.py to return errors instead of raising exceptions
- Convert all tests to use FastAPI TestClient (no more httpx.Client)
- Fix test files: conftest, api, credentials, delegation, evolution,
  execution, intent_parser, marketplace, router, schema, workflow
- All 61 tests now pass
@Hiteshsai007
Hiteshsai007 merged commit fc95ee3 into master Mar 18, 2026
1 of 5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant