Skip to content

Bug 1991860: Don't try to record an empty Record if gatherClusterConfigV1 fails#484

Closed
mtrmac wants to merge 1 commit intoopenshift:masterfrom
mtrmac:cluster-config-v1-crash
Closed

Bug 1991860: Don't try to record an empty Record if gatherClusterConfigV1 fails#484
mtrmac wants to merge 1 commit intoopenshift:masterfrom
mtrmac:cluster-config-v1-crash

Conversation

@mtrmac
Copy link
Copy Markdown
Contributor

@mtrmac mtrmac commented Aug 10, 2021

Currently, gatherClusterConfigV1 returns (Record{}, error) on failure, and its caller appends the empty Record into its results; that later crashes in Record.Filename() because Record.Item is nil.

Instead, be more similar to the sibling function and return a []Record{}, which allows gatherClusterConfigV1 to return no records.

Categories

  • Bugfix
  • Enhancement
  • Backporting
  • Others (CI, Infrastructure, Documentation)

Sample Archive

See https://prow.ci.openshift.org/view/gs/origin-ci-test/pr-logs/pull/openshift_machine-config-operator/2695/pull-ci-openshift-machine-config-operator-master-e2e-aws-disruptive/1421081909886193664

Documentation

Unit Tests

N/A, the existing code doesn’t have unit tests of this nature.

Privacy

N/A, no newly collected information.

Changelog

?

Breaking Changes

No

References

None

Currently, gatherClusterConfigV1 returns (Record{}, error) on failure,
and its caller appends the empty Record into its results; that
later crashes in Record.Filename() because Record.Item is nil.

Instead, be more similar to the sibling function and return a []Record{},
which allows gatherClusterConfigV1 to return no records.

Signed-off-by: Miloslav Trmač <mitr@redhat.com>
@mtrmac mtrmac force-pushed the cluster-config-v1-crash branch from 7d0c1ca to f47bb91 Compare August 10, 2021 21:12
@openshift-ci
Copy link
Copy Markdown

openshift-ci Bot commented Aug 10, 2021

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: mtrmac
To complete the pull request process, please assign tremes after the PR has been reviewed.
You can assign the PR to them by writing /assign @tremes in a comment when ready.

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

@mtrmac mtrmac changed the title Don't try to record an empty Record if gatherClusterConfigV1 fails Bug 1991860: Don't try to record an empty Record if gatherClusterConfigV1 fails Aug 10, 2021
@openshift-ci openshift-ci Bot added the bugzilla/severity-unspecified Referenced Bugzilla bug's severity is unspecified for the PR. label Aug 10, 2021
@openshift-ci
Copy link
Copy Markdown

openshift-ci Bot commented Aug 10, 2021

@mtrmac: This pull request references Bugzilla bug 1991860, which is invalid:

  • expected the bug to target the "4.9.0" release, but it targets "---" instead

Comment /bugzilla refresh to re-evaluate validity if changes to the Bugzilla bug are made, or edit the title of this pull request to link to a different bug.

Details

In response to this:

Bug 1991860: Don't try to record an empty Record if gatherClusterConfigV1 fails

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/test-infra repository.

@openshift-ci openshift-ci Bot added the bugzilla/invalid-bug Indicates that a referenced Bugzilla bug is invalid for the branch this PR is targeting. label Aug 10, 2021
@openshift-ci
Copy link
Copy Markdown

openshift-ci Bot commented Aug 10, 2021

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

Test name Commit Details Rerun command
ci/prow/e2e 7d0c1ca link /test e2e

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/test-infra repository. I understand the commands that are listed here.

@mtrmac
Copy link
Copy Markdown
Contributor Author

mtrmac commented Aug 10, 2021

/bugzilla refresh

@openshift-ci openshift-ci Bot added bugzilla/severity-medium Referenced Bugzilla bug's severity is medium for the branch this PR is targeting. bugzilla/valid-bug Indicates that a referenced Bugzilla bug is valid for the branch this PR is targeting. and removed bugzilla/severity-unspecified Referenced Bugzilla bug's severity is unspecified for the PR. labels Aug 10, 2021
@openshift-ci
Copy link
Copy Markdown

openshift-ci Bot commented Aug 10, 2021

@mtrmac: This pull request references Bugzilla bug 1991860, which is valid. The bug has been moved to the POST state. The bug has been updated to refer to the pull request using the external bug tracker.

3 validation(s) were run on this bug
  • bug is open, matching expected state (open)
  • bug target release (4.9.0) matches configured target release for branch (4.9.0)
  • bug is in the state NEW, which is one of the valid states (NEW, ASSIGNED, ON_DEV, POST, POST)

No GitHub users were found matching the public email listed for the QA contact in Bugzilla (dmisharo@redhat.com), skipping review request.

Details

In response to this:

/bugzilla refresh

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/test-infra repository.

@openshift-ci openshift-ci Bot removed the bugzilla/invalid-bug Indicates that a referenced Bugzilla bug is invalid for the branch this PR is targeting. label Aug 10, 2021
@tremes
Copy link
Copy Markdown
Contributor

tremes commented Aug 11, 2021

@mtrmac Thank you, however it would be nice if you assign the BZ to yourself when you're working on that (or plan to work on that). I have already prepared tremes@e348871

@mtrmac
Copy link
Copy Markdown
Contributor Author

mtrmac commented Aug 11, 2021

@mtrmac Thank you, however it would be nice if you assign the BZ to yourself when you're working on that

I’m afraid I’m not going to to take the lead on this; this is a three-levels-deep dependency on some other work I’m actually doing, and I know basically nothing about the insights operator.

Feel free to treat this as a third-party drive-by PR; if you want to disconnect it from the bug, reprioritize the bug to some other time, or fix it in some other way, any of that is perfectly fine with me.

@tremes
Copy link
Copy Markdown
Contributor

tremes commented Aug 11, 2021

@mtrmac No problem. The change is fine. I was only little bit surprised :) OK so let me take your commit and add mine there and I will open a new PR if you're OK with that.

@tremes
Copy link
Copy Markdown
Contributor

tremes commented Aug 11, 2021

I took the @mtrmac's commit and created new #485. Thanks a lot!

@tremes
Copy link
Copy Markdown
Contributor

tremes commented Aug 11, 2021

/close

@openshift-ci openshift-ci Bot closed this Aug 11, 2021
@openshift-ci
Copy link
Copy Markdown

openshift-ci Bot commented Aug 11, 2021

@tremes: Closed this PR.

Details

In response to this:

/close

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/test-infra repository.

@openshift-ci
Copy link
Copy Markdown

openshift-ci Bot commented Aug 11, 2021

@mtrmac: This pull request references Bugzilla bug 1991860. The bug has been updated to no longer refer to the pull request using the external bug tracker.

Details

In response to this:

Bug 1991860: Don't try to record an empty Record if gatherClusterConfigV1 fails

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/test-infra repository.

@mtrmac mtrmac deleted the cluster-config-v1-crash branch August 11, 2021 15:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bugzilla/severity-medium Referenced Bugzilla bug's severity is medium for the branch this PR is targeting. bugzilla/valid-bug Indicates that a referenced Bugzilla bug is valid for the branch this PR is targeting.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants