Bug: Intermittent TV toolkit/components/nimbus/test/browser/browser_remotesettings_experiment_enroll.js | A promise chain failed to handle a rejection: An experiment with the slug "foo1613792262087" already exists. - stack: enroll@resource://nimbus/lib/Experim
Status: RESOLVED
Priority: P1
Resolution: FIXED
Created: 2021-02-20 06:51:41+00:00
Resolved: 2021-03-25 16:29:51+00:00

**Filed by:** malexandru [at] mozilla.com
**Parsed log:** https://treeherder.mozilla.org/logviewer?job_id=330586872&repo=autoland
**Full log:** https://firefox-ci-tc.services.mozilla.com/api/queue/v1/task/Y0nhYu2DSH-jT2PtDTJDgQ/runs/0/artifacts/public/logs/live_backing.log
**Reftest URL:** https://hg.mozilla.org/mozilla-central/raw-file/tip/layout/tools/reftest/reftest-analyzer.xhtml#logurl=https://firefox-ci-tc.services.mozilla.com/api/queue/v1/task/Y0nhYu2DSH-jT2PtDTJDgQ/runs/0/artifacts/public/logs/live_backing.log&only_show_unexpected=1

---
```
[task 2021-02-20T03:37:42.015Z] 03:37:42     INFO - TEST-OK | toolkit/components/nimbus/test/browser/browser_remotesettings_experiment_enroll.js | took 67ms
[task 2021-02-20T03:37:42.039Z] 03:37:42     INFO - checking window state
[task 2021-02-20T03:37:42.059Z] 03:37:42     INFO - TEST-START | toolkit/components/nimbus/test/browser/browser_remotesettings_experiment_enroll.js
[task 2021-02-20T03:37:42.080Z] 03:37:42     INFO - GECKO(11877) | console.debug: RSLoader:
[task 2021-02-20T03:37:42.081Z] 03:37:42     INFO - GECKO(11877) |   Registered update timer
[task 2021-02-20T03:37:42.081Z] 03:37:42     INFO - GECKO(11877) | console.debug: RSLoader:
[task 2021-02-20T03:37:42.082Z] 03:37:42     INFO - GECKO(11877) |   Updating recipes
[task 2021-02-20T03:37:42.105Z] 03:37:42     INFO - GECKO(11877) | console.debug: RSLoader:
[task 2021-02-20T03:37:42.105Z] 03:37:42     INFO - GECKO(11877) |   Got 1 recipes from Remote Settings
[task 2021-02-20T03:37:42.105Z] 03:37:42     INFO - GECKO(11877) | console.debug: RSLoader:
[task 2021-02-20T03:37:42.106Z] 03:37:42     INFO - GECKO(11877) |   No targeting for recipe, so it matches automatically
[task 2021-02-20T03:37:42.106Z] 03:37:42     INFO - GECKO(11877) | console.debug: RSLoader:
[task 2021-02-20T03:37:42.108Z] 03:37:42     INFO - GECKO(11877) |   8a9a1735-c107-4e69-aa42-92a684083ae7 matched
[task 2021-02-20T03:37:42.109Z] 03:37:42     INFO - GECKO(11877) | console.debug: RSLoader:
[task 2021-02-20T03:37:42.109Z] 03:37:42     INFO - GECKO(11877) |   Got 1 recipes from Remote Settings
[task 2021-02-20T03:37:42.110Z] 03:37:42     INFO - GECKO(11877) | console.debug: RSLoader:
[task 2021-02-20T03:37:42.110Z] 03:37:42     INFO - GECKO(11877) |   No targeting for recipe, so it matches automatically
[task 2021-02-20T03:37:42.111Z] 03:37:42     INFO - GECKO(11877) | console.debug: RSLoader:
[task 2021-02-20T03:37:42.111Z] 03:37:42     INFO - GECKO(11877) |   8a9a1735-c107-4e69-aa42-92a684083ae7 matched
[task 2021-02-20T03:37:42.126Z] 03:37:42     INFO - GECKO(11877) | console.debug: ExperimentManager:
[task 2021-02-20T03:37:42.126Z] 03:37:42     INFO - GECKO(11877) |   New experiment started: foo1613792262087, treatment
[task 2021-02-20T03:37:42.127Z] 03:37:42     INFO - GECKO(11877) | console.debug: ExperimentManager:
[task 2021-02-20T03:37:42.127Z] 03:37:42     INFO - GECKO(11877) |   Experiment unenrolled: foo1613792262087
[task 2021-02-20T03:37:42.128Z] 03:37:42     INFO - GECKO(11877) | console.debug: RSLoader:
[task 2021-02-20T03:37:42.128Z] 03:37:42     INFO - GECKO(11877) |   1 recipes matched. Finalizing ExperimentManager.
[task 2021-02-20T03:37:42.130Z] 03:37:42     INFO - GECKO(11877) | JavaScript error: resource://nimbus/lib/ExperimentManager.jsm, line 200: Error: An experiment with the slug "foo1613792262087" already exists.
[task 2021-02-20T03:37:42.131Z] 03:37:42     INFO - GECKO(11877) | console.debug: RSLoader:
[task 2021-02-20T03:37:42.133Z] 03:37:42     INFO - GECKO(11877) |   Registered update timer
[task 2021-02-20T03:37:42.134Z] 03:37:42     INFO - GECKO(11877) | console.debug: RSLoader:
[task 2021-02-20T03:37:42.137Z] 03:37:42     INFO - GECKO(11877) |   Updating recipes
[task 2021-02-20T03:37:42.137Z] 03:37:42     INFO - TEST-INFO | started process screentopng
[task 2021-02-20T03:37:42.347Z] 03:37:42     INFO - TEST-INFO | screentopng: exit 0
[task 2021-02-20T03:37:42.348Z] 03:37:42     INFO - Buffered messages logged at 03:37:42
[task 2021-02-20T03:37:42.348Z] 03:37:42     INFO - Entering test bound setup
[task 2021-02-20T03:37:42.348Z] 03:37:42     INFO - Leaving test bound setup
[task 2021-02-20T03:37:42.348Z] 03:37:42     INFO - Entering test bound test_experimentEnrollment
[task 2021-02-20T03:37:42.350Z] 03:37:42     INFO - Console message: [JavaScript Error: "Unknown Collection "main/nimbus-desktop-experiments"" {file: "resource://services-settings/RemoteSettingsClient.jsm" line: 160}]
[task 2021-02-20T03:37:42.350Z] 03:37:42     INFO - UnknownCollectionError@resource://services-settings/RemoteSettingsClient.jsm:160:5
[task 2021-02-20T03:37:42.350Z] 03:37:42     INFO - sync@resource://services-settings/RemoteSettingsClient.jsm:470:13
[task 2021-02-20T03:37:42.351Z] 03:37:42     INFO - 
[task 2021-02-20T03:37:42.351Z] 03:37:42     INFO - Console message: [JavaScript Error: "Unknown Collection "main/nimbus-desktop-experiments"" {file: "resource://services-settings/RemoteSettingsClient.jsm" line: 160}]
[task 2021-02-20T03:37:42.351Z] 03:37:42     INFO - UnknownCollectionError@resource://services-settings/RemoteSettingsClient.jsm:160:5
[task 2021-02-20T03:37:42.351Z] 03:37:42     INFO - sync@resource://services-settings/RemoteSettingsClient.jsm:470:13
[task 2021-02-20T03:37:42.351Z] 03:37:42     INFO - 
[task 2021-02-20T03:37:42.352Z] 03:37:42     INFO - TEST-PASS | toolkit/components/nimbus/test/browser/browser_remotesettings_experiment_enroll.js | Should be enrolled in the experiment - true == true - 
[task 2021-02-20T03:37:42.353Z] 03:37:42     INFO - TEST-PASS | toolkit/components/nimbus/test/browser/browser_remotesettings_experiment_enroll.js | Experiment is no longer active - true == true - 
[task 2021-02-20T03:37:42.354Z] 03:37:42     INFO - Leaving test bound test_experimentEnrollment
[task 2021-02-20T03:37:42.354Z] 03:37:42     INFO - Entering test bound test_experimentEnrollment_startup
[task 2021-02-20T03:37:42.355Z] 03:37:42     INFO - Console message: 1613792262100	Toolkit.Telemetry	WARN	TelemetryEnvironment::setExperimentActive - the experiment type was truncated.
[task 2021-02-20T03:37:42.356Z] 03:37:42     INFO - TEST-PASS | toolkit/components/nimbus/test/browser/browser_remotesettings_experiment_enroll.js | Should be disabled - true == true - 
[task 2021-02-20T03:37:42.356Z] 03:37:42     INFO - Console message: [JavaScript Error: "Error: An experiment with the slug "foo1613792262087" already exists." {file: "resource://nimbus/lib/ExperimentManager.jsm" line: 200}]
[task 2021-02-20T03:37:42.357Z] 03:37:42     INFO - TEST-PASS | toolkit/components/nimbus/test/browser/browser_remotesettings_experiment_enroll.js | Should still be disabled (feature pref is off) - true == true - 
[task 2021-02-20T03:37:42.358Z] 03:37:42     INFO - TEST-PASS | toolkit/components/nimbus/test/browser/browser_remotesettings_experiment_enroll.js | Should finally be enabled - true == true - 
[task 2021-02-20T03:37:42.358Z] 03:37:42     INFO - Buffered messages finished
[task 2021-02-20T03:37:42.358Z] 03:37:42     INFO - TEST-UNEXPECTED-FAIL | toolkit/components/nimbus/test/browser/browser_remotesettings_experiment_enroll.js | A promise chain failed to handle a rejection: An experiment with the slug "foo1613792262087" already exists. - stack: enroll@resource://nimbus/lib/ExperimentManager.jsm:200:13
[task 2021-02-20T03:37:42.359Z] 03:37:42     INFO - onRecipe@resource://nimbus/lib/ExperimentManager.jsm:118:18
[task 2021-02-20T03:37:42.359Z] 03:37:42     INFO - Rejection date: Sat Feb 20 2021 03:37:42 GMT+0000 (Coordinated Universal Time) - false == true - JS frame :: resource://testing-common/PromiseTestUtils.jsm :: assertNoUncaughtRejections :: line 282
[task 2021-02-20T03:37:42.359Z] 03:37:42     INFO - Stack trace:
[task 2021-02-20T03:37:42.359Z] 03:37:42     INFO - resource://testing-common/PromiseTestUtils.jsm:assertNoUncaughtRejections:282
[task 2021-02-20T03:37:42.359Z] 03:37:42     INFO - chrome://mochikit/content/browser-test.js:Tester_execTest/<:1119
[task 2021-02-20T03:37:42.361Z] 03:37:42     INFO - Leaving test bound test_experimentEnrollment_startup
[task 2021-02-20T03:37:42.361Z] 03:37:42     INFO - GECKO(11877) | console.debug: RSLoader:
[task 2021-02-20T03:37:42.361Z] 03:37:42     INFO - GECKO(11877) |   Got 0 recipes from Remote Settings
[task 2021-02-20T03:37:42.362Z] 03:37:42     INFO - GECKO(11877) | console.debug: RSLoader:
[task 2021-02-20T03:37:42.362Z] 03:37:42     INFO - GECKO(11877) |   0 recipes matched. Finalizing ExperimentManager.
[task 2021-02-20T03:37:42.362Z] 03:37:42     INFO - GECKO(11877) | console.debug: RSLoader:
[task 2021-02-20T03:37:42.363Z] 03:37:42     INFO - GECKO(11877) |   Registered update timer
[task 2021-02-20T03:37:42.363Z] 03:37:42     INFO - GECKO(11877) | console.debug: RSLoader:
[task 2021-02-20T03:37:42.364Z] 03:37:42     INFO - GECKO(11877) |   Updating recipes
[task 2021-02-20T03:37:42.364Z] 03:37:42     INFO - GECKO(11877) | MEMORY STAT | vsize 2788MB | residentFast 301MB | heapAllocated 107MB
[task 2021-02-20T03:37:42.365Z] 03:37:42     INFO - TEST-OK | toolkit/components/nimbus/test/browser/browser_remotesettings_experiment_enroll.js | took 90ms
[task 2021-02-20T03:37:42.366Z] 03:37:42     INFO - checking window state
[task 2021-02-20T03:37:42.366Z] 03:37:42     INFO - GECKO(11877) | Completed ShutdownLeaks collections in process 11877
[task 2021-02-20T03:37:42.366Z] 03:37:42     INFO - TEST-START | Shutdown```