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

Several fonts still can't install #55

Open
iandol opened this issue Jul 1, 2024 · 4 comments
Open

Several fonts still can't install #55

iandol opened this issue Jul 1, 2024 · 4 comments

Comments

@iandol
Copy link
Contributor

iandol commented Jul 1, 2024

General troubleshooting steps

  • [x ] I have retried my command with --force and the issue is still present.
  • [x ] I have checked the instructions for reporting bugs (or making requests) before opening the issue.
    • [x ] None of the templates was appropriate for my issue, or I’m not sure.
  • [ x] I ran brew update-reset && brew update and retried my command.
  • [ x] I ran brew doctor, fixed as many issues as possible and retried my command.
  • [ x] I understand that if I ignore these instructions, my issue may be closed without review.

Description of issue

#53 was closed, but the underlying problem remains. Several fonts still do not install:

e.g. font-jetbrains-mono:

ε ➪ brew install --force font-jetbrains-mono
==> Auto-updating Homebrew...
Adjust how often this is run with HOMEBREW_AUTO_UPDATE_SECS or disable with
HOMEBREW_NO_AUTO_UPDATE. Hide these hints with HOMEBREW_NO_ENV_HINTS (see `man brew`).
==> Fetching homebrew/linux-fonts/font-jetbrains-mono
==> Downloading https://github.com/JetBrains/JetBrainsMono/releases/download/v2.304/JetBra
==> Downloading from https://objects.githubusercontent.com/github-production-release-asset
################################################################################### 100.0%
==> Installing font-jetbrains-mono from homebrew/linux-fonts
Error: An exception occurred within a child process:
  TypeError: Parameter 'sources': Expected type T.any(Pathname, Resource, Resource::Partial, String, T::Array[T.any(Pathname, String)], T::Hash[T.any(Pathname, String), String]), got type NilClass
Caller: /home/linuxbrew/.linuxbrew/Homebrew/Library/Homebrew/vendor/bundle/ruby/3.3.0/gems/sorbet-runtime-0.5.11463/lib/types/private/methods/call_validation.rb:215
Definition: /home/linuxbrew/.linuxbrew/Homebrew/Library/Homebrew/extend/pathname.rb:93 (Pathname#install)

See also font-stix. I got some other fonts to work, e.g. font-juliamono. Looking at the formula the main difference is the font-juliamono has no verified:

class FontJuliamono < Formula
  desc "Juliamono font"
  homepage "https://github.com/cormullion/juliamono"
  url "https://github.com/cormullion/juliamono/releases/download/v0.056/JuliaMono.tar.gz"

but jetbrains-mono and stix do:

class FontJetbrainsMono < Formula
  desc "Jetbrains mono font"
  homepage "https://www.jetbrains.com/lp/mono"
  url "https://github.com/JetBrains/JetBrainsMono/releases/download/v2.304/JetBrainsMono-2.304.zip",
       verified: "github.com/JetBrains/JetBrainsMono/"

Output of your command with --verbose --debug

ε ◎ brew install --force --verbose --debug font-stix
==> Auto-updating Homebrew...
Adjust how often this is run with HOMEBREW_AUTO_UPDATE_SECS or disable with
HOMEBREW_NO_AUTO_UPDATE. Hide these hints with HOMEBREW_NO_ENV_HINTS (see `man brew`).
/home/linuxbrew/.linuxbrew/Homebrew/Library/Homebrew/brew.rb (Formulary::FromNameLoader): loading font-stix
/home/linuxbrew/.linuxbrew/Homebrew/Library/Homebrew/brew.rb (Formulary::FromNameLoader): loading font-stix
==> Fetching homebrew/linux-fonts/font-stix
==> Downloading https://github.com/stipub/stixfonts/archive/refs/tags/v2.13.tar.gz
/usr/bin/env /home/linuxbrew/.linuxbrew/Homebrew/Library/Homebrew/shims/shared/curl --disable --cookie /dev/null --globoff --show-error --user-agent Linuxbrew/4.3.8-12-g3aeef5a\ \(Linux\;\ x86_64\ Ubuntu\ 22.04.4\ LTS\)\ curl/7.81.0 --header Accept-Language:\ en --retry 3 --fail --location --silent --head https://github.com/stipub/stixfonts/archive/refs/tags/v2.13.tar.gz
Already downloaded: /home/cog5/.cache/Homebrew/downloads/ca252da4cf0d499057382b83ecb2e408012227785a76603c62d778a7aeb35ec2--stixfonts-2.13.tar.gz
==> Verifying checksum for 'ca252da4cf0d499057382b83ecb2e408012227785a76603c62d778a7aeb35ec2--stixfonts-2.13.tar.gz'
==> Installing font-stix from homebrew/linux-fonts
/home/linuxbrew/.linuxbrew/Homebrew/Library/Homebrew/brew.rb (Formulary::FromTapLoader): loading homebrew/linux-fonts/font-stix
/usr/bin/env /home/linuxbrew/.linuxbrew/Homebrew/Library/Homebrew/shims/shared/git --version
/home/linuxbrew/.linuxbrew/Homebrew/Library/Homebrew/build.rb (Formulary::FromPathLoader): loading /home/linuxbrew/.linuxbrew/Homebrew/Library/Taps/homebrew/homebrew-linux-fonts/Formula/font-stix.rb
/home/linuxbrew/.linuxbrew/Homebrew/Library/Homebrew/build.rb (Formulary::FromAPILoader): loading gcc@11
/home/linuxbrew/.linuxbrew/Homebrew/Library/Homebrew/build.rb (Formulary::FromAPILoader): loading binutils
/home/linuxbrew/.linuxbrew/Homebrew/Library/Homebrew/build.rb (Formulary::FromAPILoader): loading make
/usr/bin/env /home/linuxbrew/.linuxbrew/Homebrew/Library/Homebrew/shims/shared/git --version
/home/linuxbrew/.linuxbrew/Homebrew/Library/Homebrew/build.rb (Formulary::FromAPILoader): loading gcc
/home/linuxbrew/.linuxbrew/Homebrew/Library/Homebrew/build.rb (Formulary::FromAPILoader): loading gcc@11
/home/linuxbrew/.linuxbrew/Homebrew/Library/Homebrew/build.rb (Formulary::FromAPILoader): loading gcc
/home/linuxbrew/.linuxbrew/Homebrew/Library/Homebrew/build.rb (Formulary::FromAPILoader): loading gcc@11
/usr/bin/env tar --extract --no-same-owner --file /home/cog5/.cache/Homebrew/downloads/ca252da4cf0d499057382b83ecb2e408012227785a76603c62d778a7aeb35ec2--stixfonts-2.13.tar.gz --directory /tmp/homebrew-unpack20240701-77343-c8pj94
/usr/bin/env cp -pR /tmp/homebrew-unpack20240701-77343-c8pj94/stixfonts-2.13/. /tmp/font-stix-20240701-77343-dsv8im/stixfonts-2.13
/home/linuxbrew/.linuxbrew/Homebrew/Library/Homebrew/ignorable.rb:27:in `block in raise'
TypeError: Parameter 'sources': Expected type T.any(Pathname, Resource, Resource::Partial, String, T::Array[T.any(Pathname, String)], T::Hash[T.any(Pathname, String), String]), got type NilClass
Caller: /home/linuxbrew/.linuxbrew/Homebrew/Library/Homebrew/vendor/bundle/ruby/3.3.0/gems/sorbet-runtime-0.5.11463/lib/types/private/methods/call_validation.rb:215
Definition: /home/linuxbrew/.linuxbrew/Homebrew/Library/Homebrew/extend/pathname.rb:93 (Pathname#install)
1. raise
2. ignore
3. backtrace
4. irb
5. shell
Choose an action: 1
==> Temporary files retained at:
/tmp/font-stix-20240701-77343-dsv8im
Error: An exception occurred within a child process:
  TypeError: Parameter 'sources': Expected type T.any(Pathname, Resource, Resource::Partial, String, T::Array[T.any(Pathname, String)], T::Hash[T.any(Pathname, String), String]), got type NilClass
Caller: /home/linuxbrew/.linuxbrew/Homebrew/Library/Homebrew/vendor/bundle/ruby/3.3.0/gems/sorbet-runtime-0.5.11463/lib/types/private/methods/call_validation.rb:215
Definition: /home/linuxbrew/.linuxbrew/Homebrew/Library/Homebrew/extend/pathname.rb:93 (Pathname#install)
/home/linuxbrew/.linuxbrew/Homebrew/Library/Homebrew/ignorable.rb:27:in `block in raise'
/home/linuxbrew/.linuxbrew/Homebrew/Library/Homebrew/ignorable.rb:26:in `callcc'
/home/linuxbrew/.linuxbrew/Homebrew/Library/Homebrew/ignorable.rb:26:in `raise'
/home/linuxbrew/.linuxbrew/Homebrew/Library/Homebrew/vendor/bundle/ruby/3.3.0/gems/sorbet-runtime-0.5.11463/lib/types/configuration.rb:296:in `call_validation_error_handler_default'
/home/linuxbrew/.linuxbrew/Homebrew/Library/Homebrew/vendor/bundle/ruby/3.3.0/gems/sorbet-runtime-0.5.11463/lib/types/configuration.rb:303:in `call_validation_error_handler'
/home/linuxbrew/.linuxbrew/Homebrew/Library/Homebrew/vendor/bundle/ruby/3.3.0/gems/sorbet-runtime-0.5.11463/lib/types/private/methods/call_validation.rb:310:in `report_error'
/home/linuxbrew/.linuxbrew/Homebrew/Library/Homebrew/vendor/bundle/ruby/3.3.0/gems/sorbet-runtime-0.5.11463/lib/types/private/methods/call_validation.rb:218:in `block in validate_call'
/home/linuxbrew/.linuxbrew/Homebrew/Library/Homebrew/vendor/bundle/ruby/3.3.0/gems/sorbet-runtime-0.5.11463/lib/types/private/methods/signature.rb:222:in `block in each_args_value_type'
<internal:numeric>:237:in `times'
/home/linuxbrew/.linuxbrew/Homebrew/Library/Homebrew/vendor/bundle/ruby/3.3.0/gems/sorbet-runtime-0.5.11463/lib/types/private/methods/signature.rb:221:in `each_args_value_type'
/home/linuxbrew/.linuxbrew/Homebrew/Library/Homebrew/vendor/bundle/ruby/3.3.0/gems/sorbet-runtime-0.5.11463/lib/types/private/methods/call_validation.rb:215:in `validate_call'
/home/linuxbrew/.linuxbrew/Homebrew/Library/Homebrew/vendor/bundle/ruby/3.3.0/gems/sorbet-runtime-0.5.11463/lib/types/private/methods/_methods.rb:277:in `block in _on_method_added'
/home/linuxbrew/.linuxbrew/Homebrew/Library/Taps/homebrew/homebrew-linux-fonts/Formula/font-stix.rb:10:in `install'
/home/linuxbrew/.linuxbrew/Homebrew/Library/Homebrew/debrew.rb:15:in `block in install'
/home/linuxbrew/.linuxbrew/Homebrew/Library/Homebrew/debrew.rb:86:in `debrew'
/home/linuxbrew/.linuxbrew/Homebrew/Library/Homebrew/debrew.rb:15:in `install'
/home/linuxbrew/.linuxbrew/Homebrew/Library/Homebrew/build.rb:177:in `block (3 levels) in install'
/home/linuxbrew/.linuxbrew/Homebrew/Library/Homebrew/extend/kernel.rb:528:in `with_env'
/home/linuxbrew/.linuxbrew/Homebrew/Library/Homebrew/build.rb:137:in `block (2 levels) in install'
/home/linuxbrew/.linuxbrew/Homebrew/Library/Homebrew/formula.rb:1578:in `block in brew'
/home/linuxbrew/.linuxbrew/Homebrew/Library/Homebrew/formula.rb:3209:in `block (2 levels) in stage'
/home/linuxbrew/.linuxbrew/Homebrew/Library/Homebrew/extend/kernel.rb:528:in `with_env'
/home/linuxbrew/.linuxbrew/Homebrew/Library/Homebrew/formula.rb:3208:in `block in stage'
/home/linuxbrew/.linuxbrew/Homebrew/Library/Homebrew/resource.rb:127:in `block (2 levels) in unpack'
/home/linuxbrew/.linuxbrew/Homebrew/Library/Homebrew/download_strategy.rb:119:in `chdir'
/home/linuxbrew/.linuxbrew/Homebrew/Library/Homebrew/download_strategy.rb:119:in `chdir'
/home/linuxbrew/.linuxbrew/Homebrew/Library/Homebrew/download_strategy.rb:106:in `stage'
/home/linuxbrew/.linuxbrew/Homebrew/Library/Homebrew/resource.rb:123:in `block in unpack'
/home/linuxbrew/.linuxbrew/Homebrew/Library/Homebrew/mktemp.rb:75:in `block in run'
/home/linuxbrew/.linuxbrew/Homebrew/Library/Homebrew/mktemp.rb:75:in `chdir'
/home/linuxbrew/.linuxbrew/Homebrew/Library/Homebrew/mktemp.rb:75:in `run'
/home/linuxbrew/.linuxbrew/Homebrew/Library/Homebrew/resource.rb:229:in `stage_resource'
/home/linuxbrew/.linuxbrew/Homebrew/Library/Homebrew/resource.rb:122:in `unpack'
/home/linuxbrew/.linuxbrew/Homebrew/Library/Homebrew/resource.rb:96:in `stage'
/home/linuxbrew/.linuxbrew/Homebrew/Library/Homebrew/vendor/portable-ruby/3.3.3/lib/ruby/3.3.0/forwardable.rb:240:in `stage'
/home/linuxbrew/.linuxbrew/Homebrew/Library/Homebrew/formula.rb:3186:in `stage'
/home/linuxbrew/.linuxbrew/Homebrew/Library/Homebrew/formula.rb:1571:in `brew'
/home/linuxbrew/.linuxbrew/Homebrew/Library/Homebrew/build.rb:131:in `block in install'
/home/linuxbrew/.linuxbrew/Homebrew/Library/Homebrew/extend/kernel.rb:528:in `with_env'
/home/linuxbrew/.linuxbrew/Homebrew/Library/Homebrew/build.rb:123:in `install'
/home/linuxbrew/.linuxbrew/Homebrew/Library/Homebrew/build.rb:229:in `<main>'
Exception: brew exited with 1

Output of brew cask doctor

ε ◎ brew doctor
Please note that these warnings are just used to help the Homebrew maintainers
with debugging if you file an issue. If everything you use Homebrew for is
working fine: please don't worry or file an issue; just ignore this. Thanks!

Warning: Suspicious https://github.com/Homebrew/homebrew-core git origin remote found.
The current git origin is:
  https://mirrors.tuna.tsinghua.edu.cn/git/homebrew/homebrew-core.git

With a non-standard origin, Homebrew won't update properly.
You can solve this by setting the origin remote:
  git -C "/home/linuxbrew/.linuxbrew/Homebrew/Library/Taps/homebrew/homebrew-core" remote set-url origin https://github.com/Homebrew/homebrew-core

Warning: Some installed kegs have no formulae!
This means they were either deleted or installed manually.
You should find replacements for the following formulae:
  font-fantasque-sans-mono
  font-alegreya-sans
  font-recursive-code
  font-alegreya
  font-cascadia-code
  font-fira-code
  font-symbols-only-nerd-font

Warning: Some installed formulae are deprecated or disabled.
You should find replacements for the following formulae:
  [email protected]

Warning: Unbrewed header files were found in /usr/local/include.
If you didn't put them there on purpose they could cause problems when
building Homebrew formulae and may need to be deleted.

Unexpected header files:
  /usr/local/include/LabJackM.h
  /usr/local/include/chipmunk/chipmunk.h
  /usr/local/include/chipmunk/chipmunk_ffi.h
  /usr/local/include/chipmunk/chipmunk_private.h
  /usr/local/include/chipmunk/chipmunk_structs.h
  /usr/local/include/chipmunk/chipmunk_types.h
  /usr/local/include/chipmunk/chipmunk_unsafe.h
  /usr/local/include/chipmunk/cpArbiter.h
  /usr/local/include/chipmunk/cpBB.h
  /usr/local/include/chipmunk/cpBody.h
  /usr/local/include/chipmunk/cpConstraint.h
  /usr/local/include/chipmunk/cpDampedRotarySpring.h
  /usr/local/include/chipmunk/cpDampedSpring.h
  /usr/local/include/chipmunk/cpGearJoint.h
  /usr/local/include/chipmunk/cpGrooveJoint.h
  /usr/local/include/chipmunk/cpHastySpace.h
  /usr/local/include/chipmunk/cpMarch.h
  /usr/local/include/chipmunk/cpPinJoint.h
  /usr/local/include/chipmunk/cpPivotJoint.h
  /usr/local/include/chipmunk/cpPolyShape.h
  /usr/local/include/chipmunk/cpPolyline.h
  /usr/local/include/chipmunk/cpRatchetJoint.h
  /usr/local/include/chipmunk/cpRobust.h
  /usr/local/include/chipmunk/cpRotaryLimitJoint.h
  /usr/local/include/chipmunk/cpShape.h
  /usr/local/include/chipmunk/cpSimpleMotor.h
  /usr/local/include/chipmunk/cpSlideJoint.h
  /usr/local/include/chipmunk/cpSpace.h
  /usr/local/include/chipmunk/cpSpatialIndex.h
  /usr/local/include/chipmunk/cpTransform.h
  /usr/local/include/chipmunk/cpVect.h
  /usr/local/include/labjackusb.h

Warning: Unbrewed static libraries were found in /usr/local/lib.
If you didn't put them there on purpose they could cause problems when
building Homebrew formulae and may need to be deleted.

Unexpected static libraries:
  /usr/local/lib/libchipmunk.a

Warning: You have unlinked kegs in your Cellar.
Leaving kegs unlinked can lead to build-trouble and cause formulae that depend on
those kegs to fail to run properly once built. Run `brew link` on these:
  pkg-config
@iandol
Copy link
Contributor Author

iandol commented Jul 1, 2024

Note comment #53 (comment) from @SMillerDev seems still relelvant here.

@iandol
Copy link
Contributor Author

iandol commented Jul 1, 2024

Here are the paths for a working vs. non-working font:

image

(share/"fonts").install Dir.glob("./**/JuliaMono-BlackItalic.ttf")[0]
(share/"fonts").install Dir.glob("./**/fonts/ttf/JetBrainsMonoNL-BoldItalic.ttf")[0]

@SMillerDev
Copy link
Member

the main difference is the font-juliamono has no verified

Verified is just metadata, that has nothing to do with this issue. The issue is what is mentioned in the comment:

Casks do not move into the first directory like formula do, so the path is off. Someone will need to adjust the formula generation to drop the first directory from the glob if the name is the same as the current directory.

@iandol
Copy link
Contributor Author

iandol commented Jul 1, 2024

OK, thanks for the confirmation.

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

2 participants