Skip to content

Commit

Permalink
Fixing list-string bug
Browse files Browse the repository at this point in the history
  • Loading branch information
ktbyers committed Aug 4, 2019
1 parent 5bf1e08 commit 5c6570e
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 13 deletions.
13 changes: 3 additions & 10 deletions napalm/eos/eos.py
Original file line number Diff line number Diff line change
Expand Up @@ -1704,16 +1704,11 @@ def get_config(self, retrieve="all", full=False):
run_full = " all" if full else ""

if retrieve == "all":
commands = [
"show startup-config"
"show running-config{}".format(run_full),
]
commands = ["show startup-config", "show running-config{}".format(run_full)]

if self.config_session:
commands.append(
"show session-config named {}".format(
self.config_session
)
"show session-config named {}".format(self.config_session)
)

output = self.device.run_commands(commands, encoding="text")
Expand Down Expand Up @@ -1744,9 +1739,7 @@ def get_config(self, retrieve="all", full=False):
"candidate": "",
}
elif get_candidate:
commands = [
"show session-config named {}".format(self.config_session)
]
commands = ["show session-config named {}".format(self.config_session)]
output = self.device.run_commands(commands, encoding="text")
return {
"startup": "",
Expand Down
4 changes: 1 addition & 3 deletions napalm/iosxr/iosxr.py
Original file line number Diff line number Diff line change
Expand Up @@ -2238,9 +2238,7 @@ def get_config(self, retrieve="all", full=False):
)
if retrieve.lower() in ["candidate", "all"]:
config["candidate"] = py23_compat.text_type(
self.device._execute_config_show(
"show configuration merge"
)
self.device._execute_config_show("show configuration merge")
)

return config

0 comments on commit 5c6570e

Please sign in to comment.