Open Bug 1728821 Opened 3 years ago Updated 6 months ago

Intermittent LeakSanitizer | leak at mozilla::extensions::AtomSet::Get, mozilla::extensions::MatchPattern::Init, mozilla::extensions::MatchPattern::Constructor, mozilla::extensions::MatchPatternSet::Constructor

Categories

(WebExtensions :: General, defect, P5)

defect

Tracking

(Not tracked)

REOPENED

People

(Reporter: intermittent-bug-filer, Unassigned, NeedInfo)

References

Details

(Keywords: intermittent-failure, Whiteboard: [stockwell unknown])

Filed by: apavel [at] mozilla.com
Parsed log: https://treeherder.mozilla.org/logviewer?job_id=350360493&repo=mozilla-release
Full log: https://firefox-ci-tc.services.mozilla.com/api/queue/v1/task/T-qAGFWHRQub6U1pyf4chA/runs/0/artifacts/public/logs/live_backing.log


[task 2021-09-02T14:57:01.722Z] 14:57:01     INFO - TEST-OK | /webdriver/tests/bidi/new_session/connect.py | took 48495ms
[task 2021-09-02T14:57:01.722Z] 14:57:01     INFO - Restarting browser for new test group
[task 2021-09-02T14:57:01.779Z] 14:57:01     INFO - STDOUT:         request.addfinalizer(finalizer)
[task 2021-09-02T14:57:01.780Z] 14:57:01     INFO - STDOUT: >       return loop.run_until_complete(setup())
[task 2021-09-02T14:57:01.780Z] 14:57:01     INFO - STDOUT: args       = ()
[task 2021-09-02T14:57:01.780Z] 14:57:01     INFO - STDOUT: finalizer  = <function pytest_fixture_setup.<locals>.wrapper.<locals>.finalizer at 0x7fe84a6467b8>
[task 2021-09-02T14:57:01.780Z] 14:57:01     INFO - STDOUT: fixture_stripper = <pytest_asyncio.plugin.FixtureStripper object at 0x7fe84a612860>
[task 2021-09-02T14:57:01.781Z] 14:57:01     INFO - STDOUT: gen_obj    = <async_generator object bidi_session at 0x7fe84a5b0db0>
[task 2021-09-02T14:57:01.781Z] 14:57:01     INFO - STDOUT: generator  = <function bidi_session at 0x7fe84aefa620>
[task 2021-09-02T14:57:01.782Z] 14:57:01     INFO - STDOUT: kwargs     = {'capabilities': {'acceptInsecureCerts': True},
[task 2021-09-02T14:57:01.782Z] 14:57:01     INFO -  'configuration': {'capabilities': {'moz:firefoxOptions': {'args': ['--profile',
[task 2021-09-02T14:57:01.782Z] 14:57:01     INFO -                                                                     '/tmp/tmpm_zprjip.mozrunner'],
[task 2021-09-02T14:57:01.782Z] 14:57:01     INFO -                                                            'binary': '/builds/worker/workspace/build/application/firefox/firefox'}},
[task 2021-09-02T14:57:01.782Z] 14:57:01     INFO -                    'host': '127.0.0.1',
[task 2021-09-02T14:57:01.782Z] 14:57:01     INFO -                    'port': 46022},
[task 2021-09-02T14:57:01.783Z] 14:57:01     INFO -  'request': <SubRequest 'bidi_session' for <Function test_bidi_session_with_different_capability[capabilities0]>>}
[task 2021-09-02T14:57:01.783Z] 14:57:01     INFO - STDOUT: loop       = <_UnixSelectorEventLoop running=False closed=False debug=False>
[task 2021-09-02T14:57:01.783Z] 14:57:01     INFO - STDOUT: request    = <SubRequest 'bidi_session' for <Function test_bidi_session_with_different_capability[capabilities0]>>
[task 2021-09-02T14:57:01.784Z] 14:57:01     INFO - STDOUT: setup      = <function pytest_fixture_setup.<locals>.wrapper.<locals>.setup at 0x7fe8580e2488>
[task 2021-09-02T14:57:01.784Z] 14:57:01     INFO - STDOUT: tests/web-platform/tests/tools/third_party/pytest-asyncio/pytest_asyncio/plugin.py
[task 2021-09-02T14:57:01.784Z] 14:57:01     INFO - STDOUT: :127: 
[task 2021-09-02T14:57:01.785Z] 14:57:01     INFO - STDOUT: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
[task 2021-09-02T14:57:01.785Z] 14:57:01     INFO - STDOUT: /usr/lib/python3.6/asyncio/base_events.py
[task 2021-09-02T14:57:01.785Z] 14:57:01     INFO - STDOUT: :484: in run_until_complete
[task 2021-09-02T14:57:01.786Z] 14:57:01     INFO - STDOUT:     return future.result()
[task 2021-09-02T14:57:01.786Z] 14:57:01     INFO - STDOUT:         future     = <Task finished coro=<pytest_fixture_setup.<locals>.wrapper.<locals>.setup() done, defined at /builds/worker/workspace/build/tests/web-platform/tests/tools/third_party/pytest-asyncio/pytest_asyncio/plugin.py:109> exception=<SessionNotCreatedException http_status=Requested bidi session, but webSocketUrl capability not found>>
[task 2021-09-02T14:57:01.786Z] 14:57:01     INFO - STDOUT:         new_task   = True
[task 2021-09-02T14:57:01.787Z] 14:57:01     INFO - STDOUT:         self       = <_UnixSelectorEventLoop running=False closed=False debug=False>
[task 2021-09-02T14:57:01.787Z] 14:57:01     INFO - STDOUT: tests/web-platform/tests/tools/third_party/pytest-asyncio/pytest_asyncio/plugin.py
[task 2021-09-02T14:57:01.787Z] 14:57:01     INFO - STDOUT: :110: in setup
[task 2021-09-02T14:57:01.788Z] 14:57:01     INFO - STDOUT:     res = await gen_obj.__anext__()
[task 2021-09-02T14:57:01.788Z] 14:57:01     INFO - STDOUT:         gen_obj    = <async_generator object bidi_session at 0x7fe84a5b0db0>
[task 2021-09-02T14:57:01.789Z] 14:57:01     INFO - STDOUT: tests/web-platform/tests/webdriver/tests/support/fixtures.py
[task 2021-09-02T14:57:01.789Z] 14:57:01     INFO - STDOUT: :205: in bidi_session
[task 2021-09-02T14:57:01.789Z] 14:57:01     INFO - STDOUT:     _current_session.start()
[task 2021-09-02T14:57:01.790Z] 14:57:01     INFO - STDOUT:         capabilities = {'acceptInsecureCerts': True}
[task 2021-09-02T14:57:01.790Z] 14:57:01     INFO - STDOUT:         caps       = {'alwaysMatch': {'acceptInsecureCerts': True,
[task 2021-09-02T14:57:01.790Z] 14:57:01     INFO -                  'moz:firefoxOptions': {'args': ['--profile',
[task 2021-09-02T14:57:01.790Z] 14:57:01     INFO -                                                  '/tmp/tmpm_zprjip.mozrunner'],
[task 2021-09-02T14:57:01.790Z] 14:57:01     INFO -                                         'binary': '/builds/worker/workspace/build/application/firefox/firefox'},
[task 2021-09-02T14:57:01.791Z] 14:57:01     INFO -                  'webSocketUrl': True}}
[task 2021-09-02T14:57:01.791Z] 14:57:01     INFO - STDOUT:         configuration = {'capabilities': {'moz:firefoxOptions': {'args': ['--profile',
[task 2021-09-02T14:57:01.791Z] 14:57:01     INFO -                                                   '/tmp/tmpm_zprjip.mozrunner'],
[task 2021-09-02T14:57:01.791Z] 14:57:01     INFO -                                          'binary': '/builds/worker/workspace/build/application/firefox/firefox'}},
[task 2021-09-02T14:57:01.791Z] 14:57:01     INFO -  'host': '127.0.0.1',
[task 2021-09-02T14:57:01.791Z] 14:57:01     INFO -  'port': 46022}
[task 2021-09-02T14:57:01.792Z] 14:57:01     INFO - STDOUT:         request    = <SubRequest 'bidi_session' for <Function test_bidi_session_with_different_capability[capabilities0]>>
[task 2021-09-02T14:57:01.792Z] 14:57:01     INFO - STDOUT: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
[task 2021-09-02T14:57:01.792Z] 14:57:01     INFO - STDOUT: self = <Session (disconnected)>
[task 2021-09-02T14:57:01.793Z] 14:57:01     INFO - STDOUT:     def start(self):
[task 2021-09-02T14:57:01.793Z] 14:57:01     INFO - STDOUT:         """Start a new WebDriver session.
[task 2021-09-02T14:57:01.793Z] 14:57:01     INFO - STDOUT:     
[task 2021-09-02T14:57:01.794Z] 14:57:01     INFO - STDOUT:         :return: Dictionary with `capabilities` and `sessionId`.
[task 2021-09-02T14:57:01.794Z] 14:57:01     INFO - STDOUT:     
[task 2021-09-02T14:57:01.794Z] 14:57:01     INFO - STDOUT:         :raises error.WebDriverException: If the remote end returns
[task 2021-09-02T14:57:01.795Z] 14:57:01     INFO - STDOUT:             an error.
[task 2021-09-02T14:57:01.795Z] 14:57:01     INFO - STDOUT:         """
[task 2021-09-02T14:57:01.795Z] 14:57:01     INFO - STDOUT:         if self.session_id is not None:
[task 2021-09-02T14:57:01.796Z] 14:57:01     INFO - STDOUT:             return
[task 2021-09-02T14:57:01.796Z] 14:57:01     INFO - STDOUT:     
[task 2021-09-02T14:57:01.796Z] 14:57:01     INFO - STDOUT:         self.transport.close()
[task 2021-09-02T14:57:01.797Z] 14:57:01     INFO - STDOUT:     
[task 2021-09-02T14:57:01.797Z] 14:57:01     INFO - STDOUT:         body = {"capabilities": {}}
[task 2021-09-02T14:57:01.797Z] 14:57:01     INFO - STDOUT:     
[task 2021-09-02T14:57:01.798Z] 14:57:01     INFO - STDOUT:         if self.requested_capabilities is not None:
[task 2021-09-02T14:57:01.798Z] 14:57:01     INFO - STDOUT:             body["capabilities"] = self.requested_capabilities
[task 2021-09-02T14:57:01.798Z] 14:57:01     INFO - STDOUT:     
[task 2021-09-02T14:57:01.799Z] 14:57:01     INFO - STDOUT:         value = self.send_command("POST", "session", body=body)
[task 2021-09-02T14:57:01.799Z] 14:57:01     INFO - STDOUT:         self.session_id = value["sessionId"]
[task 2021-09-02T14:57:01.799Z] 14:57:01     INFO - STDOUT:         self.capabilities = value["capabilities"]
[task 2021-09-02T14:57:01.800Z] 14:57:01     INFO - STDOUT:     
[task 2021-09-02T14:57:01.800Z] 14:57:01     INFO - STDOUT:         if "webSocketUrl" in self.capabilities:
[task 2021-09-02T14:57:01.800Z] 14:57:01     INFO - STDOUT:             self.bidi_session = BidiSession.from_http(self.session_id,
[task 2021-09-02T14:57:01.801Z] 14:57:01     INFO - STDOUT:                                                       self.capabilities)
[task 2021-09-02T14:57:01.801Z] 14:57:01     INFO - STDOUT:         elif self.enable_bidi:
[task 2021-09-02T14:57:01.801Z] 14:57:01     INFO - STDOUT:             self.end()
[task 2021-09-02T14:57:01.802Z] 14:57:01     INFO - STDOUT:             raise error.SessionNotCreatedException(
[task 2021-09-02T14:57:01.802Z] 14:57:01     INFO - STDOUT: >               "Requested bidi session, but webSocketUrl capability not found")
[task 2021-09-02T14:57:01.803Z] 14:57:01     INFO - STDOUT: E           webdriver.error.SessionNotCreatedException: session not created (Requested bidi session, but webSocketUrl capability not found)
[task 2021-09-02T14:57:01.803Z] 14:57:01     INFO - STDOUT: body       = {'capabilities': {'alwaysMatch': {'acceptInsecureCerts': True,
[task 2021-09-02T14:57:01.803Z] 14:57:01     INFO -                                   'moz:firefoxOptions': {'args': ['--profile',
[task 2021-09-02T14:57:01.803Z] 14:57:01     INFO -                                                                   '/tmp/tmpm_zprjip.mozrunner'],
[task 2021-09-02T14:57:01.804Z] 14:57:01     INFO -                                                          'binary': '/builds/worker/workspace/build/application/firefox/firefox'},
[task 2021-09-02T14:57:01.804Z] 14:57:01     INFO -                                   'webSocketUrl': True}}}
[task 2021-09-02T14:57:01.804Z] 14:57:01     INFO - STDOUT: self       = <Session (disconnected)>
[task 2021-09-02T14:57:01.805Z] 14:57:01     INFO - STDOUT: value      = {'capabilities': {'acceptInsecureCerts': True,
[task 2021-09-02T14:57:01.805Z] 14:57:01     INFO -                   'browserName': 'firefox',
[task 2021-09-02T14:57:01.805Z] 14:57:01     INFO -                   'browserVersion': '92.0',
[task 2021-09-02T14:57:01.805Z] 14:57:01     INFO -                   'moz:accessibilityChecks': False,
[task 2021-09-02T14:57:01.805Z] 14:57:01     INFO -                   'moz:buildID': '20210902133412',
[task 2021-09-02T14:57:01.805Z] 14:57:01     INFO -                   'moz:debuggerAddress': 'localhost:9222',
[task 2021-09-02T14:57:01.806Z] 14:57:01     INFO -                   'moz:geckodriverVersion': '0.29.1',
[task 2021-09-02T14:57:01.806Z] 14:57:01     INFO -                   'moz:headless': False,
[task 2021-09-02T14:57:01.806Z] 14:57:01     INFO -                   'moz:processID': 1663,
[task 2021-09-02T14:57:01.806Z] 14:57:01     INFO -                   'moz:profile': '/tmp/tmpm_zprjip.mozrunner',
[task 2021-09-02T14:57:01.806Z] 14:57:01     INFO -                   'moz:shutdownTimeout': 300000,
[task 2021-09-02T14:57:01.806Z] 14:57:01     INFO -                   'moz:useNonSpecCompliantPointerOrigin': False,
[task 2021-09-02T14:57:01.806Z] 14:57:01     INFO -                   'moz:webdriverClick': True,
[task 2021-09-02T14:57:01.806Z] 14:57:01     INFO -                   'pageLoadStrategy': 'normal',
[task 2021-09-02T14:57:01.806Z] 14:57:01     INFO -                   'platformName': 'linux',
[task 2021-09-02T14:57:01.806Z] 14:57:01     INFO -                   'platformVersion': '4.4.0-1014-aws',
[task 2021-09-02T14:57:01.806Z] 14:57:01     INFO -                   'proxy': {},
[task 2021-09-02T14:57:01.806Z] 14:57:01     INFO -                   'setWindowRect': True,
[task 2021-09-02T14:57:01.807Z] 14:57:01     INFO -                   'strictFileInteractability': False,
[task 2021-09-02T14:57:01.807Z] 14:57:01     INFO -                   'timeouts': {'implicit': 0,
[task 2021-09-02T14:57:01.807Z] 14:57:01     INFO -                                'pageLoad': 300000,
[task 2021-09-02T14:57:01.807Z] 14:57:01     INFO -                                'script': 30000},
[task 2021-09-02T14:57:01.807Z] 14:57:01     INFO -                   'unhandledPromptBehavior': 'dismiss and notify'},
[task 2021-09-02T14:57:01.807Z] 14:57:01     INFO -  'sessionId': 'd33ac4c6-47ed-4d27-89e7-5962e8bd51f9'}
[task 2021-09-02T14:57:01.808Z] 14:57:01     INFO - STDOUT: tests/web-platform/tests/tools/webdriver/webdriver/client.py
[task 2021-09-02T14:57:01.808Z] 14:57:01     INFO - STDOUT: :553: SessionNotCreatedException
[task 2021-09-02T14:57:01.809Z] 14:57:01     INFO - STDOUT: =================================== FAILURES ===================================
[task 2021-09-02T14:57:01.809Z] 14:57:01     INFO - STDOUT: __________________ test_websocket_url_connect[capabilities0] ___________________
[task 2021-09-02T14:57:01.810Z] 14:57:01     INFO - STDOUT: session = <Session db9fbed3-0110-4e10-a214-a3ce95664b83>
[task 2021-09-02T14:57:01.810Z] 14:57:01     INFO - STDOUT:     @pytest.mark.asyncio
[task 2021-09-02T14:57:01.810Z] 14:57:01     INFO - STDOUT:     @pytest.mark.capabilities({"webSocketUrl": True})
[task 2021-09-02T14:57:01.811Z] 14:57:01     INFO - STDOUT:     async def test_websocket_url_connect(session):
[task 2021-09-02T14:57:01.811Z] 14:57:01     INFO - STDOUT: >       websocket_url = session.capabilities["webSocketUrl"]
[task 2021-09-02T14:57:01.816Z] 14:57:01     INFO - STDOUT: E       KeyError: 'webSocketUrl'
[task 2021-09-02T14:57:01.816Z] 14:57:01     INFO - STDOUT: session    = <Session db9fbed3-0110-4e10-a214-a3ce95664b83>
[task 2021-09-02T14:57:01.816Z] 14:57:01     INFO - STDOUT: tests/web-platform/tests/webdriver/tests/bidi/new_session/connect.py
[task 2021-09-02T14:57:01.817Z] 14:57:01     INFO - STDOUT: :11: KeyError
[task 2021-09-02T14:57:01.817Z] 14:57:01     INFO - STDOUT: =========================== short test summary info ============================
[task 2021-09-02T14:57:01.817Z] 14:57:01     INFO - STDOUT: FAILED tests/web-platform/tests/webdriver/tests/bidi/new_session/connect.py::test_websocket_url_connect[capabilities0]
[task 2021-09-02T14:57:01.817Z] 14:57:01     INFO - STDOUT: ERROR tests/web-platform/tests/webdriver/tests/bidi/new_session/connect.py::test_bidi_session_send
[task 2021-09-02T14:57:01.817Z] 14:57:01     INFO - STDOUT: ERROR tests/web-platform/tests/webdriver/tests/bidi/new_session/connect.py::test_bidi_session_with_different_capability[capabilities0]
[task 2021-09-02T14:57:01.818Z] 14:57:01     INFO - STDOUT: ==================== 1 failed, 1 passed, 2 errors in 48.27s ====================
[task 2021-09-02T14:57:01.818Z] 14:57:01     INFO - ERROR | LeakSanitizer | SUMMARY: AddressSanitizer: 15710 byte(s) leaked in 140 allocation(s).
[task 2021-09-02T14:57:01.818Z] 14:57:01     INFO - LeakSanitizer | To show the addresses of leaked objects add report_objects=1 to LSAN_OPTIONS
[task 2021-09-02T14:57:01.818Z] 14:57:01     INFO - This can be done in testing/mozbase/mozrunner/mozrunner/utils.py
[task 2021-09-02T14:57:01.819Z] 14:57:01     INFO - Allowed depth was 4
[task 2021-09-02T14:57:01.819Z] 14:57:01     INFO - TEST-UNEXPECTED-FAIL | LeakSanitizer | leak at mozilla::extensions::AtomSet::Get, mozilla::extensions::MatchPattern::Init, mozilla::extensions::MatchPattern::Constructor, mozilla::extensions::MatchPatternSet::Constructor
[task 2021-09-02T14:57:01.819Z] 14:57:01     INFO - TEST-UNEXPECTED-FAIL | LeakSanitizer | leak at XPCNativeInterface::NewInstance, XPCNativeInterface::GetNewOrUsed, XPCNativeSet::GetNewOrUsed, XPCWrappedNativeProto::GetNewOrUsed
[task 2021-09-02T14:57:01.819Z] 14:57:01     INFO - TEST-UNEXPECTED-FAIL | LeakSanitizer | leak at XPCNativeSet::NewInstance, XPCNativeSet::GetNewOrUsed, XPCWrappedNative::GetNewOrUsed, XPCConvert::NativeInterface2JSObject
[task 2021-09-02T14:57:01.819Z] 14:57:01     INFO - TEST-UNEXPECTED-FAIL | LeakSanitizer | leak at XPCWrappedNativeProto::GetNewOrUsed, XPCWrappedNative::GetNewOrUsed, XPCConvert::NativeInterface2JSObject, GetServiceImpl
[task 2021-09-02T14:57:01.819Z] 14:57:01     INFO - TEST-UNEXPECTED-FAIL | LeakSanitizer | leak at mozilla::extensions::MatchPattern::Init, mozilla::extensions::MatchPattern::Constructor, mozilla::extensions::MatchPatternSet::Constructor, mozilla::dom::MatchPatternSet_Binding::_constructor
[task 2021-09-02T14:57:01.819Z] 14:57:01     INFO - TEST-UNEXPECTED-FAIL | LeakSanitizer | leak at mozilla::extensions::MatchPattern::Constructor, mozilla::extensions::MatchPatternSet::Constructor, mozilla::dom::MatchPatternSet_Binding::_constructor, CallJSNative
[task 2021-09-02T14:57:01.824Z] 14:57:01     INFO - TEST-UNEXPECTED-FAIL | LeakSanitizer | leak at XPCNativeSet::NewInstance, XPCNativeSet::GetNewOrUsed, XPCWrappedNativeProto::GetNewOrUsed, XPCWrappedNative::GetNewOrUsed
[task 2021-09-02T14:57:01.824Z] 14:57:01     INFO - TEST-UNEXPECTED-FAIL | LeakSanitizer | leak at Alloc, nsTSubstring, Gecko_StartBulkWriteCString, nsstring::nsACString::start_bulk_write_impl
[task 2021-09-02T14:57:01.824Z] 14:57:01     INFO - TEST-UNEXPECTED-FAIL | LeakSanitizer | leak at XPCWrappedNative::GetNewOrUsed, XPCConvert::NativeInterface2JSObject, GetServiceImpl, GetService
[task 2021-09-02T14:57:01.824Z] 14:57:01     INFO - TEST-UNEXPECTED-FAIL | LeakSanitizer | leak at XPCNativeInterface::NewInstance, XPCNativeInterface::GetNewOrUsed, XPCConvert::NativeInterface2JSObject, GetServiceImpl
[task 2021-09-02T14:57:01.824Z] 14:57:01     INFO - TEST-UNEXPECTED-FAIL | LeakSanitizer | leak at nsDynamicAtom::Create, nsAtomTable::Atomize, NS_Atomize, mozilla::extensions::AtomSet::AtomSet
[task 2021-09-02T14:57:01.825Z] 14:57:01     INFO - TEST-UNEXPECTED-FAIL | LeakSanitizer | leak at Realloc, nsTArray_base, Compact, mozilla::extensions::AtomSet::SortAndUniquify
[task 2021-09-02T14:57:01.825Z] 14:57:01     INFO - TEST-UNEXPECTED-FAIL | LeakSanitizer | leak at mozilla::extensions::MatchPattern::Constructor, mozilla::extensions::MatchPatternSet::Constructor, mozilla::dom::MatchPatternSet_Binding::_constructor, EnterJit
[task 2021-09-02T14:57:01.825Z] 14:57:01     INFO - TEST-UNEXPECTED-FAIL | LeakSanitizer | leak at Alloc, nsTSubstring, nsTSubstring, AssignJSString
[task 2021-09-02T14:57:01.825Z] 14:57:01     INFO - TEST-UNEXPECTED-FAIL | LeakSanitizer | leak at Alloc, nsTSubstring, nsTSubstring, nsTSubstring
[task 2021-09-02T14:57:01.825Z] 14:57:01     INFO - Closing logging queue
[task 2021-09-02T14:57:01.825Z] 14:57:01     INFO - queue closed
[task 2021-09-02T14:57:01.825Z] 14:57:01     INFO - Starting runner
[task 2021-09-02T14:57:02.240Z] 14:57:02     INFO - WebDriver HTTP server listening at http://127.0.0.1:54579/
Status: NEW → RESOLVED
Closed: 3 years ago
Resolution: --- → INCOMPLETE
Status: RESOLVED → REOPENED
Resolution: INCOMPLETE → ---
Status: REOPENED → RESOLVED
Closed: 3 years ago3 years ago
Resolution: --- → INCOMPLETE
Status: RESOLVED → REOPENED
Resolution: INCOMPLETE → ---
Status: REOPENED → RESOLVED
Closed: 3 years ago3 years ago
Resolution: --- → INCOMPLETE
Status: RESOLVED → REOPENED
Resolution: INCOMPLETE → ---
Blocks: LSan

