RustPython currently supports the full Python syntax. This is “what’s left” from the Python Standard Library.
For each module’s details, check the Python Module Index.
Note that not every module here is critical or feasible for RustPython to implement. For example, the readline Python module is heavily based around the API of GNU readline, but we use rustyline (a different readline implementation), so it probably wouldn’t be worth the effort to emulate GNU
readline on top of rustyline just to implement an infrequently used module.
In addition, some modules may just be modules written in Python that we haven’t copied over to the stdlib yet; always be sure to check whether a module is implemented in Python before trying to rewrite it in Rust. You can follow these instructions for copying over files from CPython’s Lib.
- cProfile
- curses
- idlelib
- imaplib
- modulefinder
- poplib
- profile
- pstats
- readline
- tracemalloc
- turtle
- turtledemo
- xxlimited_35
- _abc
- _asyncio
- _codecs_cn
- _codecs_hk
- _codecs_iso2022
- _codecs_jp
- _codecs_kr
- _codecs_tw
- _ctypes_test
- _curses
- _curses_panel
- _datetime
- _dbm
- _decimal
- _elementtree
- _gdbm
- _heapq
- _interpchannels
- _interpqueues
- _interpreters
- _lsprof
- _multibytecodec
- _pickle
- _posixshmem
- _queue
- _sha2
- _sysconfigdata__linux_x86_64-linux-gnu
- _testclinic
- _testclinic_limited
- _testexternalinspection
- _testsinglephase
- _tkinter
- _tokenize
- _tracemalloc
- _zoneinfo
BaseException
BaseException.__getattribute__(inherited)
NoneType
NoneType.__eq__(inherited)NoneType.__ge__(inherited)NoneType.__gt__(inherited)NoneType.__hash__(inherited)NoneType.__le__(inherited)NoneType.__lt__(inherited)NoneType.__ne__(inherited)
bool
bool.__invert__(inherited)
bytearray
bytearray.__buffer__bytearray.__getattribute__(inherited)bytearray.__release_buffer__bytearray.__str__(inherited)
bytes
bytes.__buffer__bytes.__getattribute__(inherited)bytes.__str__(inherited)
classmethod
classmethod.__init__(inherited)
complex
complex.__getattribute__(inherited)
dict
dict.__getattribute__(inherited)
dict_items
dict_items.__hash__(inherited)
enumerate
enumerate.__getattribute__(inherited)
filter
filter.__getattribute__(inherited)
int
int.__getattribute__(inherited)
list
list.__getattribute__(inherited)
map
map.__getattribute__(inherited)
memoryview
memoryview.__buffer__memoryview.__getattribute__(inherited)memoryview.__release_buffer__memoryview._from_flags
property
property.__getattribute__(inherited)
range
range.__getattribute__(inherited)
set
set.__getattribute__(inherited)
slice
slice.__getattribute__(inherited)
tuple
tuple.__getattribute__(inherited)
zip
zip.__getattribute__(inherited)