1. SSE page_complete 이벤트 필드명 score→overall_score 불일치 수정 (진행 페이지에서 각 페이지별 점수가 표시되지 않던 버그) 2. 진행 페이지 재방문 시 완료된 검사는 결과 대시보드로 자동 리다이렉트 3. 카테고리 상세(이슈 목록)를 인라인으로 표시하여 트리 사이드바 유지 (이전: 별도 페이지로 이동하여 트리가 사라지는 문제) Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
40 lines
856 B
Python
40 lines
856 B
Python
"""
|
|
Application configuration from environment variables.
|
|
"""
|
|
|
|
from pydantic_settings import BaseSettings
|
|
from functools import lru_cache
|
|
|
|
|
|
class Settings(BaseSettings):
|
|
"""Application settings loaded from environment variables."""
|
|
|
|
# MongoDB
|
|
MONGODB_URL: str = "mongodb://admin:password123@localhost:27022/"
|
|
DB_NAME: str = "web_inspector"
|
|
|
|
# Redis
|
|
REDIS_URL: str = "redis://localhost:6392"
|
|
|
|
# Inspection
|
|
URL_FETCH_TIMEOUT: int = 10
|
|
CATEGORY_TIMEOUT: int = 60
|
|
MAX_HTML_SIZE: int = 10485760 # 10MB
|
|
|
|
# Site inspection
|
|
SITE_MAX_PAGES: int = 500
|
|
SITE_MAX_DEPTH: int = 2
|
|
SITE_CONCURRENCY: int = 2
|
|
|
|
# Application
|
|
PROJECT_NAME: str = "Web Inspector API"
|
|
|
|
class Config:
|
|
env_file = ".env"
|
|
case_sensitive = True
|
|
|
|
|
|
@lru_cache()
|
|
def get_settings() -> Settings:
|
|
return Settings()
|