Граф коммитов

6965 Коммитов

Автор SHA1 Сообщение Дата
Mitchell Hentges f20cdb0c12 Bug 1712804: Check if `comm` directory is empty in TB identification r=ahal
Some developers hold onto a `comm` directory as a mount point
that they conditionally populate depending on whether they're working on
Firefox or Thunderbird.
The "`comm` directory exists == is a thunderbird checkout"
assumption isn't compatible with this workflow.

The fix embraced by this patch is to check if the `comm` directory has
any contents.

Differential Revision: https://phabricator.services.mozilla.com/D119193
2021-07-06 18:33:58 +00:00
Emilio Cobos Álvarez 780f3a05d2 Bug 1719144 - Fix various imports for Python 3.10. r=firefox-build-system-reviewers,mhentges
These are enough for me to run bootstrap+configure+build.

Some touch third-party code (gyp), but per discussion in the earlier
versions of this revision that seems fine.

Differential Revision: https://phabricator.services.mozilla.com/D119080
2021-07-06 15:26:29 +00:00
Mike Hommey 544436ed03 Bug 1718156 - Avoid some configure tests creating the common virtualenv. r=firefox-build-system-reviewers,mhentges,andi
When running `mach python-test` on a clobbered tree, we create both the
python-test and common virtualenvs, but the former should be enough. The
latter is only created when running tests that use the BaseConfigureTest
class, when it indirectly includes init.configure, which makes the
configure sandbox run the virtualenv_python3 function, which ends up
initializing the common virtualenv. We only don't end up re-executing
that virtualenv python thanks to 6680ca0acc27 which was a workaround
that would allow any virtualenv in $objdir/_virtualenvs, while still
creating a virtualenv it won't use.

Tests now tell virtualenv_python3 to not use the normal virtualenv
manager, and remove the workaround.

Differential Revision: https://phabricator.services.mozilla.com/D118775
2021-07-05 22:33:56 +00:00
Mitchell Hentges c25aec1f74 Bug 1717104: Update "pth" docs for virtualenvs r=ahal
The "pth" action no longer has a customizable filename, and the docs
should be updated accordingly.

Depends on D118609

Differential Revision: https://phabricator.services.mozilla.com/D118610
2021-07-05 22:10:35 +00:00
Mitchell Hentges 86ae5fbc84 Bug 1717104: Remove obsolete "set-variable" notes from virtualenv docs r=ahal
Since https://phabricator.services.mozilla.com/D115921, "set-variable"
is no longer a valid action. Looks like that patch forgot to remove the
associated docs

Differential Revision: https://phabricator.services.mozilla.com/D118609
2021-07-05 22:10:35 +00:00
surajeet310 498013ddc6 Bug 1717651 - Removed instances of 'ensure_subprocess_env()' from virtualenv.py r=mhentges
Since Python 2 is no longer used in virtualenv.py ,hence 'ensure_subprocess_env()' is obsolete.

Differential Revision: https://phabricator.services.mozilla.com/D118883
2021-07-05 19:59:53 +00:00
Sandor Molnar fe63cb08df Backed out 2 changesets (bug 1719144) for causing build bustages. CLOSED TREE
Backed out changeset 8e4b00b9d57c (bug 1719144)
Backed out changeset d2a88c5423a0 (bug 1719144)
2021-07-05 21:15:50 +03:00
Emilio Cobos Álvarez 52a85aaca1 Bug 1719144 - Fix various imports for Python 3.10. r=firefox-build-system-reviewers,mhentges
These are enough for me to run bootstrap+configure+build.

Some touch third-party code (gyp), but per discussion in the earlier
versions of this revision that seems fine.

Differential Revision: https://phabricator.services.mozilla.com/D119080
2021-07-05 17:55:41 +00:00
Mitchell Hentges 9ee9a69ade Bug 1717905: M1 Macs don't support Android targets r=glandium
Also filter out bootstrapping for Android targets.

Differential Revision: https://phabricator.services.mozilla.com/D118727
2021-07-05 17:44:20 +00:00
Mitchell Hentges 733d1bb939 Bug 1717905: Fix M1 Mac bootstrap choice offset r=glandium
When we customized the list of possible `applications` for M1 Macs, the
change was only applying to the displayed list, but not the actual
list that the choice was indexed against.

