TriggerFragment/FormFragment not working properly in 5.4.5

Ilya Obshadko <[email protected]> Fri, 3 Jan 2020 22:04:19 +0800
Newsgroups gmane.comp.java.tapestry.user
Message-ID <CAAT_KPK+ymYXKdLtd_1i6oH+z3XptkKrqEmD7h6XceoCrGBAXg@mail.gmail.com>
--000000000000d5b481059b3cc90a
Content-Type: text/plain; charset="UTF-8"

Disclaimer: I'm doing a 'long overdue' upgrade from 5.4-beta6, so I might
be missing something obvious.

Symptoms:

   - I'm using a checkbox with *TriggerFragment* mixin and *FormFragment*
   component
   - I'm getting a JavaScript error in Chrome console: RequireJS error:
   require: Invalid configuration, fragment with id policyFragment_0 not
   found
   - Setting a breakpoint on clientId field value change in *FormFragment*
   shows the following:
      - initially clientId value is correct and it's indeed
      *policyFragment_0* (top if the stack is *conduit_get_clientId*)
      - then it's reset to *null* (top of the stack is
      *conduit_set_clientId*)
      - then it's set to *policyFragment* (without trailing *_0*),
      apparently because *TriggerFragment* mixin is calling
      *FormFragment.getClientId()* again; the field is already null at this
      point, so it's just re-initialized with an incorrect value

Apparently the culprit here is the *clientId* field re-initialization; any
ideas what might be causing this? The setup itself seems to be fairly
obvious.

-- 
Ilya Obshadko

--000000000000d5b481059b3cc90a--