зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1635260 - Scope the import of glean_parser r=janerik
glean_parser is being used by mach to send build telemetry and by FOG to generate APIs. We have to keep them separate somehow. Depends on D84862 Differential Revision: https://phabricator.services.mozilla.com/D85161
This commit is contained in:
Родитель
e16cd0205e
Коммит
19b35cefce
|
@ -4,14 +4,19 @@
|
|||
# License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
|
||||
import rust
|
||||
import sys
|
||||
|
||||
from glean_parser import lint, parser, util
|
||||
from pathlib import Path
|
||||
|
||||
|
||||
def main(output_fd, *metrics_yamls):
|
||||
from pathlib import Path
|
||||
|
||||
srcdir = Path(__file__).joinpath('../../../../../../')
|
||||
glean_parser_path = srcdir.joinpath('third_party/python/glean_parser')
|
||||
sys.path.insert(0, str(glean_parser_path.resolve()))
|
||||
|
||||
from glean_parser import lint, parser, util
|
||||
import rust
|
||||
|
||||
# Derived heavily from glean_parser.translate.translate.
|
||||
# Adapted to how mozbuild sends us a fd.
|
||||
options = {"allow_reserved": False}
|
||||
|
|
Загрузка…
Ссылка в новой задаче