- 格式化 66 个 Python 文件以符合 Black 代码风格 - 修复 GitHub Actions Code Quality 工作流失败问题 Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
13 lines
250 B
Python
13 lines
250 B
Python
from __future__ import annotations
|
|
|
|
from typing import Any
|
|
|
|
import requests
|
|
|
|
|
|
def get_response_details(response: requests.Response) -> Any:
|
|
try:
|
|
return response.json()
|
|
except Exception:
|
|
return response.text or response.reason
|