Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Automated cherry pick of #124289: e2e node: fix -v support #124415

Conversation

pohly
Copy link
Contributor

@pohly pohly commented Apr 19, 2024

Cherry pick of #124289 on release-1.30.

#124289: e2e node: fix -v support

For details on the cherry pick process, see the cherry pick requests page.


Since 43539c8 (first released in
v1.30.0-alpha.2), the test/e2e/framework manages -v and -vmodule and uses them
for a logger which writes to the Ginkgo output stream.

This did not work for test/e2e_node, because:
- logs.AddFlags(pflag.CommandLine) registers its own -v and -vmodule flags
- pflag.CommandLine.AddGoFlagSet(flag.CommandLine) skips the corresponding
  flags in the flag.CommandLine
- pflag.Parse() initializes the settings in the "logs" package even though
  those are not used at runtime

The solution is to not use the "logs" package.
Even if the textlogger which writes to Ginkgo is installed as the logger in
klog, klog still does some verbosity checks itself (for example,
klog.V().Enabled).

Therefore the framework has to keep the verbosity settings in the textlogger
and in klog consistent. This is done by wrapping the Set call instead of
replacing it.
@k8s-ci-robot k8s-ci-robot added the do-not-merge/cherry-pick-not-approved Indicates that a PR is not yet approved to merge into a release branch. label Apr 19, 2024
@k8s-ci-robot k8s-ci-robot added this to the v1.30 milestone Apr 19, 2024
@k8s-ci-robot k8s-ci-robot added size/S Denotes a PR that changes 10-29 lines, ignoring generated files. do-not-merge/release-note-label-needed Indicates that a PR should not merge because it's missing one of the release note labels. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. do-not-merge/needs-kind Indicates a PR lacks a `kind/foo` label and requires one. do-not-merge/needs-sig Indicates an issue or PR lacks a `sig/foo` label and requires one. needs-triage Indicates an issue or PR lacks a `triage/foo` label and requires one. needs-priority Indicates a PR lacks a `priority/foo` label and requires one. labels Apr 19, 2024
@k8s-ci-robot k8s-ci-robot added the area/e2e-test-framework Issues or PRs related to refactoring the kubernetes e2e test framework label Apr 19, 2024
@k8s-ci-robot k8s-ci-robot added area/test approved Indicates a PR has been approved by an approver from all required OWNERS files. sig/node Categorizes an issue or PR as relevant to SIG Node. sig/testing Categorizes an issue or PR as relevant to SIG Testing. and removed do-not-merge/needs-sig Indicates an issue or PR lacks a `sig/foo` label and requires one. labels Apr 19, 2024
@pohly
Copy link
Contributor Author

pohly commented Apr 19, 2024

/assign @SergeyKanzhelev

@SergeyKanzhelev
Copy link
Member

failures are from k8s infra

/retest

/approve
/lgtm

Change is small and test-only. And will make things easier for 1.30. Suitable for cherry pick for sure.

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Apr 19, 2024
@k8s-ci-robot
Copy link
Contributor

LGTM label has been added.

Git tree hash: 591af649abc0abc6128acbd7e55b3eff23766b22

@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: pohly, SergeyKanzhelev

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

The pull request process is described here

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

@SergeyKanzhelev
Copy link
Member

/cc kubernetes/release-managers

@SergeyKanzhelev
Copy link
Member

/priority important-soon

@k8s-ci-robot k8s-ci-robot added priority/important-soon Must be staffed and worked on either currently, or very soon, ideally in time for the next release. and removed needs-priority Indicates a PR lacks a `priority/foo` label and requires one. labels Apr 19, 2024
@SergeyKanzhelev
Copy link
Member

/kind bug

@k8s-ci-robot k8s-ci-robot added kind/bug Categorizes issue or PR as related to a bug. and removed do-not-merge/needs-kind Indicates a PR lacks a `kind/foo` label and requires one. labels Apr 19, 2024
@SergeyKanzhelev
Copy link
Member

/release-note-none

@k8s-ci-robot k8s-ci-robot added release-note-none Denotes a PR that doesn't merit a release note. and removed do-not-merge/release-note-label-needed Indicates that a PR should not merge because it's missing one of the release note labels. labels Apr 19, 2024
@SergeyKanzhelev
Copy link
Member

should have done all PR metadata in a single comment. Sorry for the spam

@bart0sh
Copy link
Contributor

bart0sh commented Apr 23, 2024

/triage accepted

@k8s-ci-robot k8s-ci-robot added triage/accepted Indicates an issue or PR is ready to be actively worked on. and removed needs-triage Indicates an issue or PR lacks a `triage/foo` label and requires one. labels Apr 23, 2024
@bart0sh bart0sh moved this from Triage to Needs Approver in SIG Node PR Triage Apr 23, 2024
@SergeyKanzhelev SergeyKanzhelev moved this from Triage to Done in SIG Node CI/Test Board Apr 24, 2024
Copy link

@Verolop Verolop left a comment

Choose a reason for hiding this comment

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

/lgtm

(Release Manager)

@Verolop Verolop added the cherry-pick-approved Indicates a cherry-pick PR into a release branch has been approved by the release branch manager. label May 10, 2024
@k8s-ci-robot k8s-ci-robot removed the do-not-merge/cherry-pick-not-approved Indicates that a PR is not yet approved to merge into a release branch. label May 10, 2024
@k8s-ci-robot k8s-ci-robot merged commit 7d9aab8 into kubernetes:release-1.30 May 10, 2024
17 checks passed
SIG Node PR Triage automation moved this from Needs Approver to Done May 10, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. area/e2e-test-framework Issues or PRs related to refactoring the kubernetes e2e test framework area/test cherry-pick-approved Indicates a cherry-pick PR into a release branch has been approved by the release branch manager. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. kind/bug Categorizes issue or PR as related to a bug. lgtm "Looks good to me", indicates that a PR is ready to be merged. priority/important-soon Must be staffed and worked on either currently, or very soon, ideally in time for the next release. release-note-none Denotes a PR that doesn't merit a release note. sig/node Categorizes an issue or PR as relevant to SIG Node. sig/testing Categorizes an issue or PR as relevant to SIG Testing. size/S Denotes a PR that changes 10-29 lines, ignoring generated files. triage/accepted Indicates an issue or PR is ready to be actively worked on.
Projects
Development

Successfully merging this pull request may close these issues.

None yet

5 participants