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

brew doctor errors without giving advice about how to resolve No Cask with this name exists. #13027

Closed
2 tasks done
jsoref opened this issue Mar 22, 2022 · 2 comments · Fixed by #13067
Closed
2 tasks done
Assignees
Labels
bug Reproducible Homebrew/brew bug outdated PR was locked due to age

Comments

@jsoref
Copy link
Contributor

jsoref commented Mar 22, 2022

brew config output

HOMEBREW_VERSION: 3.4.3
ORIGIN: https://github.com/Homebrew/brew
HEAD: 600d84e56eda931c3dd3b6a9ee61233d9bf2b054
Last commit: 3 days ago
Core tap ORIGIN: https://github.com/Homebrew/homebrew-core
Core tap HEAD: 938bc3e868b93605f67fb43f836151af4332f6cd
Core tap last commit: 25 hours ago
Core tap branch: master
HOMEBREW_PREFIX: /opt/homebrew
HOMEBREW_CASK_OPTS: []
HOMEBREW_CORE_GIT_REMOTE: https://github.com/Homebrew/homebrew-core
HOMEBREW_MAKE_JOBS: 10
Homebrew Ruby: 2.6.8 => /System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/bin/ruby
CPU: 10-core 64-bit arm_firestorm_icestorm
Clang: 13.1.6 build 1316
Git: 2.35.1 => /opt/homebrew/bin/git
Curl: 7.79.1 => /usr/bin/curl
macOS: 12.3-arm64
CLT: 13.3.0.0.1.1645755326
Xcode: N/A
Rosetta 2: false

brew doctor output

Error: Cask 'font-dejavu-sans' is unavailable: No Cask with this name exists.

Verification

  • I ran brew update and am still able to reproduce my issue.
  • I have resolved all warnings from brew doctor and that did not fix my problem.

What were you trying to do (and why)?

Reproduce Homebrew/homebrew-cask#71221 (comment) to determine that brew doctor's output is indeed very unhelpful.

What happened (include all command output)?

  1. Simulate having a font-dejavu-sans cask from before it was removed (?).
mkdir -p /opt/homebrew/Caskroom/font-dejavu-sans
  1. run brew doctor

What did you expect to happen?

brew doctor should explain that I have an obsolete cask and what I should do to remove it so that brew doctor can work.

At the very least, it should tell me a full path to things it doesn't like so I at least know where to look (I have two instances of brew installed, the other runs under rosetta).

Step-by-step reproduction instructions (by running brew commands)

mkdir -p /opt/homebrew/Caskroom/font-dejavu-sans
brew doctor
@jsoref jsoref added the bug Reproducible Homebrew/brew bug label Mar 22, 2022
@MikeMcQuaid
Copy link
Member

Can I see the output of brew doctor --debug here? Thanks!

@jsoref
Copy link
Contributor Author

jsoref commented Mar 24, 2022

Error: Cask 'font-dejavu-sans' is unavailable: No Cask with this name exists.
/opt/homebrew/Library/Homebrew/cask/cask_loader.rb:196:in `load'
/opt/homebrew/Library/Homebrew/cask/cask_loader.rb:205:in `load'
/opt/homebrew/Library/Homebrew/cask/caskroom.rb:47:in `block in casks'
/opt/homebrew/Library/Homebrew/cask/caskroom.rb:39:in `map'
/opt/homebrew/Library/Homebrew/cask/caskroom.rb:39:in `casks'
/opt/homebrew/Library/Homebrew/cmd/doctor.rb:51:in `doctor'
/opt/homebrew/Library/Homebrew/brew.rb:110:in `<main>'

@MikeMcQuaid MikeMcQuaid self-assigned this Mar 30, 2022
MikeMcQuaid added a commit that referenced this issue Mar 30, 2022
Add a new method for the two places we're checking if we have any
casks installed. This is much more performance and user friendly than
attempting to load every cask.

Fixes #13027
@github-actions github-actions bot added the outdated PR was locked due to age label Apr 30, 2022
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Apr 30, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Reproducible Homebrew/brew bug outdated PR was locked due to age
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants