Skip to content

test: improve waypoint e2e diagnostics#1685

Open
rishi-jat wants to merge 1 commit into
kmesh-net:mainfrom
rishi-jat:improve/waypoint-e2e-diagnostics
Open

test: improve waypoint e2e diagnostics#1685
rishi-jat wants to merge 1 commit into
kmesh-net:mainfrom
rishi-jat:improve/waypoint-e2e-diagnostics

Conversation

@rishi-jat
Copy link
Copy Markdown
Contributor

What type of PR is this?

/kind enhancement

What this PR does / why we need it:

Improves waypoint E2E failure diagnostics by surfacing gateway conditions,
pod readiness state, and recent waypoint logs when waypoint creation or
deletion fails.

This makes waypoint-related E2E failures significantly easier to debug in CI
and local test environments.

Which issue(s) this PR fixes:
Fixes #

Special notes for your reviewer:

  • No behavioral changes to waypoint lifecycle logic.
  • Diagnostics are only collected on failure paths.
  • Changes are isolated to test/e2e/main_test.go.

Copilot AI review requested due to automatic review settings May 8, 2026 04:59
@kmesh-bot kmesh-bot added the kind/enhancement New feature or request label May 8, 2026
@kmesh-bot kmesh-bot requested review from YaoZengzeng and lec-bit May 8, 2026 04:59
@kmesh-bot
Copy link
Copy Markdown
Collaborator

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by:
Once this PR has been reviewed and has the lgtm label, please assign lec-bit for approval. For more information see the Kubernetes Code Review Process.

The full list of commands accepted by this bot can be found here.

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@gemini-code-assist
Copy link
Copy Markdown

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 improves the observability of waypoint-related end-to-end test failures. By integrating a diagnostic collection mechanism into the test framework, the system now provides detailed state information and logs when waypoint operations fail, significantly reducing the time required to diagnose issues in automated testing pipelines.

Highlights

  • Enhanced E2E Diagnostics: Implemented a new diagnostic collection utility to capture gateway conditions, pod readiness states, and recent logs upon waypoint lifecycle failures.
  • Improved Failure Reporting: Updated waypoint creation and deletion failure paths to automatically surface diagnostic information, facilitating faster debugging in CI and local environments.
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.


When tests go dark and waypoints fail, We need a light to blaze the trail. With logs and status now in sight, We debug fast and sleep at night.

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.

@rishi-jat
Copy link
Copy Markdown
Contributor Author

/cc @hzxuzhonghu
/cc @yashisrani
/cc @LiZhenCheng9527

Copy link
Copy Markdown

@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

This pull request enhances E2E tests by adding a diagnostic collection utility for waypoint proxies, which gathers Gateway status, pod conditions, and logs upon failure. The review feedback correctly identifies that t.Fatal was used with format specifiers, which are not supported; it should be replaced with t.Fatalf to ensure the error messages and diagnostics are properly formatted in the test output.

I am having trouble creating individual review comments. Click here to see my feedback.

test/e2e/main_test.go (271)

high

The Fatal method does not support format specifiers like %v or %s. It treats all arguments as items to be printed (similar to fmt.Print). To correctly format the error message and the collected diagnostics, you should use Fatalf instead.

		t.Fatalf("create new waypoint proxy failed: %v\n%s", err, diagnostics)

test/e2e/main_test.go (327)

high

The Fatal method does not support format specifiers. Use Fatalf to ensure the error and diagnostics are properly formatted in the test failure output, otherwise the specifiers will be printed literally.

		t.Fatalf("delete waypoint proxy failed: %v\n%s", err, diagnostics)

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Copilot encountered an error and was unable to review this pull request. You can try again by re-requesting a review.

@codecov
Copy link
Copy Markdown

codecov Bot commented May 8, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 39.52%. Comparing base (a5f7474) to head (1834011).
⚠️ Report is 3 commits behind head on main.
see 1 file with indirect coverage changes


Continue to review full report in Codecov by Sentry.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 44745b3...1834011. Read the comment docs.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Copilot AI review requested due to automatic review settings May 8, 2026 18:02
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Copilot encountered an error and was unable to review this pull request. You can try again by re-requesting a review.

@kmesh-bot kmesh-bot added size/L and removed size/M labels May 8, 2026
@rishi-jat rishi-jat force-pushed the improve/waypoint-e2e-diagnostics branch from f3ebc84 to f07059f Compare May 8, 2026 21:16
Copilot AI review requested due to automatic review settings May 8, 2026 21:16
@kmesh-bot kmesh-bot added size/M and removed size/L labels May 8, 2026
Signed-off-by: Rishi Jat <rishijat2002@gmail.com>
Signed-off-by: Rishi Jat <rishijat098@gmail.com>
@rishi-jat rishi-jat force-pushed the improve/waypoint-e2e-diagnostics branch from f07059f to 1834011 Compare May 8, 2026 21:19
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Copilot encountered an error and was unable to review this pull request. You can try again by re-requesting a review.

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

Labels

kind/enhancement New feature or request size/M

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants