Skip to content

Conversation

@horiagunica
Copy link

SUMMARY

This issues Fixes #545 .

When specifying a VRF - there isn't any ipv4 or ipv6 argument from the AFI and if this is specified - the command errors out.

Within the PR I have added another condition that if the vrf argument is given a value - then it will omit the afi value from being placed into the command - that should fix the issue while still maintaing the default (non-vrf) behaviour.

As a side note - I think it might be safe taking this AFI out completely.

ISSUE TYPE
  • Bugfix Pull Request
COMPONENT NAME

module : cisco.iosxr.iosr_ping
file : argspec -> ping

ADDITIONAL INFORMATION

@roverflow roverflow marked this pull request as draft June 4, 2025 09:48
@horiagunica
Copy link
Author

@roverflow @Ruchip16 - would you kindly have some time to look at this PR ? Another option is to remove the afi completely - as the commands for IPv4 and IPv6 would work natively anyway (with and without a VRF).

@AAYUSH2091 AAYUSH2091 requested a review from Ruchip16 June 11, 2025 09:36
Copy link
Member

@Ruchip16 Ruchip16 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

hey @horiagunica thanks for raising the PR, i do not understand the need of adding afi here as commands for ip address works irrespectively of vrf right, we dont need the dependency in the very first place to be added to the module.

@horiagunica
Copy link
Author

horiagunica commented Jun 23, 2025

@Ruchip16 - try executing that task against any IOS XR device - it's going to throw an error each time. It's currently running ping vrf <input_vrf> <input_afi> <input_destination> - when using a VRF there is no AFI (ipv4/ipv6) within the command in the device OS level.

That's I thought of placing the condition there so if you DO specify the VRF instance - you omit the ipv4/ipv6 (default being ipv4) from the ping command.

@horiagunica
Copy link
Author

@Ruchip16 - can you please have a look at this and my previous reply ?

@horiagunica horiagunica requested a review from Ruchip16 July 17, 2025 19:46
@Ruchip16
Copy link
Member

@Ruchip16 - can you please have a look at this and my previous reply ?

thanks for the contribution, could you please add changelog and required integration tests to validate this behaviour?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

iosxr_ping creates bad syntax for ping request

2 participants