Skip to content

Fix GNMI-1.18 for Arista#5205

Open
prakashbadri-arista wants to merge 1 commit intoopenconfig:mainfrom
prakashbadri-arista:gnmi-1.18_fail
Open

Fix GNMI-1.18 for Arista#5205
prakashbadri-arista wants to merge 1 commit intoopenconfig:mainfrom
prakashbadri-arista:gnmi-1.18_fail

Conversation

@prakashbadri-arista
Copy link
Copy Markdown
Contributor

The fix updates the regex for identifying IC components in Arista devices so that the enttries for per fap components such as "SwitchChip2/0.1", "SwitchChip3/1.4" are skipped.

The fix updates the regex for identifying IC components in Arista
devices so that the enttries for per fap components such as
"SwitchChip2/0.1", "SwitchChip3/1.4" are skipped.
@prakashbadri-arista prakashbadri-arista requested a review from a team as a code owner March 9, 2026 02:03
@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 refines the logic for identifying Integrated Circuit (IC) components on Arista network devices within the testing framework. The change ensures that the system accurately distinguishes between main switch chips and granular per-FAP components, which was causing issues with the previous, less specific matching pattern. This improves the reliability of component identification and subsequent test results.

Highlights

  • Arista IC Component Identification: Updated the regular expression used to identify IC (Integrated Circuit) components on Arista devices. The previous regex was too broad, leading to incorrect identification of per-FAP components.
  • Regex Refinement: The new regex ^SwitchChip\d+(?:/\d+)?$ specifically targets SwitchChip followed by digits, optionally followed by a slash and more digits, ensuring that entries like SwitchChip2/0.1 are correctly skipped.
Changelog
  • feature/platform/fabric/otg_tests/sampled_backplane_capacity_counters_test/sampled_backplane_capacity_counters_test.go
    • Updated the regular expression for Arista devices in the icPattern map to correctly identify SwitchChip components and exclude per-FAP entries.
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 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 counter productive. 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.

You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension.

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.

Copy link
Copy Markdown
Contributor

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

Choose a reason for hiding this comment

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

Code Review

The pull request updates the regular expression for ondatra.ARISTA in the icPattern map within sampled_backplane_capacity_counters_test.go. The regex was changed from ^SwitchChip to ^SwitchChip\d+(?:/\d+)?$ to more accurately match Arista switch chip names, allowing for digits and an optional /digits suffix, and ensuring the match covers the entire string.

@gggsmith gggsmith requested review from a team, nikki-blr and ram-mac March 9, 2026 10:22
Copy link
Copy Markdown

@jmunusa jmunusa left a comment

Choose a reason for hiding this comment

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

LGTM

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.

5 participants