Uploaded image for project: 'ZK'
  1. ZK
  2. ZK-4696

An unchanged ClientInfo makes the infinite processing loop

XMLWordPrintable

    • None

      Steps to Reproduce

      <zk>
          <zscript><![CDATA[
          void doTheThing(){
              Include include = new Include("./includedWindow.zul");
              include.setMode("defer");
              g1.firstChild.appendChild(include);
          }
          ]]>
          </zscript>
          <label multiline="true">
              1. Click the button to create an include.
              2. You should see "onClientInfonull" in zk log.
              3. Press the button again.
              4. You should see "onClientInfonull" in zk log.
          </label>
          <button label="Create an include" onClick='doTheThing()' />
          <panel title="foo" id="g1">
              <panelchildren />
          </panel>
      </zk>
      
      includedWindow.zul
      <zk>
          <window onClientInfo="Clients.log(event.getName() + event.getData())"/>
      </zk>
      

      Current Result

      It freezes after clicking the button the second time.

      Expected Result

      It prints "onClientInfonull"

      Debug Information

      A ZK-3181 side effect.

      Since it won't trigger an event with a rTags (onClientInfo)
      https://github.com/zkoss/zk/blob/v8.6.0/zk/src/archive/web/js/zk/au.js#L1312

      The processing will never end.
      https://github.com/zkoss/zk/blob/v8.6.0/zk/src/archive/web/js/zk/au.js#L232

      Workaround

       

            rudyhuang rudyhuang
            rudyhuang rudyhuang
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved:

                Estimated:
                Original Estimate - 4 hours
                4h
                Remaining:
                Time Spent - 2 hours Remaining Estimate - 2 hours
                2h
                Logged:
                Time Spent - 2 hours Remaining Estimate - 2 hours
                2h