The following are some common errors you may experience when using Alibaba Cloud Python SDK. Potential causes and resolutions are shown for these commonly experienced errors.
Error message: Can not find endpoint to access.
The SDK cannot automatically obtain the endpoint of the called product in the specified region.
Obtain the service endpoint of the product in the corresponding API documentation.
Run the following codes to set the endpoint:
Note: Make sure that the region ID is correct.
from aliyunsdkcore.profile import region_provider
region_provider.modify_point('Ecs', 'cn-zhangjiakou', 'ecs.aliyuncs.com')
Error message: SDK.TimeoutError
The request times out and all retry attempts fail.
In scenarios such as cross-region call or low network quality, we recommend that you increase the timeout or the maximum number of retries.
If the problem persists and the network quality is confirmed to be good, we recommend that you open a ticket.
Error message: Your request is denied as lack of ssl protect.Recommend:https://error-center.aliyun.com/status/search?Keyword=InvalidProtocol.NeedSsl&source=PopGw
The API accepts only HTTPS requests so HTTP requests are rejected.
Add the following codes before sending the request: