isort
Put Python imports into consistent order and groups.
PyCQA · Code and testing
GitHub projectOpen source Open on GitHubHow to try it
In a Python virtual environment, install isort==9.0.2. Sort a tiny sample with unordered standard-library imports.
What we tested
9.0.2. Sort a tiny sample with unordered standard-library imports. Sorted the two standard-library imports alphabetically.