There are several config_mode scripts (11) (6) that break compatibility with the script structure and behaviour as outlined in:
The non-standard use of vyos.config Config in those scripts can likely be avoided by the move to get_config_dict as in the example here [SSH: migrate to get_config_dict()]:
https://phabricator.vyos.net/T2635
There are compelling reasons to follow the guidelines outlined above:
- Ability to mock Config() with test data and run scripts in batch for test based development
- Ability to run all scripts from a config daemon
- Easy transition to vyconf
Some of the non-conformant scripts are easily adjusted without changing logic or readability; others rely on the use of Config() in 'verify' in a manner that should be considered as a candidate for a get_config_dict rewrite.
This task will serve as a metatask for investigation; the list of non-conforming scripts is below:
arp.py
dns_forwarding.py
flow_accounting_conf.py
host_name.py
interfaces-bonding.py
interfaces-bridge.py
interfaces-tunnel.py
interfaces-wireless.py
protocols_bfd.py
snmp.py
system-proxy.py