Skip to content

Commit 853ab88

Browse files
gmulocShivani-gslabClausHolbechArista
authored
Refactor(pyavd)!: Make sort_key mandatory in natural_sort when sorting list of dictionaries (aristanetworks#6273)
Co-authored-by: Shivani-gslab <[email protected]> Co-authored-by: Claus Holbech <[email protected]>
1 parent b93d964 commit 853ab88

File tree

71 files changed

+569
-418
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

71 files changed

+569
-418
lines changed

ansible_collections/arista/avd/examples/cv-pathfinder/documentation/fabric/WAN-documentation.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -68,10 +68,10 @@
6868
| l3leaf | site2-leaf2 | Ethernet3 | wan_router | site2-wan2 | Ethernet1 |
6969
| l3leaf | site2-leaf2 | Ethernet3.100 | wan_router | site2-wan2 | Ethernet1.100 |
7070
| l3leaf | site2-leaf2 | Ethernet3.101 | wan_router | site2-wan2 | Ethernet1.101 |
71-
| l2leaf | site3-leaf1 | Ethernet1 VLAN 42 | wan_router | site3-wan1 | Ethernet1.42 |
72-
| l2leaf | site3-leaf1 | Ethernet1 VLAN 666 | wan_router | site3-wan1 | Ethernet1.666 |
7371
| l2leaf | site3-leaf1 | Ethernet1 | wan_router | site3-wan1 | Ethernet1 |
7472
| l2leaf | site3-leaf1 | Ethernet1 | wan_router | site3-wan1 | Ethernet1 |
73+
| l2leaf | site3-leaf1 | Ethernet1 VLAN 42 | wan_router | site3-wan1 | Ethernet1.42 |
74+
| l2leaf | site3-leaf1 | Ethernet1 VLAN 666 | wan_router | site3-wan1 | Ethernet1.666 |
7575
| l3leaf | site4-border1 | Ethernet3 | wan_router | site4-wan1 | Ethernet1 |
7676
| l3leaf | site4-border1 | Ethernet5 | mlag_peer | site4-border2 | Ethernet5 |
7777
| l3leaf | site4-border1 | Ethernet6 | mlag_peer | site4-border2 | Ethernet6 |

ansible_collections/arista/avd/extensions/molecule/eos_cli_config_gen/documentation/devices/host1.md

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -885,9 +885,9 @@ management tech-support
885885
| FTP | default | Loopback0 |
886886
| FTP | MGMT | Management0 |
887887
| FTP | abc | Ethernet10 |
888+
| HTTP | default | Ethernet10 |
888889
| HTTP | default | Loopback0 |
889890
| HTTP | MGMT | Management0 |
890-
| HTTP | default | Ethernet10 |
891891
| SSH | default | Ethernet10 |
892892
| SSH | default | Loopback0 |
893893
| SSH | MGMT | Management0 |
@@ -905,9 +905,9 @@ management tech-support
905905
ip ftp client source-interface Loopback0
906906
ip ftp client source-interface Management0 vrf MGMT
907907
ip ftp client source-interface Ethernet10 vrf abc
908+
ip http client local-interface Ethernet10
908909
ip http client local-interface Loopback0 vrf default
909910
ip http client local-interface Management0 vrf MGMT
910-
ip http client local-interface Ethernet10
911911
ip ssh client source-interface Ethernet10
912912
ip ssh client source-interface Loopback0 vrf default
913913
ip ssh client source-interface Management0 vrf MGMT
@@ -1370,19 +1370,19 @@ tacacs-server host 10.10.10.160
13701370

13711371
| VRF | Source Interface Name |
13721372
| --- | --------------- |
1373-
| default | loopback1 |
1374-
| TEST1 | lo3 |
1375-
| default | loopback10 |
1373+
| default | Loopback1 |
1374+
| TEST1 | Loopback3 |
1375+
| default | Loopback10 |
13761376

13771377
#### IP TACACS Source Interfaces Device Configuration
13781378

13791379
```eos
13801380
!
1381-
ip tacacs vrf default source-interface loopback1
1381+
ip tacacs vrf default source-interface Loopback1
13821382
!
1383-
ip tacacs vrf TEST1 source-interface lo3
1383+
ip tacacs vrf TEST1 source-interface Loopback3
13841384
!
1385-
ip tacacs source-interface loopback10
1385+
ip tacacs source-interface Loopback10
13861386
```
13871387

13881388
### Radius Proxy
@@ -1582,19 +1582,19 @@ radius-server host 10.10.11.155 vrf mgt tls ssl-profile HOST_SSL_PROFILE port 20
15821582

15831583
| VRF | Source Interface Name |
15841584
| --- | --------------- |
1585-
| default | loopback1 |
1586-
| MGMT | Ma1 |
1587-
| default | loopback10 |
1585+
| default | Loopback1 |
1586+
| default | Loopback10 |
1587+
| MGMT | Management1 |
15881588

15891589
#### IP SOURCE Source Interfaces Device Configuration
15901590

15911591
```eos
15921592
!
1593-
ip radius vrf default source-interface loopback1
1593+
ip radius vrf default source-interface Loopback1
15941594
!
1595-
ip radius vrf MGMT source-interface Ma1
1595+
ip radius source-interface Loopback10
15961596
!
1597-
ip radius source-interface loopback10
1597+
ip radius vrf MGMT source-interface Management1
15981598
```
15991599

16001600
### AAA Server Groups

ansible_collections/arista/avd/extensions/molecule/eos_cli_config_gen/intended/configs/host1.cfg

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -5265,9 +5265,9 @@ ip nat synchronization
52655265
ip ftp client source-interface Loopback0
52665266
ip ftp client source-interface Management0 vrf MGMT
52675267
ip ftp client source-interface Ethernet10 vrf abc
5268+
ip http client local-interface Ethernet10
52685269
ip http client local-interface Loopback0 vrf default
52695270
ip http client local-interface Management0 vrf MGMT
5270-
ip http client local-interface Ethernet10
52715271
ip ssh client source-interface Ethernet10
52725272
ip ssh client source-interface Loopback0 vrf default
52735273
ip ssh client source-interface Management0 vrf MGMT
@@ -5472,11 +5472,11 @@ priority-flow-control pause watchdog default recovery-time 1.22
54725472
priority-flow-control pause watchdog default polling-interval 10.001
54735473
priority-flow-control pause watchdog action no-drop
54745474
!
5475-
ip radius vrf default source-interface loopback1
5475+
ip radius vrf default source-interface Loopback1
54765476
!
5477-
ip radius vrf MGMT source-interface Ma1
5477+
ip radius source-interface Loopback10
54785478
!
5479-
ip radius source-interface loopback10
5479+
ip radius vrf MGMT source-interface Management1
54805480
!
54815481
role network-limited
54825482
10 permit mode exec command ssh
@@ -7136,11 +7136,11 @@ stun
71367136
binding timeout 600 seconds
71377137
ssl connection lifetime 1300 minutes
71387138
!
7139-
ip tacacs vrf default source-interface loopback1
7139+
ip tacacs vrf default source-interface Loopback1
71407140
!
7141-
ip tacacs vrf TEST1 source-interface lo3
7141+
ip tacacs vrf TEST1 source-interface Loopback3
71427142
!
7143-
ip tacacs source-interface loopback10
7143+
ip tacacs source-interface Loopback10
71447144
!
71457145
traffic-policies
71467146
field-set l4-port SERVICE-DEMO

ansible_collections/arista/avd/extensions/molecule/eos_cli_config_gen/inventory/host_vars/host1/ip-radius-source-interface.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,8 @@
33

44
ip_radius_source_interfaces:
55
- vrf: default
6-
name: loopback1
6+
name: Loopback1
77
- vrf: MGMT
8-
name: Ma1
8+
name: Management1
99
- vrf:
10-
name: loopback10
10+
name: Loopback10

ansible_collections/arista/avd/extensions/molecule/eos_cli_config_gen/inventory/host_vars/host1/ip-tacacs-source-interface.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,8 @@
33

44
ip_tacacs_source_interfaces:
55
- vrf: default
6-
name: loopback1
6+
name: Loopback1
77
- vrf: TEST1
8-
name: lo3
8+
name: Loopback3
99
- vrf:
10-
name: loopback10
10+
name: Loopback10

ansible_collections/arista/avd/plugins/filter/natural_sort.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@
3838
- |-
3939
Provides the capability to sort a list or a dictionary of integers and strings that contain alphanumeric characters naturally.
4040
When leveraged on a dictionary, only the key value will be returned.
41-
An optional `sort_key` can be specified, to sort on content of certain key if the items are dictionaries.
41+
If the items are dictionaries, a `sort_key` must be specified, to sort on the content of the key.
4242
- The filter will return an empty list if the value parsed to `arista.avd.natural_sort` is `None` or `undefined`.
4343
positional: _input
4444
options:

ansible_collections/arista/avd/roles/eos_cli_config_gen/docs/tables/ethernet-interfaces.md

Lines changed: 6 additions & 6 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

ansible_collections/arista/avd/roles/eos_cli_config_gen/docs/tables/port-channel-interfaces.md

Lines changed: 6 additions & 6 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

ansible_collections/arista/avd/roles/eos_cli_config_gen/docs/tables/qos-profiles.md

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

ansible_collections/arista/avd/roles/eos_cli_config_gen/docs/tables/router-general.md

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)