Skip to content

Commit dd1597b

Browse files
authored
Merge pull request #562 from networktocode/develop
Prep v1.9.1 into Main
2 parents 0caf64e + 6b8f5f7 commit dd1597b

File tree

6 files changed

+23
-5
lines changed

6 files changed

+23
-5
lines changed

docs/admin/release_notes/version_1.9.md

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,17 @@
66
- Added DNA Center platform mappings.
77
- Improved error message when duplicate line is parsed.
88

9+
## [v1.9.1] 2024-08
10+
11+
### Changed
12+
13+
- [557](https://github.com/networktocode/netutils/pull/557) OUI File Updates.
14+
- [558](https://github.com/networktocode/netutils/pull/558) PROTOCOL File Updates.
15+
16+
### Fixed
17+
18+
- [553](https://github.com/networktocode/netutils/pull/553) Fixes incorrect cisco_xe to ntc-templates library mapping.
19+
920
## [v1.9.0] 2024-07
1021

1122
### Added

docs/user/lib_mapper/ntctemplates.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@
3333
| cisco_s300 || cisco_s300 |
3434
| cisco_tp || cisco_tp |
3535
| cisco_wlc || cisco_wlc |
36-
| cisco_xe || cisco_xe |
36+
| cisco_xe || cisco_ios |
3737
| cisco_xr || cisco_xr |
3838
| cloudgenix_ion || cloudgenix_ion |
3939
| coriant || coriant |

docs/user/lib_mapper/ntctemplates_reverse.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,6 @@
3333
| cisco_s300 || cisco_s300 |
3434
| cisco_tp || cisco_tp |
3535
| cisco_wlc || cisco_wlc |
36-
| cisco_xe || cisco_xe |
3736
| cisco_xr || cisco_xr |
3837
| cloudgenix_ion || cloudgenix_ion |
3938
| coriant || coriant |

netutils/lib_mapper.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -260,6 +260,7 @@
260260
# ntc templates is primarily based on netmiko, so a copy is in order
261261
_NTCTEMPLATES_LIB_MAPPER = copy.deepcopy(NETMIKO_LIB_MAPPER)
262262
_NTCTEMPLATES_LIB_MAPPER["aruba_aoscx"] = "aruba_aoscx"
263+
_NTCTEMPLATES_LIB_MAPPER["cisco_xe"] = "cisco_ios" # no reverse
263264
_NTCTEMPLATES_LIB_MAPPER["huawei_vrp"] = "huawei_vrp"
264265
_NTCTEMPLATES_LIB_MAPPER["vmware_nsxv"] = "vmware_nsxv"
265266
_NTCTEMPLATES_LIB_MAPPER["watchguard_firebox"] = "watchguard_firebox"
@@ -270,7 +271,9 @@
270271
}
271272
# Normalized | NTCTemplates
272273
NTCTEMPLATES_LIB_MAPPER_REVERSE: t.Dict[str, str] = {
273-
value: key for key, value in NTCTEMPLATES_LIB_MAPPER.items() if key not in ["f5_ltm", "f5_tmsh", "f5_linux"]
274+
value: key
275+
for key, value in NTCTEMPLATES_LIB_MAPPER.items()
276+
if key not in ["f5_ltm", "f5_tmsh", "f5_linux", "cisco_xe"]
274277
}
275278

276279

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[tool.poetry]
22
name = "netutils"
3-
version = "1.9.0"
3+
version = "1.9.1"
44
description = "Common helper functions useful in network automation."
55
authors = ["Network to Code, LLC <[email protected]>"]
66
license = "Apache-2.0"

tests/unit/test_lib_mapper.py

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,10 +48,15 @@ def test_lib_mapper_reverse(lib):
4848
_mapper = getattr(lib_mapper, f"{lib}_LIB_MAPPER").copy()
4949
if lib == "NAPALM":
5050
_mapper.pop("nxos_ssh")
51-
if lib in ["NETMIKO", "NTCTEMPLATES"]:
51+
if lib == "NETMIKO":
5252
_mapper.pop("f5_ltm")
5353
_mapper.pop("f5_tmsh")
5454
_mapper.pop("f5_linux")
55+
if lib == "NTCTEMPLATES":
56+
_mapper.pop("f5_ltm")
57+
_mapper.pop("f5_tmsh")
58+
_mapper.pop("f5_linux")
59+
_mapper.pop("cisco_xe")
5560
if lib in [
5661
"AERLEON",
5762
"ANSIBLE",

0 commit comments

Comments
 (0)