save_config() got an unexpected keyword argument 'confirm_response'
See original GitHub issueHi,
I am running this code against a test device, where it logs into the device and attempts to save the configuration
from nornir import InitNornir
from nornir.plugins.tasks.networking import netmiko_save_config
from nornir.plugins.functions.text import print_result
def save_config(task):
task.run(task=netmiko_save_config,
name='Saving configuration',
cmd='copy running-config startup-config')
result = target_hosts.run(save_config)
print_result(result, vars=["stdout"])
However Nornir throws an exception and I get below message “save_config() got an unexpected keyword argument ‘confirm_response’”.
What’s more strange is, despite the exception, device configuration is saved to startup-config file.
Issue Analytics
- State:
- Created 5 years ago
- Reactions:2
- Comments:8 (2 by maintainers)
Top Results From Across the Web
getting errors while running tests in test_netmiko_config.py in ...
E TypeError: save_config() got an unexpected keyword argument 'confirm_response'. test_netmiko_config.py:135: TypeError.
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
That is probably a bug in Netmiko. It should probably be fixed in Netmiko (i.e. all Netmiko drivers should accept the same set of arguments for that method).
This is fixed in the Netmiko
develop
branch. I am going to go ahead and close this.