mirror of
https://github.com/elisiariocouto/leggen.git
synced 2025-12-14 18:02:20 +00:00
fix(config): Add Pydantic validation and fix telegram config field mappings.
* Add Pydantic models for configuration validation in leggen/models/config.py * Fix telegram config field aliases (api-key -> token, chat-id -> chat_id) * Update config.py to use Pydantic validation with proper error handling * Fix TOML serialization by excluding None values with exclude_none=True * Update notification service to use correct telegram field names * Enhance notification service with actual Discord/Telegram implementations * Fix all failing configuration tests to work with Pydantic validation * Add pydantic dependency to pyproject.toml 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
committed by
Elisiário Couto
parent
990d0295b3
commit
2c6e099596
2
uv.lock
generated
2
uv.lock
generated
@@ -229,6 +229,7 @@ dependencies = [
|
||||
{ name = "fastapi" },
|
||||
{ name = "httpx" },
|
||||
{ name = "loguru" },
|
||||
{ name = "pydantic" },
|
||||
{ name = "requests" },
|
||||
{ name = "tabulate" },
|
||||
{ name = "tomli-w" },
|
||||
@@ -257,6 +258,7 @@ requires-dist = [
|
||||
{ name = "fastapi", specifier = ">=0.104.0,<1" },
|
||||
{ name = "httpx", specifier = ">=0.28.1" },
|
||||
{ name = "loguru", specifier = ">=0.7.2,<0.8" },
|
||||
{ name = "pydantic", specifier = ">=2.0.0,<3" },
|
||||
{ name = "requests", specifier = ">=2.31.0,<3" },
|
||||
{ name = "tabulate", specifier = ">=0.9.0,<0.10" },
|
||||
{ name = "tomli-w", specifier = ">=1.0.0,<2" },
|
||||
|
||||
Reference in New Issue
Block a user