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

ASCII download tests fail with libcurl error #78 - all platforms #113

Open
mjram0s opened this issue Jul 19, 2021 · 5 comments
Open

ASCII download tests fail with libcurl error #78 - all platforms #113

mjram0s opened this issue Jul 19, 2021 · 5 comments

Comments

@mjram0s
Copy link
Member

mjram0s commented Jul 19, 2021

binary_ascii: Error During Test at /home/runner/work/FTPClient.jl/FTPClient.jl/test/non_ssl.jl:205
  Got exception outside of a @test
   :: LibCURL error #78
  Stacktrace:
    [1] macro expansion
      @ ~/work/FTPClient.jl/FTPClient.jl/src/FTPC.jl:62 [inlined]
    [2] ftp_perform(ctxt::ConnContext{Bool})
      @ FTPClient ~/work/FTPClient.jl/FTPClient.jl/src/conn_context.jl:298
    [3] ftp_get(ctxt::ConnContext{Bool}, file_name::String, save_path::String; mode::FTP_MODE)
      @ FTPClient ~/work/FTPClient.jl/FTPClient.jl/src/conn_context.jl:152
    [4] ftp_get(options::RequestOptions, file_name::String, save_path::String; mode::FTP_MODE, verbose::Bool)
      @ FTPClient ~/work/FTPClient.jl/FTPClient.jl/src/request_options.jl:114
    [5] macro expansion
      @ ~/work/FTPClient.jl/FTPClient.jl/test/non_ssl.jl:231 [inlined]
    [6] macro expansion
      @ /buildworker/worker/package_linux64/build/usr/share/julia/stdlib/v1.6/Test/src/Test.jl:1151 [inlined]
    [7] top-level scope
      @ ~/work/FTPClient.jl/FTPClient.jl/test/non_ssl.jl:207
    [8] include(fname::String)
      @ Base.MainInclude ./client.jl:444
    [9] macro expansion
      @ ~/work/FTPClient.jl/FTPClient.jl/test/runtests.jl:41 [inlined]
   [10] macro expansion
      @ /buildworker/worker/package_linux64/build/usr/share/julia/stdlib/v1.6/Test/src/Test.jl:1151 [inlined]
   [11] macro expansion
      @ ~/work/FTPClient.jl/FTPClient.jl/test/runtests.jl:40 [inlined]
   [12] macro expansion
      @ /buildworker/worker/package_linux64/build/usr/share/julia/stdlib/v1.6/Test/src/Test.jl:1151 [inlined]
   [13] top-level scope
      @ ~/work/FTPClient.jl/FTPClient.jl/test/runtests.jl:29
   [14] include(fname::String)
      @ Base.MainInclude ./client.jl:444
   [15] top-level scope
      @ none:6
   [16] eval
      @ ./boot.jl:360 [inlined]
   [17] exec_options(opts::Base.JLOptions)
      @ Base ./client.jl:261
   [18] _start()
      @ Base ./client.jl:485
@morris25
Copy link
Member

morris25 commented Aug 19, 2021

The problem behind this is that the FTP get function is failing when using ASCII mode. This happens whether we use CURLOPT_TRANSFERTEXT or @ce_curl curl_easy_setopt CURLOPT_URL full_url * ";type=a" to set the mode.

I think the problem may be in LibCURL_jll v7.73.0+0. The issue does not appear to be happening in julia 1.5 which can only use up to v7.70.0+2. I haven't been able to verify though.

Doing some digging it appears to be related to this curl/curl#6564. FTPServer.jl uses pyftpdlib which does not support SIZE for ASCII transfers. I'm not sure how the error is being triggered.

Verbose output from failing call:

*   Trying ::1:52090...
* Connected to localhost (::1) port 52090 (#0)
< 220 pyftpdlib 1.5.6 ready.
> USER user4252
< 331 Username ok, send password.
> PASS <password>
< 230 Login successful.
> PWD
< 257 "/" is the current directory.
* Entry path is '/'
* Request has same path as previous transfer
> EPSV
* Connect data stream passively
* ftp_perform ends with SECONDARY: 0
< 229 Entering extended passive mode (|||52093|).
*   Trying ::1:52093...
* Connecting to ::1 (::1) port 52093
* Connected to localhost (::1) port 52090 (#0)
> TYPE A
< 200 Type set to: ASCII.
> SIZE test_byte_file
< 550 SIZE not allowed in ASCII mode.
* The file does not exist
* Remembering we are in dir ""
* Connection #0 to host localhost left intact

@morris25 morris25 changed the title libcurl error #78 - all platforms ASCII download tests fail with libcurl error #78 - all platforms Aug 20, 2021
@morris25
Copy link
Member

I will silence the tests with the @test_skip macro for now since it isn't a high priority. If we need to fix this in future we could find a different FTP test server implementation or figure out how to avoid checking the size when performing an ASCII download.

@jo-fleck
Copy link

Has this ever been fixed? I am still receiving this error when testing on > Julia 1.5

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

4 participants