fix: add python3-venv package for virtual environment support #31

Merged
brad merged 1 commit from fix-python3-venv into main 2026-02-24 10:45:34 -08:00
Owner

Problem

The python3 -m venv command used to install bloc was failing because the python3-venv package was not installed.

Root Cause

Previous attempts missed the fundamental issue: On Debian/Ubuntu systems, the venv module is not included in the base python3 package — it requires a separate python3-venv package.

The three previous approaches failed because:

  1. PR #26: Used uv tool install but didn't address venv
  2. PR #28: Attempted system-wide install with different flags
  3. PR #29: Switched to venv approach but didn't install python3-venv

Solution

Added python3-venv to the initial apt-get install alongside python3 and python3-pip.

This is the correct fix because:

  • Addresses the actual error message: "you need to install the python3-venv package"
  • Installs the package BEFORE attempting to create the venv
  • Follows Debian best practices (separate -venv package)
  • Minimal change with no side effects

Testing

The error message was explicit: ensurepip is not available. On Debian/Ubuntu systems, you need to install the python3-venv package.

This directly resolves that requirement.

Fixes #30

## Problem The `python3 -m venv` command used to install bloc was failing because the `python3-venv` package was not installed. ## Root Cause **Previous attempts missed the fundamental issue**: On Debian/Ubuntu systems, the venv module is not included in the base `python3` package — it requires a separate `python3-venv` package. The three previous approaches failed because: 1. PR #26: Used `uv tool install` but didn't address venv 2. PR #28: Attempted system-wide install with different flags 3. PR #29: Switched to venv approach but didn't install python3-venv ## Solution Added `python3-venv` to the initial apt-get install alongside `python3` and `python3-pip`. **This is the correct fix** because: - ✅ Addresses the actual error message: "you need to install the python3-venv package" - ✅ Installs the package BEFORE attempting to create the venv - ✅ Follows Debian best practices (separate -venv package) - ✅ Minimal change with no side effects ## Testing The error message was explicit: `ensurepip is not available. On Debian/Ubuntu systems, you need to install the python3-venv package.` This directly resolves that requirement. Fixes #30
The bloc installation uses python3 -m venv to create a virtual environment,
but python3-venv was not installed. This is required on Debian/Ubuntu systems.

Fixes #30
brad merged commit 40dd9f8dfc into main 2026-02-24 10:45:34 -08:00
brad deleted branch fix-python3-venv 2026-02-24 10:45:35 -08:00
Sign in to join this conversation.
No reviewers
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
commune/sandbox!31
No description provided.