FileHint

.py

High risk

Python script

Python source code. Ubiquitous in data analysis, ML, automation, and backends — runs on every mainstream OS.

MIME types

  • text/x-python
  • application/x-python-code

Category

code

What opens this file

  • CPython
  • PyCharm
  • VS Code
  • Jupyter
  • IDLE

How to open by OS

Windows

  • Microsoft Store Python 3 or the python.org installer.

Mac

  • Homebrew or pyenv.

Linux

  • Distribution packages or pyenv.

Ios

  • Pyto, Pythonista.

Android

  • Pydroid 3, Termux.

Safety notes

  • Any python script.py runs with the user's privileges. Read unknown Python scripts before executing them.
  • pickle.load on untrusted input equals arbitrary code execution — never unpickle data you don't control.

Common mistakes

  • Using Python 2 idioms (print statement, / integer division) on Python 3 raises errors. Python 2 hit EOL in 2020 — move to 3.9+.
  • Failing to pin dependencies (no requirements.txt, no pip freeze, no poetry/uv lock) leads to non-reproducible environments.

Related extensions

References