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

Fix premature Close() of docker client #1056

Merged
merged 1 commit into from
Jun 13, 2022

Conversation

matejvasek
Copy link
Contributor

@matejvasek matejvasek commented Jun 13, 2022

Changes

  • Fix premature Close() of docker client

/kind bug

fix: s2i+podman "Cannot connect to the Docker daemon" error

@knative-prow knative-prow bot added the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Jun 13, 2022
@matejvasek matejvasek marked this pull request as ready for review June 13, 2022 20:53
@knative-prow
Copy link

knative-prow bot commented Jun 13, 2022

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: matejvasek

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

@knative-prow knative-prow bot added approved Indicates a PR has been approved by an approver from all required OWNERS files. size/S Denotes a PR that changes 10-29 lines, ignoring generated files. and removed do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. labels Jun 13, 2022
Signed-off-by: Matej Vasek <mvasek@redhat.com>
if err != nil {
return
}
defer client.Close()
Copy link
Contributor Author

Choose a reason for hiding this comment

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

This is first time I find defer scoping of Go useful.

Copy link
Contributor

Choose a reason for hiding this comment

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

:D

@matejvasek
Copy link
Contributor Author

@lance we might wan't to cherry pick this to 0.24.0

@matejvasek
Copy link
Contributor Author

and maybe backport this to midstream maybe?

@codecov
Copy link

codecov bot commented Jun 13, 2022

Codecov Report

Merging #1056 (f585eb4) into main (df7b573) will not change coverage.
The diff coverage is 0.00%.

@@           Coverage Diff           @@
##             main    #1056   +/-   ##
=======================================
  Coverage   46.79%   46.79%           
=======================================
  Files          59       59           
  Lines        7761     7761           
=======================================
  Hits         3632     3632           
  Misses       3783     3783           
  Partials      346      346           
Impacted Files Coverage Δ
s2i/builder.go 70.78% <0.00%> (ø)

Continue to review full report at Codecov.

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

Copy link
Member

@lance lance left a comment

Choose a reason for hiding this comment

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

/lgtm
/hold for tests

@knative-prow knative-prow bot added the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Jun 13, 2022
@knative-prow knative-prow bot added the lgtm Indicates that a PR is ready to be merged. label Jun 13, 2022
@lance
Copy link
Member

lance commented Jun 13, 2022

/unhold

@knative-prow knative-prow bot removed the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Jun 13, 2022
@knative-prow knative-prow bot merged commit 5f6d11c into knative:main Jun 13, 2022
@lance
Copy link
Member

lance commented Jun 13, 2022

/cherry-pick release-0.24

@knative-prow-robot
Copy link

@lance: new pull request created: #1057

In response to this:

/cherry-pick release-0.24

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.

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. lgtm Indicates that a PR is ready to be merged. size/S Denotes a PR that changes 10-29 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants