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

Check for valid url, sha256 and version when loading casks #15976

Closed
1 task done
apainintheneck opened this issue Sep 7, 2023 · 4 comments
Closed
1 task done

Check for valid url, sha256 and version when loading casks #15976

apainintheneck opened this issue Sep 7, 2023 · 4 comments
Labels
cask Homebrew Cask discussion Input solicited from others features New features outdated PR was locked due to age stale No recent activity

Comments

@apainintheneck
Copy link
Contributor

Verification

Provide a detailed description of the proposed feature

When we load a cask from a file or the API, we don't check if it has basic attributes necessary to install it on a system. This means that we can see some obscure error messages when those attributes are not defined. On the formula side, we check for those things every time we load anything for the first time. We should do the same thing for casks.

What is the motivation for the feature?

It would improve consistency and give users and package maintainers more helpful error messages.

How will the feature be relevant to at least 90% of Homebrew users?

Getting better error messages and not trying to load cask files that have errors will improve the experience for all users indirectly by helping us troubleshoot problems faster.

What alternatives to the feature have been considered?

Adding more checks around the codebase or leaving things as is.

@apainintheneck apainintheneck added features New features discussion Input solicited from others cask Homebrew Cask labels Sep 7, 2023
@apainintheneck
Copy link
Contributor Author

Changing this requirement would probably break brew search and brew info if we just enabled it everywhere since you're able to see results for packages that can't be installed on your system. I'm not sure how that is handled on the formula side to be honest.

@apainintheneck
Copy link
Contributor Author

We also try to use the original cask file when removing casks and that might cause problems so we might want to be able to turn off these checks at times.

@MikeMcQuaid
Copy link
Member

This seems like a good idea 👍🏻

@github-actions
Copy link

github-actions bot commented Oct 1, 2023

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs.

@github-actions github-actions bot added the stale No recent activity label Oct 1, 2023
@github-actions github-actions bot closed this as not planned Won't fix, can't repro, duplicate, stale Oct 9, 2023
@github-actions github-actions bot added the outdated PR was locked due to age label Nov 9, 2023
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Nov 9, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
cask Homebrew Cask discussion Input solicited from others features New features outdated PR was locked due to age stale No recent activity
Projects
None yet
Development

No branches or pull requests

3 participants
@MikeMcQuaid @apainintheneck and others