This is fixed by properly using `applications` instead of
`APPLICATIONS` where relevant.

Note that it's still possible to manually request an
`artifact_mode` if you provide it as an argument for `./mach bootstrap`,
but this workflow is usually only done by devs who are familiar with all
the applications, and therefore likely know what they're doing.

Differential Revision: https://phabricator.services.mozilla.com/D118625
2021-07-05 17:44:19 +00:00
june wilde 68adbeeae5 Bug 1703066 - add tracking key to mozyaml file schema; r=tjr
Differential Revision: https://phabricator.services.mozilla.com/D110829
2021-06-29 14:01:58 +00:00
Mike Hommey 81228f00cd Bug 1717947 - Remove packager support for brotli in Jars. r=firefox-build-system-reviewers,nalexander
This was added ing bug 1352595. It has only been used briefly, and we
since then have gone all the way to never compress omni.ja. Even if we
did go back to compressing, we'd probably go with zstd rather than
brotli.
The gecko-side support for this has only ever been nightly-only.

Differential Revision: https://phabricator.services.mozilla.com/D118655
2021-06-25 00:20:10 +00:00
Mitchell Hentges b7dde05a8d Bug 1717786: Update mozperfest runner's list of in-tree Python packages r=kimberlythegeek
After replacing a bunch of vendored source packages with wheels, the
paths to the raw source changed.

Differential Revision: https://phabricator.services.mozilla.com/D118723
2021-06-24 18:02:53 +00:00
Mitchell Hentges 43949e4a1c Bug 1717702: Resolve `print-checks` python unpacking typo r=andi
`_get_infer_config()` returns 3 items, but the existing code expects 2.
Add a third `_` to capture the other unwanted item.

Differential Revision: https://phabricator.services.mozilla.com/D118535
2021-06-24 13:21:57 +00:00
Alexander J. Vincent b12c2e5817 Bug 1717650 - Support RockyLinux 8.4. r=mhentges
Differential Revision: https://phabricator.services.mozilla.com/D118539
2021-06-22 20:34:13 +00:00
Alexander J. Vincent 2c7ff94a69 Bug 1717650 - Drop requirement for wireless-tools-devel package. r=mhentges
wireless-tools-devel isn't available on Rocky Linux. Fortunately, it doesn't appear to be needed for the build anymore, and it was added almost a decade ago, so it should be safe to remove.

Differential Revision: https://phabricator.services.mozilla.com/D118532
2021-06-22 20:34:13 +00:00
Tarik Eshaq 453be8c6fd Bug 1716450 - Removes fxa-client rust code from Desktop. r=rfkelly
Differential Revision: https://phabricator.services.mozilla.com/D118238
2021-06-22 17:04:35 +00:00
Marian-Vasile Laza 4728ef73b2 Bug 1700534 - black lint fix r=fix CLOSED TREE 2021-06-22 09:22:33 +03:00
Mike Hommey 744db845c6 Bug 1700534 - Coalesce RLBox wasmboxed libraries. r=firefox-build-system-reviewers,shravanrn,bholley,andi,mhentges
Differential Revision: https://phabricator.services.mozilla.com/D116440
2021-06-22 05:31:33 +00:00
Mitchell Hentges ee5a948268 Bug 1716600: Don't use node/npm that are too old or have no version r=firefox-build-system-reviewers,nalexander
In the existing behaviour, we would return a node/npm executable from
`find_executable()`, even if we couldn't extract a version from it or if
the extracted version was insufficient.

Now, we fail early if the detected node/npm is insufficient.

Differential Revision: https://phabricator.services.mozilla.com/D118377
2021-06-21 16:47:56 +00:00
Mitchell Hentges 00d96c3fed Bug 1716600: Remove looping from Node's find_executable() r=firefox-build-system-reviewers,nalexander
Since we're no longer checking for both "nodejs" and "node",
`find_executable()` can be simplified.

Differential Revision: https://phabricator.services.mozilla.com/D118376
2021-06-21 16:47:55 +00:00
Mitchell Hentges 73814a7f0f Bug 1716600: Always search for "node" instead of "nodejs" r=firefox-build-system-reviewers,nalexander
As :julienw beautifully described on Bugzilla,
we no longer need to search for "nodejs" since all
packages providing Node >= v12 will provide the `node`
binary.
See his comment here:
https://bugzilla.mozilla.org/show_bug.cgi?id=1716600#c4

