Bug 2333826

Summary: Latest os-net-config breaks "--exit-on-validation-errors" behavior
Product: Red Hat OpenStack Reporter: Alex Stupnikov <astupnik>
Component: os-net-configAssignee: RHOSP:NFV_Eng <rhosp-nfv-int>
Status: CLOSED MIGRATED QA Contact: Nate Johnston <njohnston>
Severity: high Docs Contact:
Priority: unspecified    
Version: 17.1 (Wallaby)CC: bfournie, jelle.hoylaerts.ext, jslagle, ktordeur, mburns, njohnston
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2025-01-10 12:44:13 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Alex Stupnikov 2024-12-23 10:40:11 UTC
Description of problem:
Customer has spoofcheck option defined for VLAN interface according to https://docs.redhat.com/en/documentation/red_hat_openstack_platform/17.1/html-single/configuring_network_functions_virtualization/index#config-nic-partition_dplsriov-nfv . This configuration stopped working in RHOSP 17.1.4

OSP17.1.3 was using os-net-config-14.2.1-17.1.20230729001034.el9ost.noarch which gives only a warning message when schema is violated
OSP17.1.4 is using os-net-config-14.2.1-17.1.20240917143753.el8ost.noarch which gives an error message for the same thing and fails execution

This looks like a regression introduced via 6a03b735d4e11974082181feda61c78aba23ac27:

diff --git a/os_net_config/cli.py b/os_net_config/cli.py
index 1b40580..7b78c01 100644
--- a/os_net_config/cli.py
+++ b/os_net_config/cli.py
@@ -73,7 +73,7 @@
         action='store_true',
         help="Exit with an error if configuration file validation fails. "
              "Without this option, just log a warning and continue.",
-        default=False)
+        default=True)
 
     parser.add_argument(
         '-d', '--debug',

This change looks incorrect to me because "exit-on-validation-errors" action is to "store_true". If it is true by default, then this argument becomes pointless. IMO we shouldn't change default behavior in minor upgrades as well.


Version-Release number of selected component (if applicable): RHOSP 17.1.4


How reproducible: configure VLAN interface with disabled spoofchecks according to https://docs.redhat.com/en/documentation/red_hat_openstack_platform/17.1/html-single/configuring_network_functions_virtualization/index#config-nic-partition_dplsriov-nfv


Actual results: deployment fails


Expected results: warning should be printed as before