• Resolved Anders Kanten

    (@akanten)


    At my page https://www.investeringsbloggen.no when i click the site kit icon on top, i get this error below.

    I have Yoast, Imagify and WP-rocket. Not much else.
    If i go via the console, it works. Its just the admin drop down at the actual site.

    An error occurred while running 'mapSelect': Cannot read properties of null (reading 'isGatheringData')
    The error may be correlated with this previous error:
    TypeError: Cannot read properties of null (reading 'isGatheringData')
        at Object.current (https://www.investeringsbloggen.no/wp-content/cache/min/1/wp-content/plugins/google-site-kit/dist/assets/js/googlesitekit-adminbar-25d8f70d4f48bfe6b0b1.js?ver=1643572391:1:108422)
        at e (https://www.investeringsbloggen.no/wp-content/cache/min/1/wp-content/plugins/google-site-kit/dist/assets/js/googlesitekit-vendor-9538ca334fe900a1f94f.js?ver=1643572391:1:190209)
        at https://www.investeringsbloggen.no/wp-content/cache/min/1/wp-content/plugins/google-site-kit/dist/assets/js/googlesitekit-vendor-9538ca334fe900a1f94f.js?ver=1643572391:1:190318
        at Ui (https://www.investeringsbloggen.no/wp-content/cache/min/1/wp-content/plugins/google-site-kit/dist/assets/js/googlesitekit-vendor-9538ca334fe900a1f94f.js?ver=1643572391:1:823504)
        at va (https://www.investeringsbloggen.no/wp-content/cache/min/1/wp-content/plugins/google-site-kit/dist/assets/js/googlesitekit-vendor-9538ca334fe900a1f94f.js?ver=1643572391:1:846431)
        at t.unstable_runWithPriority (https://www.investeringsbloggen.no/wp-content/cache/min/1/wp-content/plugins/google-site-kit/dist/assets/js/googlesitekit-vendor-9538ca334fe900a1f94f.js?ver=1643572391:1:866056)
        at Mr (https://www.investeringsbloggen.no/wp-content/cache/min/1/wp-content/plugins/google-site-kit/dist/assets/js/googlesitekit-vendor-9538ca334fe900a1f94f.js?ver=1643572391:1:791156)
        at Yj (https://www.investeringsbloggen.no/wp-content/cache/min/1/wp-content/plugins/google-site-kit/dist/assets/js/googlesitekit-vendor-9538ca334fe900a1f94f.js?ver=1643572391:1:842858)
        at Lj (https://www.investeringsbloggen.no/wp-content/cache/min/1/wp-content/plugins/google-site-kit/dist/assets/js/googlesitekit-vendor-9538ca334fe900a1f94f.js?ver=1643572391:1:833216)
        at https://www.investeringsbloggen.no/wp-content/cache/min/1/wp-content/plugins/google-site-kit/dist/assets/js/googlesitekit-vendor-9538ca334fe900a1f94f.js?ver=1643572391:1:791447
    
    Original stack trace:
    
        in AdminBarSessions
        in WithWidgetComponentProps(AdminBarSessions)
        in div
        in Cell
        in div
        in Row
        in AdminBarWidgets
        in div
        in Cell
        in div
        in Row
        in div
        in ForwardRef
        in AdminBarApp
        in RestoreSnapshots
        in ErrorHandler
        in Root

    Can anyone help with this?
    It seems like everything still works and the sites not broken.

    Best,

    Anders

Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Support James Osborne

    (@jamesosborne)

    Hi Anders,

    This error which you’re reporting is due to a known conflict with your WP Rocket minification configuration and the Site Kit admin toolbar, with all Site Kit JavaScript resources already minified.

    We have some workarounds listed for this error in the related GitHub issue on the Site Kit repository. Note that these workarounds are only temporary, as WP Rocket are planning on excluding Site Kit resources from such configurations going forward.

    In the meantime please confirm you don’t encounter the same error if you’ve tried any of the workarounds mentioned in the GitHub issue. The error you’re encountering only occurs for admins when using the Site Kit toolbar, so as you referenced all should work fine elsewhere.

    Thread Starter Anders Kanten

    (@akanten)

    Hi! I just ticked the box “remove from top bar” or something like that.
    No error message now.

    I think it is because wp comprimize the top section of code and site kit does not like that. I still get the stats okay, so I think I will be happy with this solution.

    Thank you for your help and thorough answer.

    Anders

    Plugin Support James Osborne

    (@jamesosborne)

    Hi Anders,

    Removing the Site Kit admin bar would indeed result in this error no longer occurring. Note however that you won’t be able to view stats on any page visited directly from the admin toolbar without this.

    If you do decide to enable the Site Kit admin toolbar one more WP have just merged a fix which now excludes Site Kit resources from minification (With all Site Kit JS resources already minified). For that reason let me know us know if you do decide to do so should you run into any other errors.

    We also have some documentation on the plugin website in relation to this error.

    Best of luck with your Site Kit enabled site going forward!

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Site kit gives me an error’ is closed to new replies.