homebrew-cask: FileZilla Client cask install fails (3.37.0)

General troubleshooting steps

Description of issue

FileZilla Client cask installation fails (3.37.0) with HTTP Status: 416

Removing --continue-at - from the curl command that executed seems to have succeeded the installation.

This fails

/usr/bin/curl -q --show-error --user-agent Homebrew/1.7.5-11-g47bebcd\ \(Macintosh\;\ Intel\ Mac\ OS\ X\ 10.13.6\)\ curl/7.54.0 --fail --location --remote-time --continue-at - --output /Users/slx/Library/Caches/Homebrew/downloads/0c8955f33cd033e0f9d95957818649ce3abf2fcf5c4bfc8ffef2a4c54920a812--FileZilla_3.37.0_macosx-x86.app.tar.bz2.incomplete https://download.filezilla-project.org/client/FileZilla_3.37.0_macosx-x86.app.tar.bz2

This successfully downloads

/usr/bin/curl -q --show-error --user-agent Homebrew/1.7.5-11-g47bebcd\ \(Macintosh\;\ Intel\ Mac\ OS\ X\ 10.13.6\)\ curl/7.54.0 --fail --location --remote-time --output /Users/slx/Library/Caches/Homebrew/downloads/0c8955f33cd033e0f9d95957818649ce3abf2fcf5c4bfc8ffef2a4c54920a812--FileZilla_3.37.0_macosx-x86.app.tar.bz2.incomplete https://download.filezilla-project.org/client/FileZilla_3.37.0_macosx-x86.app.tar.bz2

Command that failed

brew cask reinstall filezilla

Output of command with --force --verbose --debug

