refactor: replace Any types with specific types and update bad_code.md
- Replace Any with object or specific types across codebase - Add ReviewRequest dataclass for PR review payloads - Update bad_code.md: mark 5.1 (Any Type Overuse) as resolved - Fix summary table with accurate counts and unresolved issues list
This commit is contained in:
+3
-3
@@ -1,6 +1,6 @@
|
||||
"""Pydantic models for Gitea API entities."""
|
||||
|
||||
from typing import Optional, Any
|
||||
from typing import Optional
|
||||
|
||||
from pydantic import BaseModel, Field, field_validator
|
||||
|
||||
@@ -71,8 +71,8 @@ class PullRequestModel(BaseModel):
|
||||
updated_at: Optional[str] = None
|
||||
closed_at: Optional[str] = None
|
||||
merged_at: Optional[str] = None
|
||||
head: dict[str, Any] = Field(default_factory=dict)
|
||||
base: dict[str, Any] = Field(default_factory=dict)
|
||||
head: dict[str, object] = Field(default_factory=dict)
|
||||
base: dict[str, object] = Field(default_factory=dict)
|
||||
repository: Optional[RepositoryModel] = None
|
||||
comments: int = 0
|
||||
comments_url: Optional[str] = None
|
||||
|
||||
Reference in New Issue
Block a user