Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
Clear All
new posts

    js errors with latest 13.1

    SNAPSHOT_v13.1d_2023-10-05/Enterprise Deployment

    Chrome on MacOS

    Hello, while loading one on my applications with the latest 13.1, I've got two js errors:

    Code:
    Uncaught TypeError: Cannot read properties of undefined (reading 'changeDefaults')
        at isc.loadSkin (load_skin.js?isc_version=SNAPSHOT_v13.1d_2023-10-05.js:1:33164)
        at load_skin.js?isc_version=SNAPSHOT_v13.1d_2023-10-05.js:1:40573
    EventWindow doesn't seem defined

    and

    Code:
    Uncaught TypeError: Cannot read properties of undefined (reading 'min')
        at cons.checkDateRangeValidator (ISC_Forms.js?isc_version=SNAPSHOT_v13.1d_2023-10-05.js:41720:103)
        at cons.init (ISC_Forms.js?isc_version=SNAPSHOT_v13.1d_2023-10-05.js:66330:14)
        at cons.completeCreation (ISC_Core.js?isc_version=SNAPSHOT_v13.1d_2023-10-05.js:8896:14)
        at cons.createItem (ISC_Forms.js?isc_version=SNAPSHOT_v13.1d_2023-10-05.js:11473:14)
        at cons._addItems (ISC_Forms.js?isc_version=SNAPSHOT_v13.1d_2023-10-05.js:11244:45)
        at cons._setItems (ISC_Forms.js?isc_version=SNAPSHOT_v13.1d_2023-10-05.js:11015:10)
        at cons.initWidget (ISC_Forms.js?isc_version=SNAPSHOT_v13.1d_2023-10-05.js:10778:10)
        at cons.invokeSuper (ISC_Core.js?isc_version=SNAPSHOT_v13.1d_2023-10-05.js:7348:44)
        at cons.Super (ISC_Core.js?isc_version=SNAPSHOT_v13.1d_2023-10-05.js:7165:21)
        at cons.initWidget (everyRole.js?isc_version=1696516270000.js:79017:14)
        at cons.init (ISC_Core.js?isc_version=SNAPSHOT_v13.1d_2023-10-05.js:79608:10)
        at cons.completeCreation (ISC_Core.js?isc_version=SNAPSHOT_v13.1d_2023-10-05.js:8896:14)
        at cons.create (ISC_Core.js?isc_version=SNAPSHOT_v13.1d_2023-10-05.js:5850:39)
    here I'm not sure if there's just need of some null check

    #2
    EventWindow indeed does not exist in 13.1 - it was deprecated long ago and removed in 13.1.

    It sounds like you have quite an old custom skin - in which case, compare the load_skin to the latest version of the skin you based it from. Most likely, you just need to remove the entire block that affects isc.EventWindow.
    Last edited by Isomorphic; 5 Oct 2023, 21:02.

    Comment


      #3
      thanks for the heads up on the custom skin, I had a stale version of it in my local project.

      But I still have the second error:

      Code:
      Uncaught TypeError: Cannot read properties of undefined (reading 'min') at cons.checkDateRangeValidator (ISC_Forms.js?isc_version=SNAPSHOT_v13.1d_2023-10-05.js:41720:103) at cons.init (ISC_Forms.js?isc_version=SNAPSHOT_v13.1d_2023-10-05.js:66330:14) at cons.completeCreation (ISC_Core.js?isc_version=SNAPSHOT_v13.1d_2023-10-05.js:8896:14) at cons.createItem (ISC_Forms.js?isc_version=SNAPSHOT_v13.1d_2023-10-05.js:11473:14) at cons._addItems (ISC_Forms.js?isc_version=SNAPSHOT_v13.1d_2023-10-05.js:11244:45) at cons._setItems (ISC_Forms.js?isc_version=SNAPSHOT_v13.1d_2023-10-05.js:11015:10) at cons.initWidget (ISC_Forms.js?isc_version=SNAPSHOT_v13.1d_2023-10-05.js:10778:10) at cons.invokeSuper (ISC_Core.js?isc_version=SNAPSHOT_v13.1d_2023-10-05.js:7348:44) at cons.Super (ISC_Core.js?isc_version=SNAPSHOT_v13.1d_2023-10-05.js:7165:21) at cons.initWidget (everyRole.js?isc_version=1696516270000.js:79017:14) at cons.init (ISC_Core.js?isc_version=SNAPSHOT_v13.1d_2023-10-05.js:79608:10) at cons.completeCreation (ISC_Core.js?isc_version=SNAPSHOT_v13.1d_2023-10-05.js:8896:14) at cons.create (ISC_Core.js?isc_version=SNAPSHOT_v13.1d_2023-10-05.js:5850:39)
      which seems related to _autoGeneratedValidator which was not there in 13.0.

      Comment


        #4
        Thanks Claudio - we've added a missing null check that fixes this. You can try it out in today's builds, dated October 6 and later.

        Comment


          #5
          Version SNAPSHOT_v13.1d_2023-10-06/Enterprise Deployment (2023-10-06)
          Chrome on MacOS

          Hello, I can confirm that error is fixed, but I've got a new one:

          Code:
          ISC_Core.js?isc_version=SNAPSHOT_v13.1d_2023-10-06.js:31995 *18:08:16.364:WARN:Log:TypeError: item.getTrimmedDataPath is not a function
          Stack from error.stack:
              cons.getValue(<no args: exited>) on [DynamicForm ID:gestContrattiTecniciStoricoForm] @ ISC_Forms.js:13499:31
          The same application is working with the latest 13.0

          I don't understand what's going on, for some FormItems the getTrimmedDataPath function is defined, for others it's not. But I can't find a common pattern.
          Any hints?

          Comment


            #6
            In the end, the error was caused by code written in a "condition" in a custom validator and in an "expression" of a requiredIf validator.
            Instead of using record[fieldName], there was item.form.getValue(fieldName).
            After correcting it, I no longer encountered any errors.
            I don't know if this could be a sign of some issue in the framework.
            Last edited by claudiobosticco; 6 Oct 2023, 12:34.

            Comment

            Working...
            X