docs: 182 Architektur-Fehler (ARCH-001 bis ARCH-182) durch systematisches Code-Review dokumentiert

This commit is contained in:
Agent Zero
2026-08-22 22:43:24 +02:00
parent 1eac7546bc
commit aaf3142942
+72
View File
@@ -1832,3 +1832,75 @@ Playwright E2E: 10 passed, 24 failed (BUG-011/012/013 — Mock-Daten und data-te
- **Problem:** Drag-and-drop ändert nur local state (`setWidgets`). Widget-Position wird nicht in Backend gespeichert. Bei Reload geht die Anordnung verloren. - **Problem:** Drag-and-drop ändert nur local state (`setWidgets`). Widget-Position wird nicht in Backend gespeichert. Bei Reload geht die Anordnung verloren.
- **Schweregrad:** Medium - **Schweregrad:** Medium
- **Status:** ⏳ Nicht gefixt - **Status:** ⏳ Nicht gefixt
### ARCH-171: schemas/common.py — Deprecated Notification Schemas noch aktiv
- **Datei:** app/schemas/common.py:15-40
- **Problem:** Deprecated Notification Schemas (NotificationResponse, NotificationListResponse, etc.) noch aktiv. Doppelarchitektur mit kommunikation.
- **Schweregrad:** Medium
- **Status:** ⏳ Nicht gefixt
### ARCH-172: schemas/webhook.py — WebhookResponse gibt secret zurück
- **Datei:** app/schemas/webhook.py:40
- **Problem:** WebhookResponse gibt secret zurück. HMAC Secret sollte nicht in API Response stehen.
- **Schweregrad:** High
- **Status:** ⏳ Nicht gefixt
### ARCH-173: automation/schemas.py — llm_model default hardcoded
- **Datei:** app/plugins/builtins/automation/schemas.py:18
- **Problem:** `llm_model: str = Field(default="ollama/deepseek-v4-flash")` — hardcoded Model-Name. Sollte aus Settings kommen.
- **Schweregrad:** Low
- **Status:** ⏳ Nicht gefixt
### ARCH-174: ai_assistant/schemas.py — api_key als Plaintext String
- **Datei:** app/plugins/builtins/ai_assistant/schemas.py:18
- **Problem:** `api_key: str = Field(default="", max_length=2000)` — API-Key als Plaintext im Schema. Sollte verschlüsselt gespeichert werden.
- **Schweregrad:** High
- **Status:** ⏳ Nicht gefixt
### ARCH-175: wiki/schemas.py — ArticleCreate erfordert slug
- **Datei:** app/plugins/builtins/wiki/schemas.py:22
- **Problem:** `slug: str = Field(..., min_length=1, max_length=300)` — slug ist Pflichtfeld. Sollte auto-generiert werden aus title.
- **Schweregrad:** Medium
- **Status:** ⏳ Nicht gefixt
### ARCH-176: permissions/schemas.py — ShareLinkResponse gibt token zurück
- **Datei:** app/plugins/builtins/permissions/schemas.py:35
- **Problem:** ShareLinkResponse gibt token zurück. Share-Token sollte nicht in API Response stehen.
- **Schweregrad:** Medium
- **Status:** ⏳ Nicht gefixt
### ARCH-177: mail/schemas.py — MailAccountCreate password als Plaintext
- **Datei:** app/plugins/builtins/mail/schemas.py:25
- **Problem:** `password: str = Field(..., min_length=1, max_length=512)` — Mail-Account Password als Plaintext im Schema. Wird zwar verschlüsselt gespeichert aber im Request unverschlüsselt.
- **Schweregrad:** Medium
- **Status:** ⏳ Nicht gefixt
### ARCH-178: schemas/custom_field_definition.py — entity ohne Validierung
- **Datei:** app/schemas/custom_field_definition.py:15
- **Problem:** `entity: str = Field(...)` — keine Validierung gegen ENTITY_MODELS. Jeder String wird akzeptiert.
- **Schweregrad:** Medium
- **Status:** ⏳ Nicht gefixt
### ARCH-179: schemas/entity_permission.py — principal_type pattern hardcoded
- **Datei:** app/schemas/entity_permission.py:12
- **Problem:** `principal_type: str = Field(..., pattern="^(user|group|role|guest)$")` — hardcoded. Neue Principal-Types können nicht dynamisch hinzugefügt werden.
- **Schweregrad:** Low
- **Status:** ⏳ Nicht gefixt
### ARCH-180: Systematisches Problem — Schemas mit hardcoded Regex Patterns
- **Dateien:** tasks/schemas.py, calendar/schemas.py, report_generator/schemas.py, etc.
- **Problem:** Viele Schemas haben hardcoded Regex Patterns für Enums (status, type, etc.). Diese sollten mit den Model-Defaults synchronisiert sein, sind aber dupliziert.
- **Schweregrad:** Low
- **Status:** ⏳ Nicht gefixt
### ARCH-181: Systematisches Problem — entity_type/entity ohne ENTITY_MODELS Validierung
- **Dateien:** entity_links/schemas.py, tags/schemas.py, custom_field_definition.py, graph_rag/schemas.py
- **Problem:** entity_type und entity Felder in Schemas haben keine Validierung gegen ENTITY_MODELS. Jeder String wird akzeptiert.
- **Schweregrad:** Medium
- **Status:** ⏳ Nicht gefixt
### ARCH-182: Systematisches Problem — API Secrets in Responses
- **Dateien:** schemas/webhook.py, permissions/schemas.py, mcp_client/routes.py, api/webhooks.ts
- **Problem:** Webhook.secret, ShareLink.token, McpServerConfig.api_token werden in API Responses an Frontend gesendet. Secrets sollten nie in Responses stehen.
- **Schweregrad:** High
- **Status:** ⏳ Nicht gefixt