Closed Bug 1483941 Opened 6 years ago Closed 6 years ago

mach bootstrap should prompt regarding opt out collection of local build metrics

Categories

(Firefox Build System :: Bootstrap Configuration, enhancement)

enhancement
Not set
normal

Tracking

(firefox65 fixed)

RESOLVED FIXED
mozilla65
Tracking Status
firefox65 --- fixed

People

(Reporter: kmoir, Assigned: ted)

References

(Blocks 1 open bug)

Details

Attachments

(2 files)

As part of the work to enable local build metrics (bug 1362156), we need to enable a prompt for users that allows them to opt out of build collection metrics when they run mach bootstrap.  As well, they need to be able to rerun mach bootstrap to opt in or opt out of this data collection at points in the future. See https://bugzilla.mozilla.org/show_bug.cgi?id=1291053#c33 for details on the requirements as part of the review by the data steward.
Thanks for filing this! I knew this was something we wanted but apparently never filed a bug. One of the patches I have for bug 1237610 (not yet posted) changes the opt-in from an environment variable to a mach setting, which can be set in ~/.mozbuild/machrc. It should be straightforward to add a prompt in `mach bootstrap` to enable it.
That's great Ted.  I should have mentioned that the text that should appear in the prompt is here

https://bugzilla.mozilla.org/show_bug.cgi?id=1291053#c28
The text to appear in the prompt references an URL with more information on the data we are collecting, but as of now that url is "(url tbd)". Kim, do we have a link to build metrics documentation (or something relevant) to place there? Perhaps we should file a bug to get some kind of reference/docs to point developers at so they can make an informed decision on whether to opt in.
Flags: needinfo?(kmoir)
I don't think there is a standard place to describe data that we are collecting.  We could just create a wiki page which describes the schema of data we collect. Or if there is a plan to have a readthedocs link for build telemetry that would be fine too.
Flags: needinfo?(kmoir)
I don't currently have generated docs in any of my patches but we could add them. It would be extra nice if we could generate docs from the in-tree schema.
This commit adds some documentation about build telemetry
to the build system documentation. This doc should be used
as a reference during opt-in to build system telemetry,
and includes paths to the relevant files for users to audit
independently. Documentation regarding the schema types and
object properties was generated by the `jsonschema2rst` tool,
available on PyPI.
Pushed by cosheehan@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/122ac3c6e1dc
add documentation about build telemetry r=ted
https://hg.mozilla.org/mozilla-central/rev/122ac3c6e1dc
Status: NEW → RESOLVED
Closed: 6 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla64
Assignee: nobody → sheehan
This bug is not complete.  The last patch was to add documentation, there is still work to do to implement the mach bootstrap prompt so users can opt out of build telemetry data collection if they want.  Ted is working on this.
Status: RESOLVED → REOPENED
Resolution: FIXED → ---
Assignee: sheehan → ted
This change adds a prompt to enable build system telemetry as part of
bootstrap. The prompt will only be shown if the build.telemetry config value
is not present, so users will not be prompted again if they have already
opted-in. However, if a user answers 'no' we don't save that value to
the config file because the default is to not send telemetry, so unless
they manually add `telemetry = false` to their config file they will be
prompted again the next time they run bootstrap.

The config value is always written to `~/.mozbuild/machrc` where we store
other Firefox build-related state. A standalone function is used to write
the config file so that we can do so even when running from bootstrap.py
outside of the context of a mach command.

As part of this change a `prompt_yesno` method is added to `BaseBootstrapper`.
Attachment #9020011 - Attachment description: bug 1483941 - prompt to enable build system telemetry in bootstrap. r?build → bug 1483941 - prompt to enable build system telemetry in bootstrap. r?nalexander
Pushed by tmielczarek@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/dc7924e3ea6b
prompt to enable build system telemetry in bootstrap. r=nalexander
https://hg.mozilla.org/mozilla-central/rev/dc7924e3ea6b
Status: REOPENED → RESOLVED
Closed: 6 years ago6 years ago
Resolution: --- → FIXED
Target Milestone: mozilla64 → mozilla65
Depends on: 1504449
This was requested by arai
Backed out changeset dc7924e3ea6b (bug 1483941) for causing bug 1504449. a=backout
Backout link: https://hg.mozilla.org/mozilla-central/rev/50bad93c5bdf9b1e8bae884b895f6b9da9a21a48
Flags: needinfo?(ted)
Target Milestone: mozilla65 → ---
Status: RESOLVED → REOPENED
Resolution: FIXED → ---
Pushed by tmielczarek@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/c10f11cc335c
prompt to enable build system telemetry in bootstrap. r=nalexander
I fixed the imports to work in standalone bootstrap:
https://phabricator.services.mozilla.com/D9781?id=32402

re-landing this with rs=Pike on the new changes.
https://hg.mozilla.org/mozilla-central/rev/c10f11cc335c
Status: REOPENED → RESOLVED
Closed: 6 years ago6 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla65
Flags: needinfo?(ted)
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: