Uploaded image for project: 'RHEL'
  1. RHEL
  2. RHEL-1670

NmstateError for invalid prefix-length seems not accurate

    • nmstate-2.2.18-1.el9
    • None
    • None
    • 1
    • rhel-sst-network-management
    • ssg_networking
    • 11
    • 1
    • False
    • Hide

      None

      Show
      None
    • No
    • NMT - RHEL 8.10/9.4 DTM 08
    • Hide

      Given a system administrator configures a network interface using nmstate,

      When they attempt to apply a nmstate policy with an invalid IPv4 prefix-length (e.g., 33),

      Then nmstate should provide a clear and accurate error message indicating the invalidity of the prefix-length value, rather than a generic or unrelated message.

      Definition of Done

      • The implementation meets the acceptance criteria
      • The unit tests and integration tests are written and passed
      • The code is part of a build attached to an errata
      Show
      Given a system administrator configures a network interface using nmstate, When they attempt to apply a nmstate policy with an invalid IPv4 prefix-length (e.g., 33), Then nmstate should provide a clear and accurate error message indicating the invalidity of the prefix-length value, rather than a generic or unrelated message. Definition of Done The implementation meets the acceptance criteria The unit tests and integration tests are written and passed The code is part of a build attached to an errata
    • Pass
    • Automated
    • If docs needed, set a value
    • None

      Description of problem:
      nmstate error message for invalid prefix-length seems not accurate

      Version-Release number of selected component (if applicable):
      Red Hat Enterprise Linux release 9.2
      nmstate-2.2.13-1.el9_2.x86_64

      How reproducible:
      always

      Steps to Reproduce:
      1. apply nmstate policy with invalid ipv4 prefix-length 33
      desiredState:
      interfaces:

      • ipv4:
        address:
      • ip: 5.5.5.6
        prefix-length: 33
        enabled: true
        name: br123
        state: up
        type: linux-bridge

      Actual results:
      apply failed with below error:
      NmstateError: InvalidArgument: Connection(MissingProperty):ipv4.addresses: this property cannot be empty for 'method=manual'

      Expected results:
      apply failed with accurate error message about invalid prefix-length

      Additional info:

              fge@redhat.com Gris Ge
              rh-ee-qiowang Qiong Wang
              Network Management Team Network Management Team
              Mingyu Shi Mingyu Shi
              Votes:
              0 Vote for this issue
              Watchers:
              11 Start watching this issue

                Created:
                Updated:
                Resolved: