wagtail-nest / wagtail-ab-testing

A/B testing for Wagtail
Other
23 stars 20 forks source link

JavaScript error on create AB test page #84

Open vdboor opened 4 months ago

vdboor commented 4 months ago

On creating the AB test, the following error happens:

wagtail-ab-testing.js?v=afb7bfd0:2 Uncaught ReferenceError: abTestingTabProps is not defined
    at HTMLDocument.<anonymous> (wagtail-ab-testing.js?v=afb7bfd0:2:397058)

I'm running Wagtail 6.0.5, wagtail-ab-testing 0.10 on Python 5.0.7, Python 3.10

Edit: I just checked, and it seems the script is only needed for the actual edit page? As the main script is also loaded on /cms/abtests/add/##/ it gives this error as no action menu is there.

helenb commented 4 months ago

I am seeing this same error. In addition, when I try to select the page for the test I get the following error:

vendor.js?v=747de67f:2 Uncaught TypeError: Cannot read properties of undefined (reading 'pageChooser')
    at onClick (wagtail-ab-testing.js?v=747de67f:2:391532)
    at Object.u (vendor.js?v=747de67f:2:682083)
    at p (vendor.js?v=747de67f:2:682226)
    at vendor.js?v=747de67f:2:682372
    at v (vendor.js?v=747de67f:2:682458)
    at ot (vendor.js?v=747de67f:2:697926)
    at rt (vendor.js?v=747de67f:2:697736)
    at it (vendor.js?v=747de67f:2:698092)
    at ft (vendor.js?v=747de67f:2:699299)
    at P (vendor.js?v=747de67f:2:796051)

I'm on wagtail 6.1.2

Screenshots of the error messages in the console:

Screenshot 2024-07-25 at 12 04 58

Screenshot 2024-07-25 at 12 05 05

mgax commented 3 months ago

In addition, when I try to select the page for the test I get the following error:

This is a separate issue, which should be fixed by https://github.com/wagtail-nest/wagtail-ab-testing/pull/85.