Open Bug 1712159 Opened 3 years ago Updated 1 year ago

Efficiently update command virtualenv if it's out-of-date

Categories

(Firefox Build System :: Mach Core, enhancement, P3)

enhancement

Tracking

(Not tracked)

People

(Reporter: mhentges, Unassigned)

References

(Blocks 1 open bug)

Details

On first-run of a command, or if a command's dependencies change, it's virtualenv should be updated accordingly. Remove all unneeded packages and install/update the ones now needed.

Note that if the current Python version or implementation changes, dependencies should be re-installed.
Raise an error if there's a dependency collision between the installed packages and the global mach venv (see this related bug).

Priority: -- → P2
Summary: Automatically update command virtualenv if it's out-of-date → Efficiently update command virtualenv if it's out-of-date

Tweaking this ticket a bit to refer to handling the update efficiently - right now, we blow out venvs and re-create them from scratch, which isn't the fastest.
Instead, we should:

  • Verify that venv is structurally sound (unsure how much time should be spent here, maybe more thorough checks should happen in ./mach doctor)
  • Update pth file
  • Remove unneeded packages, install/upgrade packages
Severity: -- → S3
Priority: P2 → P3
You need to log in before you can comment on or make changes to this bug.