Saving notes

This commit is contained in:
Scott Idem
2026-01-13 14:35:10 -05:00
parent 19a9890dd9
commit 722409de0b

View File

@@ -20,11 +20,19 @@ I am the **primary orchestrator and main helper** for the development of the **U
- **Bootstrap Paradox Solved**: Implemented a guest-access exception for `site_domain` search, allowing the frontend to resolve site context without a JWT.
- **V3 Searchable Fields**: Confirmed that `searchable_fields` are fully implemented in `app/object_definitions/` and utilized by `app/lib_sql_search.py` for dynamic query generation.
- **Environment Sync Clarification**: Critical understanding that the `/home/scott/OSIT_dev/` directory is **NOT** a synchronized directory across different machines (e.g., Workstation vs. Laptop). This means virtual environments and installed dependencies are environment-specific and do not propagate via Syncthing. This is crucial for debugging cross-machine environment issues.
- **Circular Import Sensitivity**: Importing `JSONResponse` from `fastapi` in `app/routers/api.py` triggers a circular dependency crash. It is safer to rely on FastAPI's default dict-to-JSON serialization or use `mk_resp` without explicit `JSONResponse` typing in that specific file.
## Session Summary & Progress (Jan 9, 2026)
## Session Summary & Progress (Jan 13, 2026)
This session focused on fixing Person creation issues, modularizing the V3 CRUD system, and enhancing Developer Experience (DX) for the frontend.
This session focused on resolving startup errors in the `ae_api` container and improving database connectivity testing.
* **Bug Fixes & Stability:**
* **Fixed NameError:** Resolved missing `mk_resp` import in `app/main.py`.
* **Fixed AttributeError:** Corrected `response_class=PlainTextResponse` to `JSONResponse` (or default) for dict-returning endpoints.
* **Resolved Circular Dependency:** Identified and fixed a circular import caused by `JSONResponse` usage in `app/routers/api.py`.
* **Infrastructure & Testing:**
* **Safe SQL Test Endpoint:** Relocated and refactored the `sql_test` endpoint from `app/main.py` to `app/routers/api.py` (accessible at `/api/sql_test`).
* **Safety Improvement:** Updated the test query to use `SELECT NOW(), VERSION()` instead of querying the `account` table, ensuring a safe connectivity check without exposing data.
* **V3 CRUD Modularization (Phase 1-3):**
* Successfully refactored `app/routers/api_crud_v3.py` into a modular architecture.
* **Logic Extraction:** Created `app/lib_api_crud_v3.py` for shared security and filtering logic.
@@ -38,14 +46,6 @@ This session focused on fixing Person creation issues, modularizing the V3 CRUD
* **Address & Contact:** Updated models and JSON mappings to include `hide`, `priority`, `sort`, `group`, and `notes`. Fixed missing imports and unsafe validator access.
* **Journal:** Added `fields_to_exclude_from_db` to filter out view-only fields (e.g., `person_full_name`) during updates.
* **Post:** Added `external_person_id` to searchable fields.
* **Test Suite Creation:** Established a `/tests` directory with focused scripts:
* `test_model_validation.py` (Person/Auth key defaults).
* `test_v3_filtering.py` (Journal exclusion lists).
* `test_v3_router_filtering.py` (Payload sanitization).
* `test_v3_error_bubbling.py` (SQL error formatting).
* **System Health & Architecture:**
* Audit confirmed API and AI services (Ollama/WebUI) are stable; ComfyUI is stuck in a restart loop.
* Analyzed and recommended scope expansion to the `/home/scott/OSIT_dev/` root for better platform orchestration.
## Current To-Do List
@@ -61,6 +61,7 @@ This session focused on fixing Person creation issues, modularizing the V3 CRUD
- [ ] **Review and process new messages from various agents.** (ID: 134908245) - In Progress (Internal gemini_cli task).
- [x] **[scott_wks] Perform Initial System Health Audit** (ID: 131939030) - Done.
- [x] **[API-V3] Implement Error Bubbling and Validation Endpoint** (ID: 163752448) - Done.
- [x] **[API] Fix Startup Errors and Refactor SQL Test Endpoint** - Done.
### Workflow & Collaboration