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

Parallel request failures don't include url in error message #6199

Closed
Earnestly opened this issue Nov 12, 2020 · 2 comments
Closed

Parallel request failures don't include url in error message #6199

Earnestly opened this issue Nov 12, 2020 · 2 comments
Labels

Comments

@Earnestly
Copy link

@Earnestly Earnestly commented Nov 12, 2020

  • Linux 5.9.0

When making use of the new parallel feature it it appears that any request failures don't include the url from which the error came from. For example I have seen the following:

curl: (92) HTTP/2 stream 0 was not closed cleanly: INTERNAL_ERROR (err 2)
curl: (92) HTTP/2 stream 0 was not closed cleanly: INTERNAL_ERROR (err 2)
curl: (22) The requested URL returned error: 502 
curl: (22) The requested URL returned error: 502 
curl: (22) The requested URL returned error: 502 
curl: (22) The requested URL returned error: 502 
curl: (22) The requested URL returned error: 502 
curl: (22) The requested URL returned error: 502 
curl: (22) The requested URL returned error: 502 
curl: (22) The requested URL returned error: 502 
curl: (22) The requested URL returned error: 502 

Due to the lack of a url in the message itself, it's hard to know where these errors are from to take any corrective action.

curl version

curl 7.74.0-DEV (x86_64-pc-linux-gnu) libcurl/7.74.0-DEV OpenSSL/1.1.1h zlib/1.2.11 zstd/1.4.5 libidn2/2.3.0 libpsl/0.21.1 (+libidn2/2.3.0) nghttp2/1.41.0 librtmp/2.3
Release-Date: [unreleased]
Protocols: dict file ftp ftps gopher http https imap imaps mqtt pop3 pop3s rtmp rtsp smb smbs smtp smtps telnet tftp 
Features: alt-svc AsynchDNS GSS-API HTTP2 HTTPS-proxy IDN IPv6 Kerberos Largefile libz NTLM NTLM_WB PSL SPNEGO SSL TLS-SRP UnixSockets zstd
@bagder bagder added the cmdline tool label Nov 12, 2020
@bagder
Copy link
Member

@bagder bagder commented Nov 12, 2020

... and even with a URL shown it could be hard to tell if you for example use the same URL multiple times and only one or some of them fail! Maybe it should then also refer to which number of the URL it was?

@Earnestly
Copy link
Author

@Earnestly Earnestly commented Nov 12, 2020

I hadn't thought of that scenario as my use cases have always used unique urls. Perhaps the idea of indexing them can work as curl already has the notion of position dependent urls and options on the command-line.

bagder added a commit that referenced this issue Nov 15, 2020
Primarily to help the user understand which error message goes with
which URL when multiple URLs have been provided.

Reported-by: Earnestly on github
Fixes #6199
bagder added a commit that referenced this issue Nov 20, 2020
In particular, these ones can help a user to create its own error
message when one or transfers fail.

writeout: add 'onerror', 'url', 'urlnum', 'exitcode', 'errormsg'

onerror - lets a user only show the rest on non-zero exit codes

url - the input URL used for this transfer

urlnum - the numerical URL counter (0 indexed) for this transfer

exitcode - the numerical exit code for the transfer

errormsg - obvious

Reported-by: Earnestly on github
Fixes #6199
bagder added a commit that referenced this issue Nov 28, 2020
In particular, these ones can help a user to create its own error
message when one or transfers fail.

writeout: add 'onerror', 'url', 'urlnum', 'exitcode', 'errormsg'

onerror - lets a user only show the rest on non-zero exit codes

url - the input URL used for this transfer

urlnum - the numerical URL counter (0 indexed) for this transfer

exitcode - the numerical exit code for the transfer

errormsg - obvious

Reported-by: Earnestly on github
Fixes #6199
Closes #6207
bagder added a commit that referenced this issue Dec 14, 2020
In particular, these ones can help a user to create its own error
message when one or transfers fail.

writeout: add 'onerror', 'url', 'urlnum', 'exitcode', 'errormsg'

onerror - lets a user only show the rest on non-zero exit codes

url - the input URL used for this transfer

urlnum - the numerical URL counter (0 indexed) for this transfer

exitcode - the numerical exit code for the transfer

errormsg - obvious

Reported-by: Earnestly on github
Fixes #6199
Closes #6207
bagder added a commit that referenced this issue Dec 20, 2020
In particular, these ones can help a user to create its own error
message when one or transfers fail.

writeout: add 'onerror', 'url', 'urlnum', 'exitcode', 'errormsg'

onerror - lets a user only show the rest on non-zero exit codes

url - the input URL used for this transfer

urlnum - the numerical URL counter (0 indexed) for this transfer

exitcode - the numerical exit code for the transfer

errormsg - obvious

Reported-by: Earnestly on github
Fixes #6199
Closes #6207
bagder added a commit that referenced this issue Dec 21, 2020
In particular, these ones can help a user to create its own error
message when one or transfers fail.

writeout: add 'onerror', 'url', 'urlnum', 'exitcode', 'errormsg'

onerror - lets a user only show the rest on non-zero exit codes

url - the input URL used for this transfer

urlnum - the numerical URL counter (0 indexed) for this transfer

exitcode - the numerical exit code for the transfer

errormsg - obvious

Reported-by: Earnestly on github
Fixes #6199
Closes #6207
@bagder bagder closed this in 7a90ddf Dec 21, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

2 participants