Commit c46f610
fix: Fix missing imports in teams_service.py for autoTriage (#184)
* fix: Fix missing imports in teams_service.py for autoTriage
The teams_service.py was importing DailyDigestResult and WeeklyPlanResult
models that don't exist in the autoTriage directory (they're part of the
larger TeamAssistant backend). These imports were causing the auto-triage
workflow to fail with ModuleNotFoundError.
Solution:
- Added `from __future__ import annotations` to make all type hints strings
- Made imports conditional using TYPE_CHECKING
- Type hints now work for development but don't fail at runtime
- Auto-triage workflow can now import services without errors
The Teams notification features (daily digest, weekly summary) are not
used by the auto-triage workflow, so these optional imports don't affect
functionality.
Fixes the workflow error:
ModuleNotFoundError: No module named 'models.daily_digest'
Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
* fix: Remove unused Any import from teams_service.py
---------
Co-authored-by: Claude Sonnet 4.5 <noreply@anthropic.com>1 parent 4b35081 commit c46f610
1 file changed
Lines changed: 8 additions & 3 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
4 | 4 | | |
5 | 5 | | |
6 | 6 | | |
| 7 | + | |
| 8 | + | |
7 | 9 | | |
8 | 10 | | |
9 | 11 | | |
10 | 12 | | |
11 | | - | |
12 | | - | |
13 | | - | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
14 | 19 | | |
15 | 20 | | |
16 | 21 | | |
| |||
0 commit comments