iflytek / spark-ai-python

星火大模型 python sdk库
MIT License
203 stars 11 forks source link

The thrown ConnectionError does not get error code #23

Closed zongyanshan closed 2 months ago

zongyanshan commented 2 months ago

The thrown ConnectionError does not allow for the error code to be obtained. Business is unable to interact based on specific error codes, kneeling down to seek repair.

whybeyoung commented 2 months ago
    try:
        xxxx()
    except ConnectionError as e:
        print(e.error_code)