Skip to content

Instantly share code, notes, and snippets.

@8Observer8
Last active March 11, 2026 22:11
Show Gist options
  • Select an option

  • Save 8Observer8/406e02e5d0f71b5786abc6e09e20530d to your computer and use it in GitHub Desktop.

Select an option

Save 8Observer8/406e02e5d0f71b5786abc6e09e20530d to your computer and use it in GitHub Desktop.
How to sort imports and find unused packages in Python
To sort packages in your project directory:
```
pip install isort
cd your_project_directory
isort .
```
To detect unused packages in your project directory:
```
pip install pyflakes
cd your_project_directory
pyflakes .
```
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment