Skip to content

gNMI-1.28: fix Arista telemetry interfaces test failures - #5729

Open
pjacakArista wants to merge 2 commits into
openconfig:mainfrom
pjacakArista:arista-gNMI-1.28-fix-port-name-add-deviations
Open

gNMI-1.28: fix Arista telemetry interfaces test failures#5729
pjacakArista wants to merge 2 commits into
openconfig:mainfrom
pjacakArista:arista-gNMI-1.28-fix-port-name-add-deviations

Conversation

@pjacakArista

Copy link
Copy Markdown
Contributor

The gNMI-1.28 telemetry_interfaces_test fails on Arista EOS for several independent reasons: the test lowercases the Ondatra port name before using it in OpenConfig interface configuration, default description state is not present unless explicitly configured, the state/rate paths are handled through the test's existing state_path_unsupported deviation, routed subinterface 0 requires IPv4 to be explicitly enabled, and aggregation cannot be configured directly on the physical test port.

gNMI-1.28, port names: use the port name exactly as returned by Ondatra instead of lowercasing it. EOS treats the lowercased name as a different interface, which causes the interface type Set to apply to the wrong interface object and fail validation.

gNMI-1.28, default description state: add Arista to the existing missing_value_for_defaults deviation. This lets the state validation skip the default description leaf when the platform does not report a default value for it.

gNMI-1.28, state/rate and aggregation paths: add Arista to the existing state_path_unsupported deviation. This uses the same test mechanism already used for platforms that do not support the tested state/rate paths or physical-port aggregation configuration. The expected handling of /interfaces/interface/state/in-rate and out-rate is still being clarified; the test README lists those paths, but they are not present in the current openconfig-interfaces model or in the test's canonical OC example.

gNMI-1.28, aggregation skip text: make the aggregation skip message platform-generic instead of Nokia-specific because the skip is now driven by the platform deviation rather than a single vendor.

gNMI-1.28, routed subinterface 0: when the existing RequireRoutedSubinterface0 deviation is set, include IPv4 enabled state in the subinterface config pushed by the test. EOS requires that explicit configuration before the subinterface state validation can succeed.

With these changes, gNMI-1.28 passes on Arista EOS.

@pjacakArista
pjacakArista requested a review from a team as a code owner July 22, 2026 09:08
@gemini-code-assist

Copy link
Copy Markdown
Contributor

Summary of Changes

Hello, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed!

This pull request addresses several test failures in the gNMI-1.28 telemetry_interfaces_test when running on Arista EOS. The changes introduce necessary platform deviations, correct interface naming conventions, and adjust subinterface configuration requirements to align with Arista's operational model, ensuring the test suite passes successfully.

Highlights

  • Platform Deviations: Added Arista to platform exceptions in metadata, enabling missing_value_for_defaults and state_path_unsupported deviations to handle Arista-specific telemetry behavior.
  • Interface Naming: Updated the test to use the exact port name provided by Ondatra instead of forcing it to lowercase, ensuring compatibility with Arista EOS interface objects.
  • Subinterface Configuration: Implemented explicit IPv4 enablement for routed subinterface 0 when the RequireRoutedSubinterface0 deviation is active.
  • Test Cleanup: Generalized skip messages for aggregation and state/rate paths to be platform-agnostic, removing vendor-specific references.
Using Gemini Code Assist

The full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips.

Invoking Gemini

You can request assistance from Gemini at any point by creating a comment using either /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands on the current page.

Feature Command Description
Code Review /gemini review Performs a code review for the current pull request in its current state.
Pull Request Summary /gemini summary Provides a summary of the current pull request in its current state.
Comment @gemini-code-assist Responds in comments when explicitly tagged, both in pull request comments and review comments.
Help /gemini help Displays a list of available commands.

Customization

To customize the Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a .gemini/ folder in the base of the repository. Detailed instructions can be found here.

Limitations & Feedback

Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counterproductive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for GitHub and other Google products, sign up here.

Footnotes

  1. Review the Privacy Notices, Generative AI Prohibited Use Policy, Terms of Service, and learn how to configure Gemini Code Assist in GitHub here. Gemini can make mistakes, so double check it and use code with caution.

@OpenConfigBot

OpenConfigBot commented Jul 22, 2026

Copy link
Copy Markdown

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Code Review

This pull request updates the telemetry interfaces test by generalizing platform skip messages, removing redundant comments, and avoiding lowercase conversion on port names. It also introduces a check for the RequireRoutedSubinterface0 deviation to conditionally enable IPv4 on subinterfaces. Feedback on this PR highlights that the newly used require_routed_subinterface_0 deviation must be added to the Arista platform exceptions in metadata.textproto to prevent test failures on Arista EOS.

Comment thread feature/gnmi/tests/telemetry_interfaces_test/metadata.textproto
func TestTelemetryInterfaces(t *testing.T) {
dut := ondatra.DUT(t, "dut")
port1 := strings.ToLower(dut.Port(t, "port1").Name())
port1 := dut.Port(t, "port1").Name()

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Do we know why this was using tolower before? How do we know that this fix does not break other vendors?

@pjacakArista pjacakArista Jul 31, 2026

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Hmm ... you might be right on this, but my thinking was that:
There are 311 ( as far as I could find ) places where dut.Port(...).Name() is used, from those there are only 2 places where strings.ToLower is used ( telemetry_interfaces_test.go and telemetry_high_availability_test.go )

If we should add deviation (to use strings.ToLower ), we probably should add it only in those 2 places for platforms that require it.

There are no tests run result for this PR. Is there any way to see those on 'main'?

I've looked at PR that added this test (#5313 ) and it failed on all virtual devices ( and was never run on physical ones )

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

@singhavnish2516 what do you think of it?

@pjacakArista
pjacakArista force-pushed the arista-gNMI-1.28-fix-port-name-add-deviations branch 4 times, most recently from a30a20b to 113962c Compare July 31, 2026 07:44
@singhavnish2516 singhavnish2516 removed their assignment Jul 31, 2026
@pjacakArista
pjacakArista force-pushed the arista-gNMI-1.28-fix-port-name-add-deviations branch 2 times, most recently from 59cb660 to d903a79 Compare August 6, 2026 09:37
@pjacakArista
pjacakArista force-pushed the arista-gNMI-1.28-fix-port-name-add-deviations branch 3 times, most recently from 6b415b1 to b80f376 Compare August 13, 2026 08:25
@pjacakArista

Copy link
Copy Markdown
Contributor Author

@singhavnish2516 could you take a look at this PR?

@pjacakArista
pjacakArista force-pushed the arista-gNMI-1.28-fix-port-name-add-deviations branch from 472639a to 977806e Compare August 25, 2026 11:33
@pjacakArista
pjacakArista force-pushed the arista-gNMI-1.28-fix-port-name-add-deviations branch 3 times, most recently from 2c30c04 to 0f64ad7 Compare September 4, 2026 06:34
The gNMI-1.28 telemetry_interfaces_test fails on Arista EOS for several
independent reasons: the test lowercases the Ondatra port name before
using it in OpenConfig interface configuration, default description state
is not present unless explicitly configured, the state/rate paths are
handled through the test's existing state_path_unsupported deviation,
routed subinterface 0 requires IPv4 to be explicitly enabled, and
aggregation cannot be configured directly on the physical test port.

gNMI-1.28, port names: use the port name exactly as returned by Ondatra
instead of lowercasing it. EOS treats the lowercased name as a different
interface, which causes the interface type Set to apply to the wrong
interface object and fail validation.

gNMI-1.28, default description state: add Arista to the existing
missing_value_for_defaults deviation. This lets the state validation skip
the default description leaf when the platform does not report a default
value for it.

gNMI-1.28, state/rate and aggregation paths: add Arista to the existing
state_path_unsupported deviation. This uses the same test mechanism
already used for platforms that do not support the tested state/rate paths
or physical-port aggregation configuration. The expected handling of
/interfaces/interface/state/in-rate and out-rate is still being clarified;
the test README lists those paths, but they are not present in the current
openconfig-interfaces model or in the test's canonical OC example.

gNMI-1.28, aggregation skip text: make the aggregation skip message
platform-generic instead of Nokia-specific because the skip is now driven
by the platform deviation rather than a single vendor.

gNMI-1.28, routed subinterface 0: when the existing
RequireRoutedSubinterface0 deviation is set, include IPv4 enabled state in
the subinterface config pushed by the test. EOS requires that explicit
configuration before the subinterface state validation can succeed.

With these changes, gNMI-1.28 passes on Arista EOS.
@pjacakArista
pjacakArista force-pushed the arista-gNMI-1.28-fix-port-name-add-deviations branch from 0f64ad7 to d600574 Compare September 7, 2026 11:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants