mozharness.mozilla.building package

Submodules

mozharness.mozilla.building.buildbase module

buildbase.py.

provides a base class for fx desktop builds author: Jordan Lund

class mozharness.mozilla.building.buildbase.BuildOptionParser[source]

Bases: object

bits = None
branch_cfg_file = 'builds/branch_specifics.py'
build_pool_cfg_file = 'builds/build_pool_specifics.py'
build_variants = {'api-9': 'builds/releng_sub_%s_configs/%s_api_9.py', 'api-11': 'builds/releng_sub_%s_configs/%s_api_11.py', 'b2g-debug': 'b2g/releng_sub_%s_configs/%s_debug.py', 'graphene': 'builds/releng_sub_%s_configs/%s_graphene.py', 'code-coverage': 'builds/releng_sub_%s_configs/%s_code_coverage.py', 'tsan': 'builds/releng_sub_%s_configs/%s_tsan.py', 'mulet': 'builds/releng_sub_%s_configs/%s_mulet.py', 'source': 'builds/releng_sub_%s_configs/%s_source.py', 'stat-and-debug': 'builds/releng_sub_%s_configs/%s_stat_and_debug.py', 'api-9-debug': 'builds/releng_sub_%s_configs/%s_api_9_debug.py', 'api-11-debug': 'builds/releng_sub_%s_configs/%s_api_11_debug.py', 'horizon': 'builds/releng_sub_%s_configs/%s_horizon.py', 'debug': 'builds/releng_sub_%s_configs/%s_debug.py', 'asan': 'builds/releng_sub_%s_configs/%s_asan.py', 'asan-and-debug': 'builds/releng_sub_%s_configs/%s_asan_and_debug.py', 'x86': 'builds/releng_sub_%s_configs/%s_x86.py'}
config_file_search_path = ['.', '/home/docs/checkouts/readthedocs.org/user_builds/moz-releng-mozharness/checkouts/latest/mozharness/../configs', '/home/docs/checkouts/readthedocs.org/user_builds/moz-releng-mozharness/checkouts/latest/mozharness/../../configs']
platform = None
classmethod set_bits(option, opt, value, parser)[source]
classmethod set_build_branch(option, opt, value, parser)[source]
classmethod set_build_pool(option, opt, value, parser)[source]
classmethod set_build_variant(option, opt, value, parser)[source]

sets an extra config file.

This is done by either taking an existing filepath or by taking a valid shortname coupled with known platform/bits.

classmethod set_platform(option, opt, value, parser)[source]
class mozharness.mozilla.building.buildbase.BuildScript(**kwargs)[source]

Bases: mozharness.mozilla.buildbot.BuildbotMixin, mozharness.mozilla.purge.PurgeMixin, mozharness.mozilla.mock.MockMixin, mozharness.mozilla.updates.balrog.BalrogMixin, mozharness.mozilla.signing.SigningMixin, mozharness.base.python.VirtualenvMixin, mozharness.base.vcs.vcsbase.MercurialScript, mozharness.base.transfer.TransferMixin, mozharness.base.python.InfluxRecordingMixin

build()[source]

builds application.

check_test()[source]
checkout_sources()[source]
clone_tools()[source]

clones the tools repo.

generate_build_props(console_output=True, halt_on_failure=False)[source]

sets props found from mach build and, in addition, buildid, sourcestamp, appVersion, and appName.

generate_build_stats()[source]

grab build stats following a compile.

This action handles all statistics from a build: ‘count_ctors’ and then posts to graph server the results. We only post to graph server for non nightly build

multi_l10n()[source]
package_source()[source]

generates source archives and uploads them

postflight_build(console_output=True)[source]

grabs properties from post build and calls ccache -s

preflight_build()[source]

set up machine state for a complete build.

preflight_package_source()[source]
query_build_env(replace_dict=None, **kwargs)[source]
query_buildid()[source]
query_builduid()[source]
query_check_test_env()[source]
query_mach_build_env(multiLocale=None)[source]
query_pushdate()[source]
query_revision(source_path=None)[source]

returns the revision of the build

first will look for it in buildbot_properties and then in buildbot_config. Failing that, it will actually poll the source of the repo if it exists yet.

This method is used both to figure out what revision to check out and to figure out what revision was checked out.

sendchange()[source]
update()[source]

submit balrog update steps.

upload_files()[source]
class mozharness.mozilla.building.buildbase.BuildingConfig(config=None, initial_config_file=None, config_options=None, all_actions=None, default_actions=None, volatile_config=None, option_args=None, require_config_file=False, append_env_variables_from_configs=False, usage='usage: %prog [options]')[source]

Bases: mozharness.base.config.BaseConfig

get_cfgs_from_files(all_config_files, options)[source]

Determine the configuration from the normal options and from –branch, –build-pool, and –custom-build-variant-cfg. If the files for any of the latter options are also given with –config-file or –opt-config-file, they are only parsed once.

The build pool has highest precedence, followed by branch, build variant, and any normally-specified configuration files.

class mozharness.mozilla.building.buildbase.CheckTestCompleteParser(**kwargs)[source]

Bases: mozharness.base.log.OutputParser

evaluate_parser()[source]
parse_single_line(line)[source]
tbpl_error_list = [{'regex': <_sre.SRE_Pattern object at 0x7fd926f5fc38>, 'level': 'RETRY'}, {'regex': <_sre.SRE_Pattern object at 0x7fd92704c030>, 'level': 'RETRY'}, {'regex': <_sre.SRE_Pattern object at 0x7fd926f149c0>, 'level': 'RETRY'}]
class mozharness.mozilla.building.buildbase.MakeUploadOutputParser(use_package_as_marfile=False, package_filename=None, **kwargs)[source]

Bases: mozharness.base.log.OutputParser

parse_single_line(line)[source]
property_conditions = [('symbolsUrl', "m.endswith('crashreporter-symbols.zip') or m.endswith('crashreporter-symbols-full.zip')"), ('testsUrl', "m.endswith(('tests.tar.bz2', 'tests.zip'))"), ('unsignedApkUrl', "m.endswith('apk') and 'unsigned-unaligned' in m"), ('robocopApkUrl', "m.endswith('apk') and 'robocop' in m"), ('jsshellUrl', "'jsshell-' in m and m.endswith('.zip')"), ('partialMarUrl', "m.endswith('.mar') and '.partial.' in m"), ('completeMarUrl', "m.endswith('.mar')"), ('codeCoverageUrl', "m.endswith('code-coverage-gcno.zip')")]
tbpl_error_list = [{'regex': <_sre.SRE_Pattern object at 0x7fd926f5fc38>, 'level': 'RETRY'}, {'regex': <_sre.SRE_Pattern object at 0x7fd92704c030>, 'level': 'RETRY'}, {'regex': <_sre.SRE_Pattern object at 0x7fd926f149c0>, 'level': 'RETRY'}]
mozharness.mozilla.building.buildbase.generate_build_ID()[source]
mozharness.mozilla.building.buildbase.generate_build_UID()[source]

Module contents