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

Fail if a build results in an empty package #670

Closed
luhring opened this issue Sep 9, 2023 · 5 comments
Closed

Fail if a build results in an empty package #670

luhring opened this issue Sep 9, 2023 · 5 comments
Assignees

Comments

@luhring
Copy link
Member

luhring commented Sep 9, 2023

Melange should detect and fail for the case where a built APK file was left with nothing but directories and an SBOM.

See motivation and context here: wolfi-dev/os#5336 (comment)

@kaniini
Copy link
Contributor

kaniini commented Sep 11, 2023

We need a way to allow this for some packages, like build-base and wolfi-base, which contain no actual data, but group dependencies together.

@Elizafox
Copy link
Contributor

Elizafox commented Sep 19, 2023

We need a way to allow this for some packages, like build-base and wolfi-base, which contain no actual data, but group dependencies together.

Perhaps set something in the melange config stating the package is a metapackage? Something like:

package:
  name: foobar
  empty: true

Alternatively, this could be a linter, which could be turned off. But I think I'd need a post-walking linter.

@luhring
Copy link
Member Author

luhring commented Sep 19, 2023

Perhaps set something in the melange config stating the package is a metapackage

I like the explicitness 👍

@Elizafox
Copy link
Contributor

Perhaps set something in the melange config stating the package is a metapackage

I like the explicitness 👍

I found out there's already:

package:
  options:
    no-provides: true

So I wrote the linter in #700 to respect it.

Incidentally, #700 will close this I believe.

@Elizafox Elizafox self-assigned this Sep 21, 2023
@Elizafox
Copy link
Contributor

Completed in #700. This lint can be disabled if needed.

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

No branches or pull requests

3 participants