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

cask_loader: fix missing checksum in FromContentsLoader #14792

Merged
merged 1 commit into from Feb 24, 2023

Conversation

Bo98
Copy link
Member

@Bo98 Bo98 commented Feb 24, 2023

Fixes #14791

@Bo98 Bo98 added the critical Critical change which should be shipped as soon as possible. label Feb 24, 2023
@BrewTestBot
Copy link
Member

Review period skipped due to critical label.

Copy link
Member

@MikeMcQuaid MikeMcQuaid left a comment

Choose a reason for hiding this comment

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

Thanks again @Bo98! Again, non-blocking comment, merging without to fix the bug but possible follow-up.

Comment on lines +48 to +51
checksum = {
"sha256" => Digest::SHA256.hexdigest(content),
}
Cask.new(header_token, source: content, source_checksum: checksum, **options, config: @config, &block)
Copy link
Member

Choose a reason for hiding this comment

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

Should this argument be made mandatory if things fail when it's not specified?

Copy link
Member Author

Choose a reason for hiding this comment

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

It is not mandatory if sourcefile_path is passed.

I don't really like the million parameters that Cask's constructor can take so will see if there's anything better.

Copy link
Member

Choose a reason for hiding this comment

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

Ah, gotcha, thanks.

@MikeMcQuaid MikeMcQuaid merged commit aeda0c4 into Homebrew:master Feb 24, 2023
@Bo98 Bo98 deleted the cask-contents-checksum branch February 24, 2023 12:58
@github-actions github-actions bot added the outdated PR was locked due to age label Mar 27, 2023
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Mar 27, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
critical Critical change which should be shipped as soon as possible. outdated PR was locked due to age
Projects
None yet
Development

Successfully merging this pull request may close these issues.

ERROR: brew info --json=v2
3 participants