==> Cask::Installer#reinstall
==> Cask::Installer#install
==> Printing caveats
==> Cask::Installer#fetch
==> Satisfying dependencies
==> Downloading
==> Downloading https://download.filezilla-project.org/client/FileZilla_3.37.0_macosx-x86.app.tar.bz2
/usr/bin/curl -q --show-error --user-agent Homebrew/1.7.5-11-g47bebcd\ \(Macintosh\;\ Intel\ Mac\ OS\ X\ 10.13.6\)\ curl/7.54.0 --location --silent --head https://download.filezilla-project.org/client/FileZilla_3.37.0_macosx-x86.app.tar.bz2
/usr/bin/curl -q --show-error --user-agent Homebrew/1.7.5-11-g47bebcd\ \(Macintosh\;\ Intel\ Mac\ OS\ X\ 10.13.6\)\ curl/7.54.0 --location --silent --head https://download.filezilla-project.org/client/FileZilla_3.37.0_macosx-x86.app.tar.bz2
/usr/bin/curl -q --show-error --user-agent Homebrew/1.7.5-11-g47bebcd\ \(Macintosh\;\ Intel\ Mac\ OS\ X\ 10.13.6\)\ curl/7.54.0 --location --head --range 0-1 --write-out \%\{http_code\} --output /dev/null https://download.filezilla-project.org/client/FileZilla_3.37.0_macosx-x86.app.tar.bz2
/usr/bin/curl -q --show-error --user-agent Homebrew/1.7.5-11-g47bebcd\ \(Macintosh\;\ Intel\ Mac\ OS\ X\ 10.13.6\)\ curl/7.54.0 --fail --location --remote-time --continue-at - --output /Users/slx/Library/Caches/Homebrew/downloads/0c8955f33cd033e0f9d95957818649ce3abf2fcf5c4bfc8ffef2a4c54920a812--FileZilla_3.37.0_macosx-x86.app.tar.bz2.incomplete https://download.filezilla-project.org/client/FileZilla_3.37.0_macosx-x86.app.tar.bz2
** Resuming transfer from byte position 10621590
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
curl: (22) The requested URL returned error: 416
Error: Download failed on Cask 'filezilla' with message: Download failed: https://download.filezilla-project.org/client/FileZilla_3.37.0_macosx-x86.app.tar.bz2
/usr/local/Homebrew/Library/Homebrew/download_strategy.rb:295:in `rescue in fetch'
/usr/local/Homebrew/Library/Homebrew/download_strategy.rb:290:in `fetch'
/usr/local/Homebrew/Library/Homebrew/cask/download.rb:40:in `fetch'
/usr/local/Homebrew/Library/Homebrew/cask/download.rb:18:in `perform'
/usr/local/Homebrew/Library/Homebrew/cask/installer.rb:146:in `download'
/usr/local/Homebrew/Library/Homebrew/cask/installer.rb:62:in `fetch'
/usr/local/Homebrew/Library/Homebrew/cask/installer.rb:90:in `install'
/usr/local/Homebrew/Library/Homebrew/cask/installer.rb:124:in `reinstall'
/usr/local/Homebrew/Library/Homebrew/cask/cmd/reinstall.rb:11:in `block in run'
/usr/local/Homebrew/Library/Homebrew/cask/cmd/reinstall.rb:5:in `each'
/usr/local/Homebrew/Library/Homebrew/cask/cmd/reinstall.rb:5:in `run'
/usr/local/Homebrew/Library/Homebrew/cask/cmd/abstract_command.rb:34:in `run'
/usr/local/Homebrew/Library/Homebrew/cask/cmd.rb:89:in `run_command'
/usr/local/Homebrew/Library/Homebrew/cask/cmd.rb:155:in `run'
/usr/local/Homebrew/Library/Homebrew/cask/cmd.rb:120:in `run'
/usr/local/Homebrew/Library/Homebrew/cmd/cask.rb:7:in `cask'
/usr/local/Homebrew/Library/Homebrew/brew.rb:89:in `<main>'
Error: Kernel.exit
/usr/local/Homebrew/Library/Homebrew/cask/cmd.rb:160:in `exit'
/usr/local/Homebrew/Library/Homebrew/cask/cmd.rb:160:in `rescue in run'
/usr/local/Homebrew/Library/Homebrew/cask/cmd.rb:143:in `run'
/usr/local/Homebrew/Library/Homebrew/cask/cmd.rb:120:in `run'
/usr/local/Homebrew/Library/Homebrew/cmd/cask.rb:7:in `cask'
/usr/local/Homebrew/Library/Homebrew/brew.rb:89:in `<main>'

Output of brew cask doctor

==> Homebrew Version
1.7.5-11-g47bebcd
==> macOS
10.13.6
==> SIP
Disabled
==> Java
1.8.0_60
==> Gatekeeper support
Enabled
==> Homebrew Cask Install Location
<NONE>
==> Homebrew Cask Staging Location
/usr/local/Caskroom
==> Homebrew Cask Taps:
/usr/local/Homebrew/Library/Taps/homebrew/homebrew-cask (4041 casks)
/usr/local/Homebrew/Library/Taps/homebrew/homebrew-cask-versions (195 casks)
==> Contents of $LOAD_PATH
/usr/local/Homebrew/Library/Homebrew/vendor/bundle-standalone/bundler/../ruby/2.3.0/gems/ruby-macho-2.0.0/lib
/usr/local/Homebrew/Library/Homebrew/vendor/bundle-standalone/bundler/../ruby/2.3.0/gems/plist-3.4.0/lib
/usr/local/Homebrew/Library/Homebrew/vendor/bundle-standalone/bundler/
/usr/local/Homebrew/Library/Homebrew/vendor/bundle-standalone/bundler/../ruby/2.3.0/gems/backports-3.11.4/lib
/usr/local/Homebrew/Library/Homebrew/vendor/bundle-standalone/bundler/../ruby/2.3.0/gems/activesupport-5.2.1/lib
/usr/local/Homebrew/Library/Homebrew/vendor/bundle-standalone/bundler/../ruby/2.3.0/gems/tzinfo-1.2.5/lib
/usr/local/Homebrew/Library/Homebrew/vendor/bundle-standalone/bundler/../ruby/2.3.0/gems/thread_safe-0.3.6/lib
/usr/local/Homebrew/Library/Homebrew/vendor/bundle-standalone/bundler/../ruby/2.3.0/gems/minitest-5.11.3/lib
/usr/local/Homebrew/Library/Homebrew/vendor/bundle-standalone/bundler/../ruby/2.3.0/gems/i18n-1.1.0/lib
/usr/local/Homebrew/Library/Homebrew/vendor/bundle-standalone/bundler/../ruby/2.3.0/gems/concurrent-ruby-1.0.5/lib
/Library/Ruby/Gems/2.3.0/gems/did_you_mean-1.0.0/lib
/Library/Ruby/Site/2.3.0
/Library/Ruby/Site/2.3.0/x86_64-darwin17
/Library/Ruby/Site/2.3.0/universal-darwin17
/Library/Ruby/Site
/System/Library/Frameworks/Ruby.framework/Versions/2.3/usr/lib/ruby/vendor_ruby/2.3.0
/System/Library/Frameworks/Ruby.framework/Versions/2.3/usr/lib/ruby/vendor_ruby/2.3.0/x86_64-darwin17
/System/Library/Frameworks/Ruby.framework/Versions/2.3/usr/lib/ruby/vendor_ruby/2.3.0/universal-darwin17
/System/Library/Frameworks/Ruby.framework/Versions/2.3/usr/lib/ruby/vendor_ruby
/System/Library/Frameworks/Ruby.framework/Versions/2.3/usr/lib/ruby/2.3.0
/System/Library/Frameworks/Ruby.framework/Versions/2.3/usr/lib/ruby/2.3.0/x86_64-darwin17
/System/Library/Frameworks/Ruby.framework/Versions/2.3/usr/lib/ruby/2.3.0/universal-darwin17
/usr/local/Homebrew/Library/Homebrew
==> Environment Variables
LC_ALL="en_US.UTF-8"
PATH="/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/Homebrew/Library/Homebrew/shims/scm"
SHELL="/bin/bash"

Output of brew tap

heroku/brew
homebrew/cask
homebrew/cask-versions
homebrew/completions
homebrew/core
homebrew/fuse
homebrew/php
homebrew/science
homebrew/services
jenv/jenv
jonof/kenutils

About this issue

  • Original URL
  • State: closed
  • Created 6 years ago
  • Reactions: 2
  • Comments: 25 (8 by maintainers)

Most upvoted comments

I encountered the same problem while upgrading FileZilla to 3.37.1 over a really limited mobile connection. After the first discontinuity upgrading failed with curl: (22) The requested URL returned error: 416.

After removing the temporary download file in ~/Library/Caches/Homebrew/downloads/${HASH}--FileZilla_3.37.1_macosx-x86.app.tar.bz2.incomplete I was able to upgrade FileZilla over a fast internet connection without any problems.

So for me it seems, that the web server serving https://download.filezilla-project.org/ is either not supporting a resumption or home-brew is calculation the restart position for the resumption wrongly ?!

Deleting the incomplete file below and reinstalling seems to have started the download. But at the end faced another issue.

Incomplete File:

/Users/slx/Library/Caches/Homebrew/downloads/0c8955f33cd033e0f9d95957818649ce3abf2fcf5c4bfc8ffef2a4c54920a812--FileZilla_3.37.0_macosx-x86.app.tar.bz2.incomplete

Error Log

→ brew cask reinstall filezilla --verbose --force --debug
==> Cask::Installer#reinstall
==> Cask::Installer#install
==> Printing caveats
==> Cask::Installer#fetch
==> Satisfying dependencies
==> Downloading
==> Downloading https://download.filezilla-project.org/client/FileZilla_3.37.0_macosx-x86.app.tar.bz2
/usr/bin/curl -q --show-error --user-agent Homebrew/1.7.5-11-g47bebcd\ \(Macintosh\;\ Intel\ Mac\ OS\ X\ 10.13.6\)\ curl/7.54.0 --location --silent --head https://download.filezilla-project.org/client/FileZilla_3.37.0_macosx-x86.app.tar.bz2
/usr/bin/curl -q --show-error --user-agent Homebrew/1.7.5-11-g47bebcd\ \(Macintosh\;\ Intel\ Mac\ OS\ X\ 10.13.6\)\ curl/7.54.0 --location --silent --head https://download.filezilla-project.org/client/FileZilla_3.37.0_macosx-x86.app.tar.bz2
/usr/bin/curl -q --show-error --user-agent Homebrew/1.7.5-11-g47bebcd\ \(Macintosh\;\ Intel\ Mac\ OS\ X\ 10.13.6\)\ curl/7.54.0 --fail --location --remote-time --continue-at 0 --output /Users/slx/Library/Caches/Homebrew/downloads/0c8955f33cd033e0f9d95957818649ce3abf2fcf5c4bfc8ffef2a4c54920a812--FileZilla_3.37.0_macosx-x86.app.tar.bz2.incomplete https://download.filezilla-project.org/client/FileZilla_3.37.0_macosx-x86.app.tar.bz2
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100 10.1M  100 10.1M    0     0  72471      0  0:02:26  0:02:26 --:--:-- 61491
curl: (16) Error in the HTTP2 framing layer
Error: Download failed on Cask 'filezilla' with message: Download failed: https://download.filezilla-project.org/client/FileZilla_3.37.0_macosx-x86.app.tar.bz2
/usr/local/Homebrew/Library/Homebrew/download_strategy.rb:295:in `rescue in fetch'
/usr/local/Homebrew/Library/Homebrew/download_strategy.rb:290:in `fetch'
/usr/local/Homebrew/Library/Homebrew/cask/download.rb:40:in `fetch'
/usr/local/Homebrew/Library/Homebrew/cask/download.rb:18:in `perform'
/usr/local/Homebrew/Library/Homebrew/cask/installer.rb:146:in `download'
/usr/local/Homebrew/Library/Homebrew/cask/installer.rb:62:in `fetch'
/usr/local/Homebrew/Library/Homebrew/cask/installer.rb:90:in `install'
/usr/local/Homebrew/Library/Homebrew/cask/installer.rb:124:in `reinstall'
/usr/local/Homebrew/Library/Homebrew/cask/cmd/reinstall.rb:11:in `block in run'
/usr/local/Homebrew/Library/Homebrew/cask/cmd/reinstall.rb:5:in `each'
/usr/local/Homebrew/Library/Homebrew/cask/cmd/reinstall.rb:5:in `run'
/usr/local/Homebrew/Library/Homebrew/cask/cmd/abstract_command.rb:34:in `run'
/usr/local/Homebrew/Library/Homebrew/cask/cmd.rb:89:in `run_command'
/usr/local/Homebrew/Library/Homebrew/cask/cmd.rb:155:in `run'
/usr/local/Homebrew/Library/Homebrew/cask/cmd.rb:120:in `run'
/usr/local/Homebrew/Library/Homebrew/cmd/cask.rb:7:in `cask'
/usr/local/Homebrew/Library/Homebrew/brew.rb:89:in `<main>'
Error: Kernel.exit
/usr/local/Homebrew/Library/Homebrew/cask/cmd.rb:160:in `exit'
/usr/local/Homebrew/Library/Homebrew/cask/cmd.rb:160:in `rescue in run'
/usr/local/Homebrew/Library/Homebrew/cask/cmd.rb:143:in `run'
/usr/local/Homebrew/Library/Homebrew/cask/cmd.rb:120:in `run'
/usr/local/Homebrew/Library/Homebrew/cmd/cask.rb:7:in `cask'
/usr/local/Homebrew/Library/Homebrew/brew.rb:89:in `<main>'

Curl:

→ curl --version
curl 7.54.0 (x86_64-apple-darwin17.0) libcurl/7.54.0 LibreSSL/2.0.20 zlib/1.2.11 nghttp2/1.24.0
Protocols: dict file ftp ftps gopher http https imap imaps ldap ldaps pop3 pop3s rtsp smb smbs smtp smtps telnet tftp
Features: AsynchDNS IPv6 Largefile GSS-API Kerberos SPNEGO NTLM NTLM_WB SSL libz HTTP2 UnixSockets HTTPS-proxy

Came across this issue trying to force FileZilla to upgrade properly, and…

Seems my current curl version is not stable when handling http2 frame layers. I suggest just to clean imcompleted download file and do more retries against networking issues.

might be a good clue. The version of curl installed with Mojave:

curl 7.54.0 (x86_64-apple-darwin18.0) libcurl/7.54.0 LibreSSL/2.6.4 zlib/1.2.11 nghttp2/1.24.1
Protocols: dict file ftp ftps gopher http https imap imaps ldap ldaps pop3 pop3s rtsp smb smbs smtp smtps telnet tftp
Features: AsynchDNS IPv6 Largefile GSS-API Kerberos SPNEGO NTLM NTLM_WB SSL libz HTTP2 UnixSockets HTTPS-proxy

Grabbing the version of curl from Homebrew, and manually dropping a link in /usr/bin/local (for some reason installing curl didn’t do it?):

curl 7.61.1 (x86_64-apple-darwin18.0.0) libcurl/7.61.1 SecureTransport zlib/1.2.11
Release-Date: 2018-09-05
Protocols: dict file ftp ftps gopher http https imap imaps ldap ldaps pop3 pop3s rtsp smb smbs smtp smtps telnet tftp
Features: AsynchDNS IPv6 Largefile NTLM NTLM_WB SSL libz UnixSockets

Tried force installing FileZilla, aborting it part way, then attempted install again and was successful despite having an incomplete file stored. The version of curl from brew doesn’t have http2 compiled into it…

Output from terminal:

advicepyro@Macky-McMackface-Sr:~/Library/Caches/Homebrew/downloads$ brew cask install filezilla --force
==> Satisfying dependencies
==> Downloading https://download.filezilla-project.org/client/FileZilla_3.37.4_macosx-x86.app.tar.bz2
#######                                                                   10.4%^C
advicepyro@Macky-McMackface-Sr:~/Library/Caches/Homebrew/downloads$ ls -lah
total 712432
drwxr-xr-x  32 advicepyro  staff   1.0K 10 Oct 10:50 .
drwxr-xr-t  28 advicepyro  staff   896B 10 Oct 10:45 ..
-rw-r--r--@  1 advicepyro  staff    21M 10 Sep 23:29 

