We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 68662a9 commit 08f4670Copy full SHA for 08f4670
dashscope/api_entities/base_request.py
@@ -10,11 +10,21 @@
10
11
class BaseRequest(ABC):
12
def __init__(self) -> None:
13
+ try:
14
+ platform_info = platform.platform()
15
+ except Exception:
16
+ platform_info = "unknown"
17
+
18
19
+ processor_info = platform.processor()
20
21
+ processor_info = "unknown"
22
23
ua = 'dashscope/%s; python/%s; platform/%s; processor/%s' % (
24
__version__,
25
platform.python_version(),
- platform.platform(),
- platform.processor(),
26
+ platform_info,
27
+ processor_info,
28
)
29
self.headers = {'user-agent': ua}
30
disable_data_inspection = os.environ.get(
0 commit comments