Skip to content

debug#30822

Open
jianlinliu wants to merge 2 commits intoopenshift:mainfrom
jianlinliu:debug-2
Open

debug#30822
jianlinliu wants to merge 2 commits intoopenshift:mainfrom
jianlinliu:debug-2

Conversation

@jianlinliu
Copy link
Contributor

@jianlinliu jianlinliu commented Mar 2, 2026

Summary by CodeRabbit

  • Tests
    • Added extra debug logging to egress IP networking tests to surface probe and target parameters during runs, improving visibility for troubleshooting and test diagnostics.

@openshift-ci-robot
Copy link

Pipeline controller notification
This repo is configured to use the pipeline controller. Second-stage tests will be triggered either automatically or after lgtm label is added, depending on the repository configuration. The pipeline controller will automatically detect which contexts are required and will utilize /test Prow commands to trigger the second stage.

For optional jobs, comment /test ? to see a list of all defined jobs. To trigger manually all jobs from second stage use /pipeline required command.

This repository is configured in: automatic mode

@openshift-ci
Copy link
Contributor

openshift-ci bot commented Mar 2, 2026

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: jianlinliu
Once this PR has been reviewed and has the lgtm label, please assign kyrtapz for approval. For more information see the 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

@coderabbitai
Copy link

coderabbitai bot commented Mar 2, 2026

Walkthrough

Added two debugging log statements to print parameter values in the egressIP networking test file, enhancing diagnostic output for troubleshooting without altering control flow or logic.

Changes

Cohort / File(s) Summary
Debugging Logs
test/extended/networking/egressip.go
Added two framework.Logf statements to output diagnostic information about test parameters (oc, externalNamespace, probePodName, routeName, targetProtocol, targetHost, targetPort, numberOfRequestsToSend, packetSnifferDaemonSet, egressIPSet) immediately after invocations of spawnProberSendEgressIPTrafficCheckLogs.

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~3 minutes

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 inconclusive)