(omitted extra files...)
-rw-r--r--   1 advicepyro  staff   1.2M 10 Oct 10:50 4751d257d12ebd67ecff5e3a69b4f4dd62a81f638dbc1a08bd1f2b3f743ea219--FileZilla_3.37.4_macosx-x86.app.tar.bz2.incomplete

advicepyro@Macky-McMackface-Sr:~/Library/Caches/Homebrew/downloads$ brew cask install filezilla --force
==> Satisfying dependencies
==> Downloading https://download.filezilla-project.org/client/FileZilla_3.37.4_macosx-x86.app.tar.bz2
######################################################################## 100.0%
==> Verifying SHA-256 checksum for Cask 'filezilla'.
==> Installing Cask filezilla
Warning: It seems there is already an App at '/Applications/FileZilla.app'; overwriting.
==> Removing App '/Applications/FileZilla.app'.
==> Moving App 'FileZilla.app' to '/Applications/FileZilla.app'.
🍺  filezilla was successfully installed!

Temporal workground

https://github.com/Homebrew/brew/blob/master/Library/Homebrew/utils/curl.rb#L55

from

               curl_output("--location", "--head", "--range", "0-1",

to

               curl_output("--location", "--head", #"--range", "0-1",

Greetings

@blue-devil The missing pice was that you first need to remove/uninstall the existing installation. Just running install/reinstall does not work. Plus I never said that your solution is wrong. I just stated that your solution was not working for me.

Not sure if this comment gets deleted but to fix the problem to update FileZilla (I had it already installed) I executed the following steps:

  1. brew cask remove filezilla
  2. rm -Rf ~/Library/Caches/Homebrew/downloads/*
  3. brew cask install filezilla

For some reason just deleting the content of the downloads folder and doing a brew cask reinstall filezilla did not work (Not sure if the cask has some special rules around reinstall vs normal install?). Thought I share my findings maybe this helps others with this issue.

Clearly this issue affects only a subset of users. This cask has nothing different from the others that would warrant it, so it’s either a specific issues with some setup you have in common, or something to do with their server. Someone should try to install without HBC, using curl directly, or the website, to see it it happens, and contact FileZilla if it does.

As it is this issue is just a repetition of the same problem, which doesn’t help in getting closer to a fix.

Since this doesn’t happen to any maintainer and we have no way to reproduce, I’m closing. You’re free to continue the discussion in this issue and try to find/coordinate a fix. If it’s something that can be fixed on our side, please submit a PR or detailed instructions on how to reproduce the issue.

If we keep getting comments with the same duplicate output and going in circles, I’ll delete those. If they still continue, I’ll lock the issue.

Thank you all who commented so far.