This topic describes the Python runtimes that Function Compute supports for writing your function code.
Python runtimes
The following table lists the Python runtimes that are supported by Function Compute.
Version | Identifier | Operating system | Architecture |
Python 3.12 (public preview) | python3.12 | Debian 11 | x86_64 |
Python 3.10 | python3.10 | Debian 10 | x86_64 |
Python 3.9 | python3.9 | Debian 9 | x86_64 |
Python 3.6 | python3 | Debian 9 | x86_64 |
Function Compute will soon stop supporting Python 2.7 according to the deprecation plan. For more information, see Runtime deprecation policy.
Python 3.12 is supported in the following regions: China (Hangzhou), China (Shanghai), China (Qingdao), China (Beijing), China (Zhangjiakou), China (Hohhot), China (Shenzhen), China (Chengdu), China (Hong Kong), Japan (Tokyo), Thailand (Bangkok), South Korea (Seoul), Germany (Frankfurt), UK (London), US (Virginia), and US (Silicon Valley).
Built-in Python modules
In addition to the standard modules of Python, Function Compute provides commonly used modules for Python for you to reference. The following table lists these modules.
Python 3.12 (public preview)
Module | Description | Version |
oss2 | 2.18.6 | |
alibabacloud_ecs20140526 | 4.1.9 | |
alibabacloud_vpc20160428 | 6.7.2 | |
alibabacloud_rds20140815 | 6.0.1 | |
alibabacloud_kms20160120 | 2.2.1 | |
alibabacloud-mns-open20220119 | 1.0.3 | |
alibabacloud_cdn20180510 | 4.0.0 | |
alibabacloud_ram20150501 | 1.1.0 | |
alibabacloud_sts20150401 | 3.1.0 | |
alibabacloud_iot20180120 | 5.1.0 | |
alibabacloud_sls20201230 | 5.2.2 | |
wand | 0.6.11 | |
scrapy | 2.11.2 | |
PyMySQL | 1.4.6 | |
elasticsearch | 8.14.0 | |
Pillow | 10.4.0 | |
pyOpenSSL | 24.2.1 | |
redis | 5.0.7 | |
requests | 2.32.3 |
Python 3.10
Module | Description | Version |
oss2 | 2.16.0 | |
tablestore | 5.4.1 | |
aliyun-fc2 | 2.5.2 | |
aliyun-python-sdk-ecs | 4.24.26 | |
aliyun-python-sdk-vpc | 3.0.27 | |
aliyun-python-sdk-rds | 2.7.2 | |
aliyun-python-sdk-kms | 2.16.0 | |
aliyun-mns | 1.1.5 | |
aliyun-python-sdk-cdn | 3.7.8 | |
aliyun-python-sdk-ram | 3.2.0 | |
aliyun-python-sdk-sts | 3.1.0 | |
aliyun-python-sdk-iot | 8.47.0 | |
aliyun-log-python-sdk | 0.8.0 | |
wand | 0.6.10 | |
scrapy | 2.7.1 | |
PyMySQL | 1.0.2 | |
elasticsearch | 8.5.2 | |
Pillow | 9.3.0 | |
pyOpenSSL | 1.0.2 | |
redis | 4.4.0 | |
requests | 2.28.1 |
Python 3.9
Module | Description | Version |
oss2 | 2.15.0 | |
tablestore | 5.2.1 | |
aliyun-fc2 | 2.5.0 | |
aliyun-python-sdk-ecs | 4.24.11 | |
aliyun-python-sdk-vpc | 3.0.15 | |
aliyun-python-sdk-rds | 2.6.1 | |
aliyun-python-sdk-kms | 2.15.0 | |
pydatahub | Not supported | |
aliyun-mns | 1.1.5 | |
aliyun-python-sdk-cdn | 3.6.7 | |
aliyun-python-sdk-ram | 3.2.0 | |
aliyun-python-sdk-sts | 3.1.0 | |
aliyun-python-sdk-iot | 8.30.0 | |
aliyun-log-python-sdk | 0.7.3 | |
wand | 0.6.7 | |
opencv | 4.5.4.58 | |
numpy | 1.21.4 | |
scipy | 1.7.2 | |
matplotlib | 3.4.3 | |
scrapy | 2.5.1 |
Python 3.6
Module | Description | Version |
oss2 | 2.9.1 | |
tablestore | 5.1.0 | |
aliyun-fc2 | 2.3.0 | |
aliyun-python-sdk-ecs | 4.10.1 | |
aliyun-python-sdk-vpc | 3.0.2 | |
aliyun-python-sdk-rds | 2.1.4 | |
aliyun-python-sdk-kms | 2.14.0 | |
pydatahub | 2.11.2 | |
aliyun-mns | 1.1.5 | |
aliyun-python-sdk-cdn | 3.0.8 | |
aliyun-python-sdk-ram | 3.0.0 | |
aliyun-python-sdk-sts | 3.0.0 | |
aliyun-python-sdk-iot | 7.8.0 | |
aliyun-log-python-sdk | 0.6.38 | |
wand | 0.6.7 | |
opencv | 3.3.0.10 | |
numpy | 1.13.3 | |
scipy | 1.0.0 | |
matplotlib | 2.0.2 | |
scrapy | 1.4.0 |