feat: introduce pydantic-settings for config definition and validation (#5202)

Co-authored-by: -LAN- <laipz8200@outlook.com>
This commit is contained in:
Bowen Liang
2024-06-19 13:41:12 +08:00
committed by GitHub
parent d160d1ed02
commit 3cc6093e4b
21 changed files with 772 additions and 227 deletions

View File

@@ -0,0 +1,17 @@
from pydantic import BaseModel, Field
class PackagingInfo(BaseModel):
"""
Packaging build information
"""
CURRENT_VERSION: str = Field(
description='Dify version',
default='0.6.11',
)
COMMIT_SHA: str = Field(
description="SHA-1 checksum of the git commit used to build the app",
default='',
)