Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
Skins
  • Light
  • Brite
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (Flatly)
  • No Skin
Collapse
Brand Logo

NetXMS Forum

  1. Home
  2. Support
  3. Standard NetXML modules are not loading after 5.0.2 upgrade

Standard NetXML modules are not loading after 5.0.2 upgrade

Scheduled Pinned Locked Moved Support
6 Posts 4 Posters 20.6k Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • L
    L
    lroytman
    wrote on last edited by
    #1

    Hi,

    We've upgraded our NetXMS installation from 4.5.0 to 5.0.2. Then we had to replace all deprecated functions in our EPP scripts. Now EPP scripts are being compiled successfully.
    However, actual execution generates an error - Script (EPP::1) execution error: Script load failed
    When we try to Execute Script on a node, even simple
    String::right("Test", 2);
    gives the following error: 
    Cannot execute script: Script compilation error (Error 16 in line 1:Requested module not found or cannot be loaded)

    Any recommendations on how to fix the issue?

    Thank you,

    Leo

    1 Reply Last reply
    0
    • F
      F
      Filipp Sudanov
      wrote on last edited by
      #2

      String functions were deprecated, now string methods should be used:

      a = "abc";
      b = a.right(2);
      println(b);
      

      Documentation should be up to date: https://www.netxms.org/documentation/nxsl-latest/#class-string

      1 Reply Last reply
      0
      • L
        L
        lroytman
        wrote on last edited by
        #3

        Thank you, Filipp, for your quick reply. After another turn of script corrections they seem to be working now.
        It is unfortunate that documentation has not been updated. And compilation diagnostics has not been updated too. We wasted quite a few hours because of that. And, as compilation does not catch deprecated code, we cannot be sure we have not missed some places which can fail on execution.

        Regards,

        Leo

        1 Reply Last reply
        0
        • V
          V
          Victor Kirhenshtein
          wrote on last edited by
          #4

          Hi,

          is this:

          String::right("Test", 2);
          

          really in documentation somewhere? Or some text/example that suggests this is the correct way? Because it is incorrect and never was.
          Module::function syntax is supported since 4.x, and some functions were indeed moved to system packages in version 5, but there never been module "String".

          Best regards,
          Victor

          1 Reply Last reply
          0
          • L
            L
            lroytman
            wrote on last edited by
            #5

            Hi Victor,

            Please, see here: https://netxms.org/documentation/nxsl-latest/#func-right
            It says:  This function is deprecated starting from version 5.0. Please use String::right()

            Regards,

            Leo

            1 Reply Last reply
            0
            • A
              A
              Alex Kirhenshtein
              wrote on last edited by
              #6

              @lroytman said in Standard NetXML modules are not loading after 5.0.2 upgrade:

              Hi Victor,

              Please, see here: https://netxms.org/documentation/nxsl-latest/#func-right
              It says:  This function is deprecated starting from version 5.0. Please use String::right()

              Regards,

              Leo

              I've updated documentation to be more descriptive.

              1 Reply Last reply
              0

              Hello! It looks like you're interested in this conversation, but you don't have an account yet.

              Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.

              With your input, this post could be even better 💗

              Register Login
              Reply
              • Reply as topic
              Log in to reply
              • Oldest to Newest
              • Newest to Oldest
              • Most Votes


              • Login

              • Don't have an account? Register

              • Login or register to search.
              Powered by NodeBB Contributors
              • First post
                Last post
              0
              • Categories
              • Recent
              • Tags
              • Popular
              • Users
              • Groups