Compare commits

...

6 Commits

Author SHA1 Message Date
HoneyryderChuck
1765ddf0f8 fixed test match 2023-05-01 01:19:43 +01:00
HoneyryderChuck
5ad314607d bump version to 0.23.1 2023-05-01 00:45:56 +01:00
HoneyryderChuck
b154d97438 readd error message on failed resolution 2023-05-01 00:45:35 +01:00
HoneyryderChuck
07624e529f Merge branch 'issue-233' into 'master'
Revert "dns errors: raise error immediately on nxdomain error"

Closes #233

See merge request os85/httpx!250
2023-04-30 23:42:24 +00:00
HoneyryderChuck
a772ab42d0 fix for no candidate queries after the first fails. 2023-05-01 00:20:27 +01:00
HoneyryderChuck
b13b0f86eb Revert "dns errors: raise error immediately on nxdomain error"
This reverts commit 04c5b39600e36ebb38884ff9285cdd66d933d70e.
2023-04-29 23:15:46 +01:00
4 changed files with 14 additions and 5 deletions

View File

@ -0,0 +1,5 @@
# 0.23.1
## Bugfixes
* fixed regression causing dns candidate names not being tried after first one fails.

View File

@ -100,7 +100,7 @@ if RUBY_VERSION >= "2.4.0"
verify_spans(transaction, response, verb: "GET") verify_spans(transaction, response, verb: "GET")
crumb = Sentry.get_current_scope.breadcrumbs.peek crumb = Sentry.get_current_scope.breadcrumbs.peek
assert crumb.category == "httpx" assert crumb.category == "httpx"
assert crumb.data == { error: "name or service not known (unexisting)", method: "GET", url: uri.to_s } assert crumb.data == { error: "name or service not known", method: "GET", url: uri.to_s }
end end
private private

View File

@ -244,10 +244,14 @@ module HTTPX
when :no_domain_found when :no_domain_found
# Indicates no such domain was found. # Indicates no such domain was found.
hostname, connection = @queries.first hostname, connection = @queries.first
reset_hostname(hostname) reset_hostname(hostname, reset_candidates: false)
@connections.delete(connection) unless @queries.value?(connection)
raise NativeResolveError.new(connection, connection.origin.host, "name or service not known (#{hostname})") @connections.delete(connection)
raise NativeResolveError.new(connection, connection.origin.host, "name or service not known")
end
resolve
when :message_truncated when :message_truncated
# TODO: what to do if it's already tcp?? # TODO: what to do if it's already tcp??
return if @socket_type == :tcp return if @socket_type == :tcp

View File

@ -1,5 +1,5 @@
# frozen_string_literal: true # frozen_string_literal: true
module HTTPX module HTTPX
VERSION = "0.23.0" VERSION = "0.23.1"
end end