Python venv Troubleshooting Cheat Sheet/Activate using bash syntax

Source the activate script in bash or zsh.

Section: Activation issues

Activate using bash syntax

bash
bash
source .venv/bin/activate
Explanation

The most common activation command on POSIX systems.

Learn the surrounding workflow

Compare similar commands or jump into common fixes when this command is part of a bigger troubleshooting path.

Related commands

Same sheet · prioritizing Activation issues
Activate using fish syntax
Source the fish activation script.
OpenIn sheetbashsame section
Run Activate.ps1
Activate from PowerShell.
OpenIn sheetpowershellsame section
Refresh command hashing in zsh
Force zsh to refresh remembered command paths.
OpenIn sheetbashsame section
Allow local PowerShell scripts
Fix execution policy for venv activation scripts.
OpenIn sheetpowershellsame section
Find python on POSIX
See which python binary your shell resolves first.
Install bundled pip
Bootstrap pip into the current interpreter or venv.