Skip to content

Conversation

Luap99
Copy link
Member

@Luap99 Luap99 commented Mar 28, 2025

driver/overlay: inline the mutex in driver

There is no need for the extra pointer indirection. With this Driver can
no longer be copied but that was never supported and now lint should
even catch a copy and warn as copying a Mutex is not allowed.


pkg/idtools: fix lint gofumpt error

CI doesn't seem to cover the libsubid build tag.


CI: add libsubid to lint task

This should ensure we run lint with the libsubid build tag.
Now this is not perfect either, as we do not cover the !libsubid but
that is only one single simple file.

Luap99 added 3 commits March 28, 2025 12:02
There is no need for the extra pointer indirection. With this Driver can
no longer be copied but that was never supported and now lint should
even catch a copy and warn as copying a Mutex is not allowed.

Signed-off-by: Paul Holzinger <pholzing@redhat.com>
CI doesn't seem to cover the libsubid build tag.

Signed-off-by: Paul Holzinger <pholzing@redhat.com>
This should ensure we run lint with the libsubid build tag.
Now this is not perfect either, as we do not cover the !libsubid but
that is only one single simple file.

Signed-off-by: Paul Holzinger <pholzing@redhat.com>
@Luap99 Luap99 marked this pull request as draft March 28, 2025 11:17
@Luap99
Copy link
Member Author

Luap99 commented Mar 28, 2025

tests/tools/build/golangci-lint run --build-tags=" "

Looks like it still doesn't run in CI with the tag...

Copy link
Member

@giuseppe giuseppe left a comment

Choose a reason for hiding this comment

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

LGTM

Copy link
Contributor

openshift-ci bot commented Mar 28, 2025

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: giuseppe, Luap99

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

The library argument must be after the sources. Not sure why this works
on fedora. Taken from a the podman fix[1].

[1] containers/podman@8ff54cb

Signed-off-by: Paul Holzinger <pholzing@redhat.com>
@Luap99 Luap99 marked this pull request as ready for review March 28, 2025 13:20
@Luap99
Copy link
Member Author

Luap99 commented Mar 28, 2025

Ok, now it worked. The

tests/tools/build/golangci-lint run --build-tags=" libsubid "

hack/libsubid_tag.sh was not correctly working either.

@Luap99
Copy link
Member Author

Luap99 commented Mar 28, 2025

cc @mtrmac (for the mutex change based off your comment)

Copy link
Collaborator

@mtrmac mtrmac left a comment

Choose a reason for hiding this comment

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

/lgtm

Thank you!

@openshift-ci openshift-ci bot added the lgtm label Mar 28, 2025
@openshift-merge-bot openshift-merge-bot bot merged commit c800027 into containers:main Mar 28, 2025
20 checks passed
@Luap99 Luap99 deleted the driver-mutex branch March 28, 2025 17:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants