Bug: Intermittent toolkit/components/search/tests/xpcshell/test_list_json_locale.js | test_listJSONRegionOverride - [test_listJSONRegionOverride : 265] A promise chain failed to handle a rejection: Unable to arm timer, the object has been finalized.
Status: RESOLVED
Priority: P2
Resolution: FIXED
Created: 2020-09-03 02:41:08+00:00
Resolved: 2020-09-14 06:16:53+00:00

**Filed by:** malexandru [at] mozilla.com
**Parsed log:** https://treeherder.mozilla.org/logviewer.html#?job_id=314747693&repo=autoland
**Full log:** https://firefox-ci-tc.services.mozilla.com/api/queue/v1/task/T4SsEr0YR3GusKUxkXEeDg/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/T4SsEr0YR3GusKUxkXEeDg/runs/0/artifacts/public/logs/live_backing.log&only_show_unexpected=1

---

```
[task 2020-09-03T00:14:04.638Z] 00:14:04     INFO -  TEST-START | xpcshell.ini:toolkit/components/search/tests/xpcshell/test_list_json_locale.js
[task 2020-09-03T00:14:12.778Z] 00:14:12  WARNING -  TEST-UNEXPECTED-FAIL | xpcshell.ini:toolkit/components/search/tests/xpcshell/test_list_json_locale.js | xpcshell return code: 0
[task 2020-09-03T00:14:12.778Z] 00:14:12     INFO -  TEST-INFO took 8134ms
[task 2020-09-03T00:14:12.778Z] 00:14:12     INFO -  >>>>>>>
[task 2020-09-03T00:14:12.778Z] 00:14:12     INFO -  PID 4504 | *** You are running in chaos test mode. See ChaosMode.h. ***
[task 2020-09-03T00:14:12.778Z] 00:14:12     INFO -  (xpcshell/head.js) | test MAIN run_test pending (1)
[task 2020-09-03T00:14:12.779Z] 00:14:12     INFO -  (xpcshell/head.js) | test run_next_test 0 pending (2)
[task 2020-09-03T00:14:12.779Z] 00:14:12     INFO -  (xpcshell/head.js) | test MAIN run_test finished (2)
[task 2020-09-03T00:14:12.779Z] 00:14:12     INFO -  running event loop
[task 2020-09-03T00:14:12.779Z] 00:14:12     INFO -  xpcshell.ini:toolkit/components/search/tests/xpcshell/test_list_json_locale.js | Starting setup
[task 2020-09-03T00:14:12.779Z] 00:14:12     INFO -  (xpcshell/head.js) | test setup pending (2)
[task 2020-09-03T00:14:12.779Z] 00:14:12     INFO -  (xpcshell/head.js) | test run_next_test 0 finished (2)
[task 2020-09-03T00:14:12.780Z] 00:14:12     INFO -  PID 4504 | console.info: Region.jsm: "Updating home region:" "US"
[task 2020-09-03T00:14:12.780Z] 00:14:12     INFO -  (xpcshell/head.js) | test run_next_test 1 pending (2)
[task 2020-09-03T00:14:12.780Z] 00:14:12     INFO -  (xpcshell/head.js) | test setup finished (2)
[task 2020-09-03T00:14:12.780Z] 00:14:12     INFO -  xpcshell.ini:toolkit/components/search/tests/xpcshell/test_list_json_locale.js | Starting test_listJSONlocale
[task 2020-09-03T00:14:12.780Z] 00:14:12     INFO -  (xpcshell/head.js) | test test_listJSONlocale pending (2)
[task 2020-09-03T00:14:12.780Z] 00:14:12     INFO -  PID 4504 | console.info: Region.jsm: "_getRegion called"
[task 2020-09-03T00:14:12.780Z] 00:14:12     INFO -  PID 4504 | console.info: Region.jsm: "_getRegion url is: " ""
[task 2020-09-03T00:14:12.780Z] 00:14:12     INFO -  (xpcshell/head.js) | test run_next_test 1 finished (2)
[task 2020-09-03T00:14:12.781Z] 00:14:12     INFO -  PID 4504 | console.debug: SearchService: "init"
[task 2020-09-03T00:14:12.781Z] 00:14:12     INFO -  PID 4504 | console.error: SearchCache: "_readCacheFile: Error reading cache file:" (new Error("", "(unknown module)"))
[task 2020-09-03T00:14:12.781Z] 00:14:12     INFO -  PID 4504 | console.debug: SearchService: "_loadEngines: start"
[task 2020-09-03T00:14:12.781Z] 00:14:12     INFO -  PID 4504 | console.debug: SearchEngineSelector: "fetchEngineConfiguration de:US:default::false:xpcshell:42"
[task 2020-09-03T00:14:12.781Z] 00:14:12     INFO -  PID 4504 | console.debug: SearchEngineSelector: "fetchEngineConfiguration: engine@search.mozilla.org"
[task 2020-09-03T00:14:12.781Z] 00:14:12     INFO -  PID 4504 | console.debug: SearchService: "_loadEnginesFromConfig"
[task 2020-09-03T00:14:12.781Z] 00:14:12     INFO -  PID 4504 | console.debug: SearchService: "makeEngineFromConfig:" ({webExtension:{id:"engine@search.mozilla.org", locale:"default"}, orderHint:10000, default:"yes"})
[task 2020-09-03T00:14:12.781Z] 00:14:12     INFO -  PID 4504 | console.debug: SearchService: "addEnginesFromExtension: engine@search.mozilla.org"
[task 2020-09-03T00:14:12.781Z] 00:14:12     INFO -  PID 4504 | console.debug: SearchService: "addEnginesFromExtension: Ignoring builtIn engine."
[task 2020-09-03T00:14:12.782Z] 00:14:12     INFO -  PID 4504 | console.debug: SearchEngine: "_setIcon: Setting icon url for" "Test search engine" "to" "moz-extension://39a2674e-0227-ca40-a14a-9691d80d2c42/favicon.ico"
[task 2020-09-03T00:14:12.782Z] 00:14:12     INFO -  PID 4504 | console.debug: SearchService: "_addEngineToStore: Adding engine:" "Test search engine"
[task 2020-09-03T00:14:12.782Z] 00:14:12     INFO -  PID 4504 | console.debug: SearchService: "_loadEngines: loading" 0 "engines reported by AddonManager startup"
[task 2020-09-03T00:14:12.782Z] 00:14:12     INFO -  PID 4504 | console.debug: SearchService: "_loadEngines: done"
[task 2020-09-03T00:14:12.782Z] 00:14:12     INFO -  PID 4504 | console.debug: SearchService: "_init: engines loaded, writing cache"
[task 2020-09-03T00:14:12.782Z] 00:14:12     INFO -  PID 4504 | console.debug: SearchService: "Completed _init"
[task 2020-09-03T00:14:12.782Z] 00:14:12     INFO -  TEST-PASS | xpcshell.ini:toolkit/components/search/tests/xpcshell/test_list_json_locale.js | test_listJSONlocale - [test_listJSONlocale : 29] search initialized - true == true
[task 2020-09-03T00:14:12.782Z] 00:14:12     INFO -  PID 4504 | console.debug: SearchService: "init"
[task 2020-09-03T00:14:12.782Z] 00:14:12     INFO -  PID 4504 | console.debug: SearchService: "getEngines: getting all engines"
[task 2020-09-03T00:14:12.783Z] 00:14:12     INFO -  PID 4504 | console.debug: SearchService: "_buildSortedEngineList: using default orders"
[task 2020-09-03T00:14:12.783Z] 00:14:12     INFO -  TEST-PASS | xpcshell.ini:toolkit/components/search/tests/xpcshell/test_list_json_locale.js | test_listJSONlocale - [test_listJSONlocale : 32] Should have only one engine - 1 == 1
[task 2020-09-03T00:14:12.783Z] 00:14:12     INFO -  TEST-PASS | xpcshell.ini:toolkit/components/search/tests/xpcshell/test_list_json_locale.js | test_listJSONlocale - [test_listJSONlocale : 34] Should have the correct default engine - "Test search engine" == "Test search engine"
[task 2020-09-03T00:14:12.783Z] 00:14:12     INFO -  TEST-PASS | xpcshell.ini:toolkit/components/search/tests/xpcshell/test_list_json_locale.js | test_listJSONlocale - [test_listJSONlocale : 39] Should have the correct private default engine - "Test search engine" == "Test search engine"
[task 2020-09-03T00:14:12.783Z] 00:14:12     INFO -  (xpcshell/head.js) | test run_next_test 2 pending (2)
[task 2020-09-03T00:14:12.783Z] 00:14:12     INFO -  (xpcshell/head.js) | test test_listJSONlocale finished (2)
[task 2020-09-03T00:14:12.783Z] 00:14:12     INFO -  xpcshell.ini:toolkit/components/search/tests/xpcshell/test_list_json_locale.js | Starting test_listJSONlocaleSwitch
[task 2020-09-03T00:14:12.783Z] 00:14:12     INFO -  (xpcshell/head.js) | test test_listJSONlocaleSwitch pending (2)
[task 2020-09-03T00:14:12.783Z] 00:14:12     INFO -  (xpcshell/head.js) | test run_next_test 2 finished (2)
[task 2020-09-03T00:14:12.784Z] 00:14:12     INFO -  PID 4504 | console.debug: SearchService: "Running maybeReloadEngines"
[task 2020-09-03T00:14:12.784Z] 00:14:12     INFO -  PID 4504 | console.debug: SearchEngineSelector: "fetchEngineConfiguration fr:US:default::false:xpcshell:42"
[task 2020-09-03T00:14:12.784Z] 00:14:12     INFO -  PID 4504 | console.debug: SearchEngineSelector: "fetchEngineConfiguration: engine@search.mozilla.org,engine-pref@search.mozilla.org,engine-resourceicon@search.mozilla.org"
[task 2020-09-03T00:14:12.784Z] 00:14:12     INFO -  PID 4504 | console.debug: SearchEngine: "_setIcon: Setting icon url for" "Test search engine" "to" "moz-extension://39a2674e-0227-ca40-a14a-9691d80d2c42/favicon.ico"
[task 2020-09-03T00:14:12.784Z] 00:14:12     INFO -  PID 4504 | console.debug: SearchUtils: "NOTIFY: Engine:" "Test search engine" "Verb:" "engine-changed"
[task 2020-09-03T00:14:12.784Z] 00:14:12     INFO -  PID 4504 | console.debug: SearchService: "makeEngineFromConfig:" ({webExtension:{id:"engine-pref@search.mozilla.org", locale:"default"}, orderHint:7000, default:"no", defaultPrivate:"yes"})
[task 2020-09-03T00:14:12.784Z] 00:14:12     INFO -  PID 4504 | console.debug: SearchService: "_handleIgnoreListUpdated"
[task 2020-09-03T00:14:12.784Z] 00:14:12     INFO -  PID 4504 | console.debug: SearchService: "Running maybeReloadEngines"
[task 2020-09-03T00:14:12.784Z] 00:14:12     INFO -  PID 4504 | console.debug: SearchEngineSelector: "fetchEngineConfiguration fr:US:default::false:xpcshell:42"
[task 2020-09-03T00:14:12.784Z] 00:14:12     INFO -  PID 4504 | console.debug: SearchEngineSelector: "fetchEngineConfiguration: engine@search.mozilla.org,engine-pref@search.mozilla.org,engine-resourceicon@search.mozilla.org"
[task 2020-09-03T00:14:12.785Z] 00:14:12     INFO -  PID 4504 | console.debug: SearchEngine: "_setIcon: Setting icon url for" "Test search engine" "to" "moz-extension://39a2674e-0227-ca40-a14a-9691d80d2c42/favicon.ico"
[task 2020-09-03T00:14:12.785Z] 00:14:12     INFO -  PID 4504 | console.debug: SearchUtils: "NOTIFY: Engine:" "Test search engine" "Verb:" "engine-changed"
[task 2020-09-03T00:14:12.786Z] 00:14:12     INFO -  PID 4504 | console.debug: SearchService: "makeEngineFromConfig:" ({webExtension:{id:"engine-pref@search.mozilla.org", locale:"default"}, orderHint:7000, default:"no", defaultPrivate:"yes"})
[task 2020-09-03T00:14:12.786Z] 00:14:12     INFO -  "CONSOLE_MESSAGE: (info) 1599092049659	addons.xpi	WARN	Addon with ID engine-pref@search.mozilla.org already installed, older version will be disabled"
[task 2020-09-03T00:14:12.786Z] 00:14:12     INFO -  PID 4504 | console.debug: SearchService: "addEnginesFromExtension: engine-pref@search.mozilla.org"
[task 2020-09-03T00:14:12.786Z] 00:14:12     INFO -  PID 4504 | console.debug: SearchService: "addEnginesFromExtension: Ignoring builtIn engine."
[task 2020-09-03T00:14:12.786Z] 00:14:12     INFO -  PID 4504 | console.debug: SearchService: "_addEngineToStore: Adding engine:" "engine-pref"
[task 2020-09-03T00:14:12.787Z] 00:14:12     INFO -  PID 4504 | console.debug: SearchUtils: "NOTIFY: Engine:" "engine-pref" "Verb:" "engine-added"
[task 2020-09-03T00:14:12.787Z] 00:14:12     INFO -  PID 4504 | console.debug: SearchService: "makeEngineFromConfig:" ({webExtension:{id:"engine-resourceicon@search.mozilla.org", locale:"default"}, orderHint:9000, default:"no"})
[task 2020-09-03T00:14:12.787Z] 00:14:12     INFO -  PID 4504 | console.debug: SearchService: "addEnginesFromExtension: engine-pref@search.mozilla.org"
[task 2020-09-03T00:14:12.787Z] 00:14:12     INFO -  PID 4504 | console.debug: SearchEngineSelector: "fetchEngineConfiguration fr:US:default::false:xpcshell:42"
[task 2020-09-03T00:14:12.787Z] 00:14:12     INFO -  PID 4504 | console.debug: SearchEngineSelector: "fetchEngineConfiguration: engine@search.mozilla.org,engine-pref@search.mozilla.org,engine-resourceicon@search.mozilla.org"
[task 2020-09-03T00:14:12.787Z] 00:14:12     INFO -  PID 4504 | console.debug: SearchService: "init"
[task 2020-09-03T00:14:12.787Z] 00:14:12     INFO -  PID 4504 | console.debug: SearchService: "getEngines: getting all engines for" "engine-pref@search.mozilla.org"
[task 2020-09-03T00:14:12.787Z] 00:14:12     INFO -  PID 4504 | console.debug: SearchService: "_addEngineToStore: Adding engine:" "engine-pref"
[task 2020-09-03T00:14:12.787Z] 00:14:12     INFO -  PID 4504 | console.debug: SearchUtils: "NOTIFY: Engine:" "engine-pref" "Verb:" "engine-added"
[task 2020-09-03T00:14:12.787Z] 00:14:12     INFO -  PID 4504 | console.debug: SearchService: "makeEngineFromConfig:" ({webExtension:{id:"engine-resourceicon@search.mozilla.org", locale:"default"}, orderHint:9000, default:"no"})
[task 2020-09-03T00:14:12.788Z] 00:14:12     INFO -  PID 4504 | console.debug: SearchService: "addEnginesFromExtension: engine-resourceicon@search.mozilla.org"
[task 2020-09-03T00:14:12.788Z] 00:14:12     INFO -  PID 4504 | console.debug: SearchService: "addEnginesFromExtension: Ignoring builtIn engine."
[task 2020-09-03T00:14:12.788Z] 00:14:12     INFO -  PID 4504 | console.debug: SearchEngine: "_setIcon: Setting icon url for" "engine-resourceicon" "to" "moz-extension://0a396c93-99c4-8245-bae7-b3d4d8c7d76e/favicon.png"
[task 2020-09-03T00:14:12.788Z] 00:14:12     INFO -  PID 4504 | console.debug: SearchService: "_addEngineToStore: Adding engine:" "engine-resourceicon"
[task 2020-09-03T00:14:12.788Z] 00:14:12     INFO -  PID 4504 | console.debug: SearchUtils: "NOTIFY: Engine:" "engine-resourceicon" "Verb:" "engine-added"
[task 2020-09-03T00:14:12.788Z] 00:14:12     INFO -  PID 4504 | console.debug: SearchUtils: "NOTIFY: Engine:" "engine-pref" "Verb:" "engine-default-private"
[task 2020-09-03T00:14:12.788Z] 00:14:12     INFO -  PID 4504 | console.debug: SearchService: "maybeReloadEngines complete"
[task 2020-09-03T00:14:12.791Z] 00:14:12     INFO -  TEST-PASS | xpcshell.ini:toolkit/components/search/tests/xpcshell/test_list_json_locale.js | test_listJSONlocaleSwitch - [test_listJSONlocaleSwitch : 57] search initialized - true == true
[task 2020-09-03T00:14:12.791Z] 00:14:12     INFO -  PID 4504 | console.debug: SearchService: "init"
[task 2020-09-03T00:14:12.791Z] 00:14:12     INFO -  PID 4504 | console.debug: SearchService: "getEngines: getting all engines"
[task 2020-09-03T00:14:12.791Z] 00:14:12     INFO -  PID 4504 | console.debug: SearchService: "_buildSortedEngineList: using default orders"
[task 2020-09-03T00:14:12.833Z] 00:14:12     INFO -  TEST-PASS | xpcshell.ini:toolkit/components/search/tests/xpcshell/test_list_json_locale.js | test_listJSONlocaleSwitch - [test_listJSONlocaleSwitch : 60] Should have the correct engine list - ["Test search engine","engine-pref","engine-resourceicon"] deepEqual ["Test search engine","engine-pref","engine-resourceicon"]
[task 2020-09-03T00:14:12.833Z] 00:14:12     INFO -  TEST-PASS | xpcshell.ini:toolkit/components/search/tests/xpcshell/test_list_json_locale.js | test_listJSONlocaleSwitch - [test_listJSONlocaleSwitch : 66] Should have the correct default engine - "Test search engine" == "Test search engine"
[task 2020-09-03T00:14:12.833Z] 00:14:12     INFO -  TEST-PASS | xpcshell.ini:toolkit/components/search/tests/xpcshell/test_list_json_locale.js | test_listJSONlocaleSwitch - [test_listJSONlocaleSwitch : 71] Should have the correct private default engine - "engine-pref" == "engine-pref"
[task 2020-09-03T00:14:12.833Z] 00:14:12     INFO -  (xpcshell/head.js) | test run_next_test 3 pending (2)
[task 2020-09-03T00:14:12.833Z] 00:14:12     INFO -  (xpcshell/head.js) | test test_listJSONlocaleSwitch finished (2)
[task 2020-09-03T00:14:12.833Z] 00:14:12     INFO -  xpcshell.ini:toolkit/components/search/tests/xpcshell/test_list_json_locale.js | Starting test_listJSONRegionOverride
[task 2020-09-03T00:14:12.833Z] 00:14:12     INFO -  (xpcshell/head.js) | test test_listJSONRegionOverride pending (2)
[task 2020-09-03T00:14:12.833Z] 00:14:12     INFO -  PID 4504 | console.info: Region.jsm: "Updating home region:" "RU"
[task 2020-09-03T00:14:12.833Z] 00:14:12     INFO -  PID 4504 | console.debug: SearchService: "Region updated:" "RU"
[task 2020-09-03T00:14:12.833Z] 00:14:12     INFO -  PID 4504 | console.debug: SearchService: "Running maybeReloadEngines"
```