Closed Bug 1572758 Opened 1 year ago Closed 11 months ago

Unable to see Event in about:telemetry in artifact build

Categories

(Toolkit :: Telemetry, defect, P1)

70 Branch
defect

Tracking

()

RESOLVED FIXED
mozilla72
Tracking Status
firefox70 --- wontfix
firefox71 --- wontfix
firefox72 --- fixed

People

(Reporter: ewright, Assigned: janerik)

References

Details

Attachments

(1 file)

I was recently adding some event telemetry using Events.yaml. The event was in the content process.

  • I ran the build in artifact mode
  • I visited about:telemetry and could see the event show up in "keyed scalars > dynamic" but I saw no events listed under "Events".

  • I ran the build in regular mode
  • I visited about:telemetry again and saw the event show under "events > content"

I was under the impression that an artifact build could be used for this.

Definitely the artifact build should work exactly the same as a full build in this respect. Thank you for filing this bug.

Seems like there's a hole in our Build Faster support for Events, maybe related to bug 1563239

See Also: → 1563239
See Also: → 1573588
Assignee: nobody → chutten
Status: NEW → ASSIGNED
Priority: -- → P1

I'm having difficulty reproducing this with latest code. I tried

  1. Changing .mozconfig to build artifact
  2. Adding a new category and event definition to Events.yaml
  3. ./mach build faster && ./mach run
  4. Loading about:telemetry and opening the dev console to Telemetry.setEventRecordingEnabled and Telemetry.recordEvent
  5. Refreshing about:telemetry and checking the Events section

The event shows up properly, and is even summarized properly to Keyed Scalars > Parent. I must be missing something.

:ewright Can you help me find out what I'm missing?

Flags: needinfo?(ewright)

(In reply to Chris H-C :chutten from comment #2)

I'm having difficulty reproducing this with latest code. I tried

  1. Changing .mozconfig to build artifact
  2. Adding a new category and event definition to Events.yaml
  3. ./mach build faster && ./mach run
  4. Loading about:telemetry and opening the dev console to Telemetry.setEventRecordingEnabled and Telemetry.recordEvent
  5. Refreshing about:telemetry and checking the Events section

The event shows up properly, and is even summarized properly to Keyed Scalars > Parent. I must be missing something.

:ewright Can you help me find out what I'm missing?

sorry for taking a while, I was on PTO. I'll see if I can duplicate it again.

Flags: needinfo?(ewright)

Did it happen to happen again? Or shall I close this down?

Flags: needinfo?(ewright)

Closing for now.

Assignee: chutten → nobody
Status: ASSIGNED → NEW
Priority: P1 → P3

:chutten, thank you, sorry I haven't had time try to reproduce this yet. I'll re-open if I can reproduce again.

Flags: needinfo?(ewright)
Status: NEW → RESOLVED
Closed: 1 year ago
Resolution: --- → WORKSFORME

I can reproduce this. In both artifact and non-artifact builds, EventArtifactDefinitions.json next to my locally built binary is not json - it's a c++ header file - ie, it starts with:

/* This file is auto-generated, only for internal use in TelemetryEvent.h,
   see gen_event_data.py. */

#ifndef mozilla_TelemetryEventData_h
#define mozilla_TelemetryEventData_h
#include "core/EventInfo.h"
namespace {

#if defined(_MSC_VER) && !defined(__clang__)
const uint32_t gExtraKeysTable[] = {
#else
constexpr uint32_t gExtraKeysTable[] = {
#endif

The key different between artifact and non-artifact builds is that presumably the latter always has up-to-date events builtin so doesn't care about loading dynamic ones at runtime.

The console always reports:

1574227665947	Toolkit.Telemetry	ERROR	TelemetryController::registerEventProbes - there was an error loading EventArtifactDefinitions.json: SyntaxError: JSON.parse: unexpected character at line 1 column 1 of the JSON data(resource://gre/modules/TelemetryController.jsm:1355:28) JS Stack trace: registerEventProbes@TelemetryController.jsm:1355:28
async*registerJsProbes@TelemetryController.jsm:1265:16
async*setupTelemetry@TelemetryController.jsm:740:43
observe@TelemetryController.jsm:1001:21
observe@TelemetryController.jsm:187:17
TelemetryStartup.prototype.observe@TelemetryStartup.jsm:31:25

which is a manifestation of the above. Note that after a 'build faster', this file does have the new probes - ie, that file is successfully getting rebuild when necessary - it's just the wrong file!

I'm on Windows which tends to be rare around here, so I wonder if that has anything to with the difficulty in others reproducing?

Status: RESOLVED → REOPENED
Resolution: WORKSFORME → ---
Assignee: nobody → jrediger
Priority: P3 → P1
Pushed by jrediger@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/77735f86efb6
Fix generation of event artifact definitions caused by using the wrong entry point r=chutten
Status: REOPENED → RESOLVED
Closed: 1 year ago11 months ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla72

Since the status are different for nightly and release, what's the status for beta?
For more information, please visit auto_nag documentation.

You need to log in before you can comment on or make changes to this bug.