Uploaded image for project: 'Near Realtime RAN Intelligent Controller'
  1. Near Realtime RAN Intelligent Controller
  2. RIC-974

Errors running example ping/pong application in `xapp-frame-py`

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Done
    • Icon: Low Low
    • None
    • None
    • None
    • None

      If we try to run the example applications in `xapp-frame-py/examples/xapp_ping.py` through docker, we get the following error.

      $ docker run xapp-python-pong
      Traceback (most recent call last):
        File "pong_xapp.py", line 21, in <module>
          from ricxappframe.xapp_frame import RMRXapp, rmr
        File "/usr/local/lib/python3.8/site-packages/ricxappframe/xapp_frame.py", line 32, in <module>
          from ricxappframe import xapp_rmr
        File "/usr/local/lib/python3.8/site-packages/ricxappframe/xapp_rmr.py", line 27, in <module>
          from ricxappframe.rmr import rmr, helpers
        File "/usr/local/lib/python3.8/site-packages/ricxappframe/rmr/rmr.py", line 25, in <module>
          from ricxappframe.rmr.rmrclib.rmrclib import rmr_c_lib, get_constants, state_to_status
        File "/usr/local/lib/python3.8/site-packages/ricxappframe/rmr/rmrclib/rmrclib.py", line 33, in <module>
          _rmr_free_consts = rmr_c_lib.rmr_free_consts
        File "/usr/local/lib/python3.8/ctypes/__init__.py", line 386, in __getattr__
          func = self.__getitem__(name)
        File "/usr/local/lib/python3.8/ctypes/__init__.py", line 391, in __getitem__
          func = self._FuncPtr((name_or_ordinal, self))
      AttributeError: Symbol not found: rmr_free_consts
      

      This is because the symbol rmr_free_consts is not available in the release 4.0.5 that is used to build the image.

      Only available images are -

      $ curl -X GET  https://nexus3.o-ran-sc.org:10002/v2/o-ran-sc/bldr-alpine3-rmr/tags/list | jq
        % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                       Dload  Upload   Total   Spent    Left  Speed
      100   109  100   109    0     0     78      0  0:00:01  0:00:01 --:--:--    78
      {
        "name": "o-ran-sc/bldr-alpine3-rmr",
        "tags": [
          "3.8.0",
          "3.8.2",
          "4.0.0",
          "4.0.2",
          "4.0.5",
          "4.1.2",
          "4.4.6",
          "4.5.2"
        ]
      }
      

      Consequently, it's not possible to build the docker image with the latest master, that would work.

      Related, There is a typo in the xapp-frame-py/examples/pong_xapp.py

      jpay = json.loads(summary[rmr.RMR_MS_MSG_PAYLOAD])
      

      This should be -

      jpay = json.loads(summary[rmr.RMR_MS_PAYLOAD])
      

      With the above fix it's still possible to run the `ping/pong applications outside docker, by using the latest rmr sources.

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

            gabhijit Abhijit Gadgil
            gabhijit Abhijit Gadgil
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: