Closed Bug 1638783 Opened 1 year ago Closed 1 year ago

Bootstrapping fails to install mercurial if no pip2

Categories

(Firefox Build System :: Bootstrap Configuration, defect, P3)

x86_64
Linux
defect

Tracking

(firefox78 fixed)

RESOLVED FIXED
mozilla78
Tracking Status
firefox78 --- fixed

People

(Reporter: saschanaz, Assigned: rstewart)

Details

Attachments

(1 file)

You do not have Mercurial installed

Mercurial releases a new version every 3 months and your distro's package
may become out of date. This may cause incompatibility with some
Mercurial extensions that rely on new Mercurial features. As a result,
you may not have an optimal version control experience.

To have the best Mercurial experience possible, we recommend installing
Mercurial via the "pip" Python packaging utility. This will likely result
in files being placed in /usr/local/bin and /usr/local/lib.

How would you like to continue?
  1. Install a modern Mercurial via pip (recommended)
  2. Install a legacy Mercurial via apt
  3. Do not install Mercurial
Your choice: 1
Executing as root: sudo pip install --upgrade Mercurial
sudo: pip: command not found
Traceback (most recent call last):
  File "python/mozboot/bin/bootstrap.py", line 202, in <module>
    sys.exit(main(sys.argv))
  File "python/mozboot/bin/bootstrap.py", line 193, in main
    dasboot.bootstrap()
  File "python/mozboot/mozboot/bootstrap.py", line 462, in bootstrap
    hg_installed, hg_modern = self.instance.ensure_mercurial_modern()
  File "python/mozboot/mozboot/base.py", line 583, in ensure_mercurial_modern
    if self.upgrade_mercurial(version) is False:
  File "python/mozboot/mozboot/debian.py", line 212, in upgrade_mercurial
    self.run_as_root(['pip', 'install', '--upgrade', 'Mercurial'])
  File "python/mozboot/mozboot/base.py", line 384, in run_as_root
    subprocess.check_call(command, stdin=sys.stdin)
  File "/usr/lib/python3.8/subprocess.py", line 364, in check_call
    raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '['sudo', 'pip', 'install', '--upgrade', 'Mercurial']' returned non-zero exit status 1.

Ubuntu 20.04 only has pip3.

Bugbug thinks this bug should belong to this component, but please revert this change in case of error.

Component: General → Bootstrap Configuration
Severity: -- → S3
Priority: -- → P3
Assignee: nobody → rstewart
Status: NEW → ASSIGNED
Pushed by rstewart@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/8d7bd3053121
Install Mercurial with pip3 rather than pip, which no longer exists on new Ubuntu/Debian versions r=froydnj
Status: ASSIGNED → RESOLVED
Closed: 1 year ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla78
You need to log in before you can comment on or make changes to this bug.