muk-it / muk_web

MuK Odoo Web Modules
GNU Lesser General Public License v3.0
108 stars 230 forks source link

[15.0] AppsMenu: Uncaught Promise > Cannot read properties of null (reading 'parentElement') #213

Open hussain opened 11 months ago

hussain commented 11 months ago

This error does not happen every time, but when it popup error shows it stays until cache is cleared. We started facing the issue after upgrading Odoo 15.0 from 20221231 to recent releases.

Error

UncaughtPromiseError > TypeError
Uncaught Promise > Cannot read properties of null (reading 'parentElement')
TypeError: Cannot read properties of null (reading 'parentElement')
    at Dropdown.onDropdownStateChanged (https://domain.com/web/assets/2015-28b285b/web.assets_backend.min.js:324:20)
    at EventBus.trigger (https://domain.com/web/assets/1917-71eb121/web.assets_common.min.js:765:145)
    at AppsMenu.changeStateAndNotify (https://domain.com/web/assets/2015-28b285b/web.assets_backend.min.js:317:118)
    at AppsMenu.close (https://domain.com/web/assets/2015-28b285b/web.assets_backend.min.js:318:21)
    at AppsMenu.<anonymous> (https://domain.com/web/assets/2015-28b285b/web.assets_backend.min.js:11732:59)
    at EventBus.trigger (https://domain.com/web/assets/1917-71eb121/web.assets_common.min.js:765:145)
    at ControllerComponent.mounted (https://domain.com/web/assets/2015-28b285b/web.assets_backend.min.js:2285:19)
    at ControllerComponent.__callMounted (https://domain.com/web/assets/1917-71eb121/web.assets_common.min.js:1321:66)
    at Fiber.complete (https://domain.com/web/assets/1917-71eb121/web.assets_common.min.js:1238:16)
    at https://domain.com/web/assets/1917-71eb121/web.assets_common.min.js:1206:65

We did further analysis for the time when error shows, the error occurs in case navbar is null so Odoo js Dropdown.onDropdownStateChanged will fail since el is null and has no .parentElement. Error occurs: Yes image

Error Occurs: No image

PierreAlainKouakou commented 10 months ago

Hello dear,

I am facing the same problem.

It only appears when using odoo with the Chrome browser.

The project is interesting.

I am on version 15 of Odoo community.

Have you found a solution please?