mirror of
https://github.com/HeyPuter/firefox.git
synced 2026-11-15 14:35:58 -10:00
Ideally, it would have been better if it were "or", but it's not possible to override "or" in python ; __or__ is for "|". This does feel magic, but it's also shorter than adding something like @depends_any(), and while we're only adding "|" as of this change, we can add other operations such as "&" in the future, or __getattr__ for things like milestone.is_nightly. An alternative form in moz.configure could require the @depends function to be called, e.g. "a() | b()" instead of "a | b", but I'm not particularly convinced that one is less magic than the other. This feature is hooked up such that b is not resolved if a is true, although in practice, it will still be resolved in Sandbox.run... but not when --help is passed. In the long run, the forced resolution of @depends functions will be removed from Sandbox.run.
This directory contains common Python code. The basic rule is that if Python code is cross-module (that's "module" in the Mozilla meaning - as in "module ownership") and is MPL-compatible, it should go here. What should not go here: * Python that is not MPL-compatible (see other-licenses/) * Python that has good reason to remain close to its "owning" (Mozilla) module (e.g. it is only being consumed from there). Historical information can be found at https://bugzilla.mozilla.org/show_bug.cgi?id=775243 ## pyyaml | pystache Used in taskcluster related mach commands to update download from github and remove .git and tests. Then run tests in taskcluster/tests/