Base-toolchain tasks with Node v10 should still be
happy because, unlike Debian's Node v10, they provide
a `node` binary instead of `nodejs`.

Differential Revision: https://phabricator.services.mozilla.com/D118375
2021-06-21 16:47:55 +00:00
Aki Sasaki 5b64d5df25 Bug 1659691 - Update cross-channel algorithm to not replay history. r=firefox-build-system-reviewers,releng-reviewers,bhearsum,mhentges
(Tl;dr: The original author of this patch was axel@mozilla.com (:pike).
This patch has been modified to run in production automation.)

Cross-channel takes all the en-US strings from the shipping train branches
and consolidates them into a single repository. Originally, this ran out of
https://hg.mozilla.org/users/axel_mozilla.com/cross-channel-experimental/ .
The original version was coupled tightly with specific hg internals, making
hg upgrades fragile. Axel wrote
https://bug1659691.bmoattachments.org/attachment.cgi?id=9170636 before
handing off project ownership; this is the original patch to stop replaying
history to simplify the logic.

This patch also automates the previously manual preparation steps, allows
for running both in automation and locally, and adds retries for production
robustness.

Differential Revision: https://phabricator.services.mozilla.com/D116537
2021-06-17 18:52:58 +00:00
Mitchell Hentges 2438ea8889 Bug 1712133: Validate that pypi dependencies are installed r=ahal
Check that all expected pypi packages are installed
when checking if a virtualenv is up-to-date.

Differential Revision: https://phabricator.services.mozilla.com/D117712
2021-06-17 14:58:17 +00:00
Mitchell Hentges 2fa59acd4f Bug 1712133: Adds "pypi" action to virtualenv `handle_package()` r=ahal
The `pypi` action uses `pip` to fetch a package and its dependencies

Differential Revision: https://phabricator.services.mozilla.com/D115925
2021-06-17 14:58:17 +00:00
Mitchell Hentges 24f634d924 Bug 1712133: Remove "pth" name customization r=ahal
Having separate `<name>.pth` files in the virtual environments
isn't providing an advantage. We can simplify configuration
by putting all `pth` adjustments into a single file: `mach.pth`.

Differential Revision: https://phabricator.services.mozilla.com/D117710
2021-06-17 14:58:16 +00:00
Mitchell Hentges 31474e8925 Bug 1712133: Make virtualenv package parsing more specific r=ahal
This has two benefits:
1. `handle_package()` becomes more clear - rather than referring to
   `action` and `package` with array index numbers, we now give
   them real names. The benefit here is also shown in `up_to_date()`.
2. This makes the top-level parser for `packages()` less opinionated
   about sub-formats: if an action has a nested structure, it should
   have the flexibility to define what it looks like.

Differential Revision: https://phabricator.services.mozilla.com/D117708
2021-06-17 14:58:16 +00:00
Mitchell Hentges 722ac646db Bug 1713857: Don't set PYTHONEXECUTABLE environment variable r=glandium
After some testing in `try` and locally, the manual
`PYTHONEXECUTABLE` definitions shouldn't be needed
anymore.

There's been some work on Brew's
Python to improve its `sitecustomize` behaviour.
The most likely improvement is:
https://github.com/Homebrew/homebrew-core/pull/65297

However, I'm not fully confident in this change.
If it fails, it's more likely to affect developers
than CI. I think it's worth attempting a landing,
because if the variable is indeed obsolete, then
deleting it will avoid some spicy "action-at-a-
distance" behaviour.

Differential Revision: https://phabricator.services.mozilla.com/D117452
2021-06-17 13:28:29 +00:00
Marian-Vasile Laza 19f23a7e8b Bug 1716911 - black lint fix r=fix CLOSED TREE 2021-06-17 09:39:54 +03:00
Mike Hommey 83c4b6a318 Bug 1716911 - Switch --enable-bootstrap on by default on macos builds on central. r=firefox-build-system-reviewers,nalexander
Differential Revision: https://phabricator.services.mozilla.com/D118107
2021-06-17 04:59:42 +00:00
Mitchell Hentges 6d154c1ed3 Bug 1713377: Change vendoring to use wheels where possible r=ahal,glandium
Vendoring wheels has three benefits:
* There's far less files, so Firefox checkouts will be smaller.
* It works around `zipp` not allowing `pip install`
  from extracted source `tar.gz` files. Now, we should
  be able to use the pip resolver against vendored
  packages, which will be needed for future
  mach virtualenv work.
* `./mach vendor python` takes far less time to execute.

Since we need the raw Python to be available to add to the `sys.path`,
we extract the wheels before putting them in tree.
Due to the structure of some wheels being less nested
than of a source `tar.gz`, `common_virtualenv_packages`
needed to be adjusted accordingly.

`install_pip_package()` had to be tweaked as well since you can't
`pip install` an extracted wheel. So, we "re-bundle" the wheel
before installing from a vendored package.

Replace python packages with wheels where possible

This contains the vendoring changes caused by the
last patch.

For reviewing, there's a couple things to note:
* A bunch of files are deleted, since there's generally
  less files in a wheel than in a source archive.
* There's a new `.dist-info` directory for each
  extracted wheel, so expect roughly 5 or
  6 new files for each wheel'd package.
* There should be no source code changes other than
  moves from package names changing from having
  `-` to having `_`.

Differential Revision: https://phabricator.services.mozilla.com/D116512
2021-06-16 15:53:16 +00:00
Mitchell Hentges c335e37407 Bug 1690870: Remove "artifact mode" from bootstrap options on M1 Macs r=firefox-build-system-reviewers,andi
As pointed out by Harry, this will help in the short-term with
onboarding new developers who will be using M1 macs.

Note that this patch doesn't leverage the "instance" classes to define
whether they're artifact-mode compatible or not, and that's because:
* Most (all except one?) of the systems support artifact mode, therefore
* Since this is a temporary workaround, it's more deletable to have
  a top-level `if/else` than to add a `supports_artifact_mode` property
  to each Bootstrapper.

Differential Revision: https://phabricator.services.mozilla.com/D117946
2021-06-16 14:31:07 +00:00
surajeet310 c3511254e0 Bug 1714688 - Removed 'if PY2'/'if PY3' logic from python/mozbuild r=mhentges
Python2 is no longer used in Mozbuild.

Differential Revision: https://phabricator.services.mozilla.com/D117561
2021-06-15 19:31:21 +00:00
Gregory Mierzwinski a5873d50c0 Bug 1716378 - Use correct test modules path in xpcshell layer. r=perftest-reviewers,kimberlythegeek
Differential Revision: https://phabricator.services.mozilla.com/D117690
2021-06-15 17:01:58 +00:00
Mitchell Hentges 9f7c330b60 Bug 1712133: Remove "windows" action support from virtualenvs r=ahal
Last year, we stopped vendoring Python packages that have native
code. Since we have only had pure-python packages since, the
Windows-specific qualifier (or excluder in the case of `!windows`)
hasn't been needed.

I don't foresee us needing it again, but if anything we can peel it
back from `hg` history if this assumption is incorrect.

Differential Revision: https://phabricator.services.mozilla.com/D117468
2021-06-15 14:46:55 +00:00
Mitchell Hentges 1b74e5a575 Bug 1713201: Resolve test_telemetry failing locally r=ahal
On Windows, Python's temporary directories are placed in `%APPDATA%`.
Unfortunately, the failing tests want to assume that some "other"
path (as a subpath of a tempdir) won't be within any
`filter_args()` known top-level paths, which includes the user's home
dir.

The only reason that this assumption has passed in CI so far is due
to Windows case insensitivity: running locally had `~` evaluated
to `c:\Users\...`, while running in CI had it be `c:\users\...`.
Since the tempdir path started with `C:\Users`, `filter_args()`
would `<path omitted>` in CI but would `$HOME/...` locally.

By not basing the `other_path` on `tempdir`, we now consistently get the
same results across platforms.

Differential Revision: https://phabricator.services.mozilla.com/D117698
2021-06-15 14:45:53 +00:00
Alexandru Michis 542a65a629 Bug 1715282 - Fix black py lint in test_toolchain_configure.py a=lint-fix
CLOSED TREE
2021-06-15 18:04:43 +03:00
Mike Hommey 7f9a51a8f5 Bug 1715282 - Bump minimum Rust version to 1.51. r=firefox-build-system-reviewers,andi
Also update the estimated rust versions for future releases, based on
the updated Firefox release dates.

Differential Revision: https://phabricator.services.mozilla.com/D117737
2021-06-15 09:23:20 +00:00
Iulian Moraru 952b525e6f Backed out changeset 55a7556ae185 (bug 1715282) for causing base-toolchain bustages and python failures on test_toolchain_configure.py. CLOSED TREE 2021-06-15 10:46:39 +03:00
Jeff Muizelaar e5c5ce020a Bug 1715282 - Bump minimum Rust version to 1.50. r=glandium
Various people want 1.50 and it's been out for a while so let's require it.

Differential Revision: https://phabricator.services.mozilla.com/D117158
2021-06-15 05:46:02 +00:00
surajeet310 ec19bcfbf2 Bug 1714688 - Removed 'if PY2' logic from python/mozrelease r=mhentges
Python2 is no longer used in Mozrelease

Differential Revision: https://phabricator.services.mozilla.com/D117583
2021-06-14 20:41:31 +00:00
Csoregi Natalia 6b0106d5b1 Backed out changeset 15c6a16f5828 (bug 1714688) for docker images bustage. CLOSED TREE 2021-06-14 20:51:29 +03:00
Csoregi Natalia 5136d2de85 Bug 1714684 - Fix linting. r=fix CLOSED TREE 2021-06-14 20:47:59 +03:00
surajeet310 0ac7b98b51 Bug 1714688 - Removed 'if PY2'/'if PY3' logic from python/mozbuild r=mhentges
Python2 is no longer used in Mozbuild.

Differential Revision: https://phabricator.services.mozilla.com/D117561
2021-06-14 16:10:11 +00:00
Mitchell Hentges b685c830d4 Bug 1714684: Resolve `assert_has_calls()` usage error r=ahal
The `calls` parameter is expected to be an iterable
container of calls, not a singular call.

This was working in `mock-1.0.0` because `calls`
was (confusingly) allowed to be a single item
if `any_order==False`. This behaviour isn't
the same in the standard library.

Differential Revision: https://phabricator.services.mozilla.com/D117074
2021-06-14 15:34:47 +00:00
Mitchell Hentges e389cc4cc4 Bug 1714684: Remove usages of vendored "mock" library r=perftest-reviewers,ahal,sparky
Python 3 has access to `unittest.mock` in the standard library.

Differential Revision: https://phabricator.services.mozilla.com/D117073
2021-06-14 15:34:46 +00:00
Butkovits Atila ce6e97604b Backed out changeset 7648560f810d (bug 1715282) for causing build bustages. CLOSED TREE 2021-06-11 22:47:34 +03:00
Jeff Muizelaar 5ca0d5fb13 Bug 1715282 - Bump minimum Rust version to 1.50. r=glandium
Various people want 1.50 and it's been out for a while so let's require it.

Differential Revision: https://phabricator.services.mozilla.com/D117158
2021-06-11 19:27:22 +00:00
surajeet310 6ea83c8ef9 Bug 1714788 - Fixed more Sphinx warnings in 'mach doc' r=sylvestre DONTBUILD
Differential Revision: https://phabricator.services.mozilla.com/D117419
2021-06-10 19:33:53 +00:00
Mitchell Hentges dc2fa7819c Bug 1713610: Require PyPI-vendored packages be added to requirements.in r=ahal
`./mach vendor python <package>` was already adding its new package
to `requirements.txt`, so we were getting full resolver support, which
is good. However, it caused our `requirements.in` file to start
getting out-of-date, and therefore made it harder to identify the
top-level dependencies.

Arguably, we could have `./mach vendor python <package>` automatically
update `requirements.in`, too, but then we need to solve the edge cases,
such as "What if the package is already in `requirements.in`? What if
that existing item has a different version?"

The hardest part of updating `requirements.in` was finding it, so I've
also modified the `./mach vendor python` help text to make it more
identifiable.

Differential Revision: https://phabricator.services.mozilla.com/D116386
2021-06-10 19:19:06 +00:00