As it looks like this leak is actually related to Webextensions. Moving for further triage.

Component: geckodriver → General
Product: Testing → WebExtensions
Status: REOPENED → RESOLVED
Closed: 3 years ago3 years ago
Resolution: --- → DUPLICATE
Status: RESOLVED → REOPENED
Resolution: DUPLICATE → ---

Shane, could someone please have a look at this issue? We see a couple of failures for Wd jobs (see bug 1745514). Thanks.

Flags: needinfo?(mixedpuppy)

There have been 42 total failures in the last 7 days, recent failure log.
Affected platforms are:

  • linux1804-64-asan-qr
Whiteboard: [stockwell needswork:owner]

The recent failures look like an ignore list issue, as there are a ton of leaks, and we're ignoring most of them.

I looked at one test, and it was in the /webdriver/tests/status/status.py directory. The file for the leaks we ignore for that test is here. I'm not sure if the other failures are for other tests. Anyways, you could probably add XPCWrappedNativeTearOff::AddTearOff to that list to make this failure go away.

Flags: needinfo?(mixedpuppy)

You should probably just switch these webdriver WPTs over to using lsan-disabled: true instead of lsan-allowed. That will just always ignore the leaks.

Flags: needinfo?(hskupin)

(In reply to Andrew McCreight [:mccr8] from comment #40)

You should probably just switch these webdriver WPTs over to using lsan-disabled: true instead of lsan-allowed. That will just always ignore the leaks.

Thanks for the pointer. We are going to discuss this later today in how we want to proceed forward with leaks as reported by wdspec tests.

Shane, could someone from the extensions team could have a look at this leak? It really fails across all of our wdspec tests and it would be great to know where it is coming from and to actually see it fixed as well. For now we will allow this leak for all of our tests. A patch for that will be uploaded soon to bug 1773218. Thanks!

Flags: needinfo?(hskupin) → needinfo?(mixedpuppy)

(In reply to Henrik Skupin (:whimboo) [⌚️UTC+1] from comment #43)

Shane, could someone from the extensions team could have a look at this leak? It really fails across all of our wdspec tests and it would be great to know where it is coming from and to actually see it fixed as well. For now we will allow this leak for all of our tests. A patch for that will be uploaded soon to bug 1773218. Thanks!

Hi Henrik, I'll try to take a look into this asap. In the meantime I'm re-assigning Shane needinfo to myself.

Flags: needinfo?(mixedpuppy) → needinfo?(lgreco)

Hi Henrik,
while I was looking the LSAN failure logs I recalled of another bug I investigated some time ago, an issue caught by the AddressSanitizer which involved both AtomSet::Get and MatchPattern::Init and MatchPatternSet::Constructor (that are all part of the failure logged by LSAN (e.g. like in these failure logs from the last failure tracked by this issue): Bug 1699298.

For that bug we did also have a Pernosco session that recorded the AddressSanitizer crash, and the following comment from that investigation may actually be relevant to investigating this one:

  • Bug 1699298 comment 2, where it mention that AtomSet::Get<...>() keeps a RefPtr for the AtomSet the first time it is called, and then it does pass it to ClearOnShutdown to free it as part of the XPCOM shutdown flow

That detail from the comment linked above made me wonder at which point of the shutdown LSAN is doing the leak checks, in case it is assuming those to be cleared before the shutdown is completed. On the contrary if LSAN is technically making those checks after the XPCOM shutdown has been technically completed then I wouldn't exclude this issue may be other one triggered by that static RefPtr<AtomSet> sMatcher ("unfortunate") pattern.

It may be worth double-checking with a Firefox Engineer with more direct experience with the ASAN builds (e.g. someone who works on fuzzy testing more often than me) if there is any chance that LSAN may be doing the leaks checks before the XPCOM shutdown has been completed.

In the meantime:

  • I have done a local ASAN build to try to trigger it locally and dig a bit more into it, and to try to possibly record it with rr and submit it to pernosco to make it easier to investigate what lead to trigger the issue and share the recorded execution between us, but I've not yet able to trigger it.

Feel free to ping me (here on bugzilla or on other channels, .e.g. Matrix and/or Slac) If you have an STR or some suggestions that may help to trigger this locally.

(I'll reassign the needinfo to me as a reminder that I'm still trying to reproduce it locally for some additional investigation).

Flags: needinfo?(lgreco)

Hi Christian,
sorry for the potentially trivial question related to when the LSAN leakchecks are being done:

I was looking into this and I recalled of Bug 1699298 comment 2 and so I was wondering if it can be taken for granted that LSAN leakcheck that is triggering the failures tracked by this issue are being executed after the XPCOM shutdown has been completed?

or is there any chance that it may be executed when technically we already know that the RefPtr allocated internally by the AtomSet::Get<...>() call isn't freed yet.

Let me know wdyt.

Flags: needinfo?(choller)

reassigning a needinfo to myself for further investigations.

Flags: needinfo?(lgreco)

You'll need to remove the ignore list stuff to get the leaks to show up, if you haven't done that already.

LSan runs after XPCOM shutdown.

(In reply to Andrew McCreight [:mccr8] from comment #49)

You'll need to remove the ignore list stuff to get the leaks to show up, if you haven't done that already.

LSan runs after XPCOM shutdown.

Thanks a lot Andrew! (both for mentioning that the ignore list may be what is preventing me to trigger the same failure locally, and for confirming that LSan should be running after XPCOM shutdown).

I'm also clearing the needinfo previously assigned to Christian.

Flags: needinfo?(choller)

The other thing I should mention is that LSan (unlike leakcheck) ignores leaks via global variables, so I think it'll never treat something in something like sMatcher (and whatever it holds onto) as leaked.

Hey Luca. So basically I never run an ASAN build locally and as such I cannot tell if one of the webdriver tests that we have will actually trigger this leak more often than others. As Andrew said as best get the following manifest files updated to actually get reports:

https://searchfox.org/mozilla-central/source/testing/web-platform/meta/webdriver/tests/__dir__.ini
https://searchfox.org/mozilla-central/source/testing/web-platform/mozilla/meta/webdriver/__dir__.ini

Please also note that web-platform-tests in general seem to be affected and it's interesting that we had such a high count of failures for WebDriver tests. Nevertheless for all of these tests Marionette is in use.

Interesting as well is that since June 11th no more failures have been reported even not for normal other web-platform tests:
https://treeherder.mozilla.org/intermittent-failures/bugdetails?startday=2022-05-17&endday=2022-06-16&tree=trunk&bug=1728821

What needs to be done to get a rr recording from a failing CI job?

(In reply to Henrik Skupin (:whimboo) [⌚️UTC+1] from comment #52)

What needs to be done to get a rr recording from a failing CI job?

It seems that mach try fuzzy supports a --pernosco cli option:

  --pernosco            Opt-in to analysis by the Pernosco debugging service.

In the past I have submitted a couple of rr recorded executions collected locally on a local build by using the pernosco-submit tool directly, but I never used this mach try fuzzy option and so it may be worth double-checking with someone that may have tried this mach try fuzzy option in case there is something in particular to be careful about when using it.

Aren't all ASAN builds actually opt builds? I vaguely remember that Pernosco requires debug builds - but I might be wrong here. So not sure if we could run try builds that easily at all. When checking Treeherder I can find some kind of NoOpt ASAN build for Linux, but not sure here as well what this actually is.

See Also: → 1800308
See Also: → 1772307
See Also: → 1802778
No longer blocks: LSan
You need to log in before you can comment on or make changes to this bug.