datacenter / ACI-Pre-Upgrade-Validation-Script

A script to run validations to detect potential issues that may cause an ACI fabric upgrade to fail
https://datacenter.github.io/ACI-Pre-Upgrade-Validation-Script/
Apache License 2.0
43 stars 27 forks source link

No test result printed for "Per-Leaf Fabric Uplink Limit Validation" #134

Closed takishida closed 3 months ago

takishida commented 5 months ago

(use upvote :thumbsup: for attentions) Describe the bug When the number of uplink ports are less than 57, the validation result should be PASS. However, it does not print anything.

Script output

[Check 44/64] APIC Container Bridge IP Overlap with APIC TEP...                                                                       PASS
[Check 45/64] Per-Leaf Fabric Uplink Limit Validation... [Check 46/64] OoB Mgmt Security...                                                                                   PASS
[Check 47/64] EECDH SSL Cipher...                                                                                                     PASS

In the above output, [Check 45/64] doesn't show the result PASS and the next check 46/64 is printed immediately after that.

To Reproduce

  1. The current version is older than 6.0 and the target version is newer than 6.0 (i.e. versions are susceptible)
  2. The number of uplinks is less than 57

Expected behavior It should show PASS as the result.

Additional context

print_result() is missing in this condition.

    if cversion.older_than("6.0(1a)") and tversion.newer_than("6.0(1a)"):
        port_profiles = icurl('class', 'eqptPortP.json?query-target-filter=eq(eqptPortP.ctrl,"uplink")')
        if not port_profiles or (len(port_profiles) < 57):
            return result