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

file testset fails unless curl is installed (0.6.0) #22783

Closed
ilia-kats opened this issue Jul 12, 2017 · 5 comments
Closed

file testset fails unless curl is installed (0.6.0) #22783

ilia-kats opened this issue Jul 12, 2017 · 5 comments
Labels
test This change adds or pertains to unit tests

Comments

@ilia-kats
Copy link

In particular, the exact failure is

Test Failed
  Expression: download("ba\0d", "good")
    Expected: ArgumentError
      Thrown: Base.UVError

This boils down to download() choosing wget to download the file. Wget is never run however, since run() throws the ArgumentError. The catch clause (interactiveutil.jl:595) assumes that wget did run, and tries to remove the newly created file, which fails with UVError since the file was not greated due to wget never being executed.

@tkelman
Copy link
Contributor

tkelman commented Jul 12, 2017

thanks for reporting and debugging a bit. throwing a different exception depending on what downloader is used doesn't seem desirable to me. why does wget curl throw an ArgumentError but curl wget doesn't?

@ilia-kats ilia-kats reopened this Jul 13, 2017
@ilia-kats
Copy link
Author

sorry, clicked on the wrong button...
it's the other way around: curl throws ArgumentError, wget doesn't. In both cases, run() throws ArgumentError, but when wget is used that error is caught and the catch clause tries to do some cleanup after wget, where rm() throws the UVError.

@tkelman
Copy link
Contributor

tkelman commented Jul 13, 2017

Ah, gotcha. That seems like an oversight in #21071 then, maybe that rm call should use the force keyword argument?

@ilia-kats
Copy link
Author

probably, yes

@kshyatt kshyatt added the test This change adds or pertains to unit tests label Jul 18, 2017
@KristofferC
Copy link
Sponsor Member

I think this should be fixed with the new ´Downloads` stdlib.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
test This change adds or pertains to unit tests
Projects
None yet
Development

No branches or pull requests

4 participants