fix: address PR review feedback (round 6)
- Fix assign_tag sending Content-Type header with no body - Mark collectives_update_collective as idempotent (no ETag involved) - Raise OCSError when 'data' key missing instead of silent fallback - Tighten color validator to 3 or 6 hex chars only - Add comment explaining null emoji semantics in set_page_emoji Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Opus 4.6
parent
aa46c6147b
commit
85119bde91
@@ -60,7 +60,7 @@ class CollectiveTag(BaseModel):
|
||||
@field_validator("color")
|
||||
@classmethod
|
||||
def validate_hex_color(cls, v: str) -> str:
|
||||
if not re.fullmatch(r"[0-9A-Fa-f]{3,8}", v):
|
||||
if not re.fullmatch(r"[0-9A-Fa-f]{3}(?:[0-9A-Fa-f]{3})?", v):
|
||||
raise ValueError(f"Invalid hex color: {v!r}")
|
||||
return v
|
||||
|
||||
|
||||
Reference in New Issue
Block a user