Don't scan sys.path to discover mach modules

RESOLVED FIXED in mozilla19

Status

RESOLVED FIXED
6 years ago
8 months ago

People

(Reporter: gps, Unassigned)

Tracking

Trunk
mozilla19

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(1 attachment)

(Reporter)

Description

6 years ago
Created attachment 678076 [details] [diff] [review]
Remove sys.path scanning, v1

Scanning sys.path for mach modules is neat and all. But, we agreed when it was implemented that it isn't ideal. Since then (bug 794509), we've established the convention of creating mach_commands.py files around the tree and referencing them explicitly in the main mach driver (./mach). This way, the mach driver has complete control over what gets loaded. I think this is more practical than having automagical side-effects.

The attached patch removes sys.path scanning. But, it does preserve the ability to scan directories. The mach commands in python/mozbuild have been moved to a mach_commands.py file.
Attachment #678076 - Flags: review?(jhammel)
(Reporter)

Updated

6 years ago
Blocks: 807974

Comment 1

6 years ago
Comment on attachment 678076 [details] [diff] [review]
Remove sys.path scanning, v1

lgtm
Attachment #678076 - Flags: review?(jhammel) → review+
(Reporter)

Comment 2

6 years ago
https://hg.mozilla.org/mozilla-central/rev/f561a4ffeeb9
Status: NEW → RESOLVED
Last Resolved: 6 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla19

Updated

8 months ago
Product: Core → Firefox Build System
You need to log in before you can comment on or make changes to this bug.