Check name Status Explanation Resolution
Title check ❓ Inconclusive The pull request title 'debug' is a single word that is too vague and generic to convey any meaningful information about the changeset. While the changes do relate to debugging (adding log statements), the title does not provide sufficient clarity about what was debugged or why. Consider using a more descriptive title like 'Add debug logging for egress IP traffic checks' that clearly indicates the specific component and nature of the debugging changes.
✅ Passed checks (4 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Stable And Deterministic Test Names ✅ Passed The pull request adds debugging log statements using framework.Logf in the test body, not test titles. All test titles remain static and deterministic with no dynamic values.
Test Structure And Quality ✅ Passed PR adds only a debug logging statement to test file, which does not violate test quality requirements and does not alter test behavior or introduce new issues.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment

Warning

There were issues while running some tools. Please review the errors and either fix the tool's configuration or disable the tool if it's a critical failure.

🔧 golangci-lint (2.5.0)

Error: can't load config: unsupported version of the configuration: "" See https://golangci-lint.run/docs/product/migration-guide for migration instructions
The command is terminated due to an error: can't load config: unsupported version of the configuration: "" See https://golangci-lint.run/docs/product/migration-guide for migration instructions


Comment @coderabbitai help to get the list of available commands and usage tips.

@openshift-ci openshift-ci bot requested review from arkadeepsen and pliurh March 2, 2026 03:35
Copy link

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In `@test/extended/networking/egressip.go`:
- Around line 457-458: The debug line should be replaced with a concise,
type-safe log that removes the XXXTESTXXX marker, avoids printing the non-string
CLI object `oc` with %s, and stops dumping large objects; instead log scalar
fields with explicit verbs and small summaries for complex objects (e.g. log
`externalNamespace`, `probePodName`, `routeName`, `targetProtocol`,
`targetHost`, `targetPort`, `numberOfRequestsToSend` using %s/%d/%v as
appropriate), omit or replace `oc` with a small identifier (e.g. omit it or log
a stable field if available), and replace `packetSnifferDaemonSet`/`egressIPSet`
with limited signals such as their names or lengths (e.g. `.Name` or `len(...)`)
so CI logs remain low-noise.

ℹ️ Review info

Configuration used: Repository: openshift/coderabbit/.coderabbit.yaml

Review profile: CHILL

Plan: Pro

Cache: Disabled due to data retention organization setting

Knowledge base: Disabled due to data retention organization setting

📥 Commits

Reviewing files that changed from the base of the PR and between 02e33c2 and 0db9e17.

📒 Files selected for processing (1)
  • test/extended/networking/egressip.go

Comment on lines +457 to +458
framework.Logf("XXXTESTXXX oc: %s, externalNamespace: %s, probePodName: %s, routeName: %s, targetProtocol: %s, targetHost: %s, targetPort: %d, numberOfRequestsToSend: %d, packetSnifferDaemonSet: %v, egressIPSet: %v", oc, externalNamespace, probePodName, routeName, targetProtocol, targetHost, targetPort, numberOfRequestsToSend, packetSnifferDaemonSet, egressIPSet)

Copy link

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🟡 Minor

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
set -euo pipefail

# 1) Find CLI type and whether it implements String() string.
echo "=== Searching for CLI type definition ==="
rg -nP --type=go 'type\s+CLI\s+struct'

echo ""
echo "=== Searching for String() method on *CLI ==="
rg -nP --type=go 'func\s*\(\s*(\w+\s+)?\*CLI\s*\)\s*String\s*\(\s*\)\s*string'

echo ""
echo "=== Locating XXXTESTXXX debug marker ==="
rg -n --type=go 'XXXTESTXXX'

echo ""
echo "=== Looking for similar %s usage with oc in Logf ==="
rg -nP --type=go 'Logf\([^)]*%s[^)]*,\s*oc\b'

Repository: openshift/origin

Length of output: 198


🏁 Script executed:

#!/bin/bash
set -euo pipefail

# Check if the file exists and read lines around 457-458
echo "=== File: test/extended/networking/egressip.go (lines 450-465) ==="
if [ -f "test/extended/networking/egressip.go" ]; then
  sed -n '450,465p' test/extended/networking/egressip.go | cat -n
else
  echo "File not found"
fi

echo ""
echo "=== CLI struct definition (test/extended/util/client.go:85-110) ==="
sed -n '85,110p' test/extended/util/client.go | cat -n

echo ""
echo "=== Search for String() methods on any CLI types ==="
rg -n --type=go 'func.*String\(\).*string' test/extended/util/client.go

echo ""
echo "=== All occurrences of XXXTESTXXX in the repository ==="
rg -r 'XXXTESTXXX' --type=go

Repository: openshift/origin

Length of output: 2864


Replace the temporary debug log with type-safe, low-noise fields

Line 457 uses %s for oc (*exutil.CLI), which doesn't implement String() string and will render as malformed output instead of being debuggable. The log also includes a temporary XXXTESTXXX marker and dumps large objects (packetSnifferDaemonSet, egressIPSet) that inflate CI logs without adding signal.

Suggested cleanup
-			framework.Logf("XXXTESTXXX oc: %s, externalNamespace: %s, probePodName: %s, routeName: %s, targetProtocol: %s, targetHost: %s, targetPort: %d, numberOfRequestsToSend: %d, packetSnifferDaemonSet: %v, egressIPSet: %v", oc, externalNamespace, probePodName, routeName, targetProtocol, targetHost, targetPort, numberOfRequestsToSend, packetSnifferDaemonSet, egressIPSet)
+			packetSnifferDaemonSetName := "<nil>"
+			if packetSnifferDaemonSet != nil {
+				packetSnifferDaemonSetName = packetSnifferDaemonSet.Name
+			}
+			framework.Logf("Debug egressIP traffic params: externalNamespace=%s probePodName=%s routeName=%s protocol=%s targetHost=%s targetPort=%d requests=%d packetSnifferDaemonSet=%s egressIPSet=%v",
+				externalNamespace, probePodName, routeName, targetProtocol, targetHost, targetPort, numberOfRequestsToSend, packetSnifferDaemonSetName, egressIPSet)
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@test/extended/networking/egressip.go` around lines 457 - 458, The debug line
should be replaced with a concise, type-safe log that removes the XXXTESTXXX
marker, avoids printing the non-string CLI object `oc` with %s, and stops
dumping large objects; instead log scalar fields with explicit verbs and small
summaries for complex objects (e.g. log `externalNamespace`, `probePodName`,
`routeName`, `targetProtocol`, `targetHost`, `targetPort`,
`numberOfRequestsToSend` using %s/%d/%v as appropriate), omit or replace `oc`
with a small identifier (e.g. omit it or log a stable field if available), and
replace `packetSnifferDaemonSet`/`egressIPSet` with limited signals such as
their names or lengths (e.g. `.Name` or `len(...)`) so CI logs remain low-noise.

Copy link

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

♻️ Duplicate comments (1)
test/extended/networking/egressip.go (1)

457-457: ⚠️ Potential issue | 🟡 Minor

Remove transient debug marker and log compact fields only.

Line 457 still includes XXXTESTXXX and dumps large objects (packetSnifferDaemonSet, full egressIPSet), which makes CI logs noisy. Please keep scalar fields and compact summaries (daemonset name/counts) instead.

Suggested cleanup
-			framework.Logf("XXXTESTXXX: externalNamespace: %s, probePodName: %s, routeName: %s, targetProtocol: %s, targetHost: %s, targetPort: %d, numberOfRequestsToSend: %d, packetSnifferDaemonSet: %v, egressIPSet: %v", externalNamespace, probePodName, routeName, targetProtocol, targetHost, targetPort, numberOfRequestsToSend, packetSnifferDaemonSet, egressIPSet)
+			packetSnifferDaemonSetName := "<nil>"
+			if packetSnifferDaemonSet != nil {
+				packetSnifferDaemonSetName = packetSnifferDaemonSet.Name
+			}
+			framework.Logf("egressIP debug: externalNamespace=%s probePodName=%s routeName=%s targetProtocol=%s targetHost=%s targetPort=%d numberOfRequestsToSend=%d packetSnifferDaemonSet=%s egressIPCount=%d",
+				externalNamespace, probePodName, routeName, targetProtocol, targetHost, targetPort, numberOfRequestsToSend, packetSnifferDaemonSetName, len(egressIPSet))
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@test/extended/networking/egressip.go` at line 457, Remove the transient
"XXXTESTXXX" marker and avoid dumping large objects in the framework.Logf call
in test/extended/networking/egressip.go; instead log only scalar fields
(externalNamespace, probePodName, routeName, targetProtocol, targetHost,
targetPort, numberOfRequestsToSend) and replace packetSnifferDaemonSet and
egressIPSet with compact summaries (e.g., packetSnifferDaemonSet.Name and/or
replica count, and egressIPSet length or a comma-joined short list), updating
the existing Logf invocation to use those summarized values.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Duplicate comments:
In `@test/extended/networking/egressip.go`:
- Line 457: Remove the transient "XXXTESTXXX" marker and avoid dumping large
objects in the framework.Logf call in test/extended/networking/egressip.go;
instead log only scalar fields (externalNamespace, probePodName, routeName,
targetProtocol, targetHost, targetPort, numberOfRequestsToSend) and replace
packetSnifferDaemonSet and egressIPSet with compact summaries (e.g.,
packetSnifferDaemonSet.Name and/or replica count, and egressIPSet length or a
comma-joined short list), updating the existing Logf invocation to use those
summarized values.

ℹ️ Review info

Configuration used: Repository: openshift/coderabbit/.coderabbit.yaml

Review profile: CHILL

Plan: Pro

Cache: Disabled due to data retention organization setting

Knowledge base: Disabled due to data retention organization setting

📥 Commits

Reviewing files that changed from the base of the PR and between 0db9e17 and 8d8f16b.

📒 Files selected for processing (1)
  • test/extended/networking/egressip.go

@openshift-ci-robot
Copy link

Scheduling required tests:
/test e2e-aws-csi
/test e2e-aws-ovn-fips
/test e2e-aws-ovn-microshift
/test e2e-aws-ovn-microshift-serial
/test e2e-aws-ovn-serial-1of2
/test e2e-aws-ovn-serial-2of2
/test e2e-gcp-csi
/test e2e-gcp-ovn
/test e2e-gcp-ovn-upgrade
/test e2e-metal-ipi-ovn-ipv6
/test e2e-vsphere-ovn
/test e2e-vsphere-ovn-upi

@jianlinliu
Copy link
Contributor Author

/test e2e-aws-ovn-serial-publicnet-1of2

@openshift-ci
Copy link
Contributor

openshift-ci bot commented Mar 2, 2026

@jianlinliu: The following test failed, say /retest to rerun all failed tests or /retest-required to rerun all mandatory failed tests:

Test name Commit Details Required Rerun command
ci/prow/e2e-aws-ovn-serial-publicnet-1of2 8d8f16b link false /test e2e-aws-ovn-serial-publicnet-1of2

Full PR test history. Your PR dashboard.

Details

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. I understand the commands that are listed here.

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.

2 participants