-
Notifications
You must be signed in to change notification settings - Fork 73
THREESCALE-15318: Update Faraday dependency for enhanced query parameter handling #4330
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
Changes from 7 commits
b76cdec
ef88e9b
5783363
71d10ba
05be635
c79e8f3
4b520b7
4d8c766
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -43,7 +43,7 @@ gem 'sorted_set', '~> 1.0' | |
| gem 'i18n' | ||
|
|
||
| # Apisonator client | ||
| gem 'pisoni', '~> 1.30' | ||
| gem 'pisoni', '~> 1.31' | ||
|
|
||
| gem '3scale_time_range', '0.0.6' | ||
|
|
||
|
|
@@ -79,8 +79,9 @@ gem 'mysql2', '~> 0.5.3' | |
| gem '3scale_client', '~> 2.11', require: false | ||
| gem 'analytics-ruby', require: false | ||
|
|
||
| gem 'connection_pool', '~> 2.2', '< 3' | ||
| gem 'dalli' | ||
| gem 'faraday', '~> 2.0', '<= 2.9' | ||
| gem 'faraday', '~> 2.0', '>= 2.14.3' | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Shouldn't we limit range to 2.x?
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The |
||
| gem 'mimemagic', '~> 0.3.10' | ||
| gem 'nokogiri', '~> 1.18.9', force_ruby_platform: true | ||
| gem 'secure_headers', '~> 6.3.0' | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -272,7 +272,7 @@ GEM | |
| colorize (0.8.1) | ||
| commonmarker (0.23.10) | ||
| concurrent-ruby (1.3.5) | ||
| connection_pool (2.5.4) | ||
| connection_pool (2.5.5) | ||
| crack (1.0.0) | ||
| bigdecimal | ||
| rexml | ||
|
|
@@ -399,14 +399,15 @@ GEM | |
| factory_bot (~> 6.2.0) | ||
| railties (>= 5.0.0) | ||
| fakefs (1.8.0) | ||
| faraday (2.8.1) | ||
| base64 | ||
| faraday-net_http (>= 2.0, < 3.1) | ||
| ruby2_keywords (>= 0.0.4) | ||
| faraday-net_http (3.0.2) | ||
| faraday-net_http_persistent (2.1.0) | ||
| faraday (2.14.3) | ||
| faraday-net_http (>= 2.0, < 3.5) | ||
| json | ||
| logger | ||
| faraday-net_http (3.4.4) | ||
| net-http (~> 0.5) | ||
| faraday-net_http_persistent (2.3.1) | ||
| faraday (~> 2.5) | ||
| net-http-persistent (~> 4.0) | ||
| net-http-persistent (>= 4.0.4, < 5) | ||
| ffi (1.17.0) | ||
| ffi-compiler (1.0.1) | ||
| ffi (>= 1.0.0) | ||
|
|
@@ -454,7 +455,7 @@ GEM | |
| rails-dom-testing (>= 1, < 3) | ||
| railties (>= 4.2.0) | ||
| thor (>= 0.14, < 2.0) | ||
| json (2.13.2) | ||
| json (2.20.0) | ||
| json_schemer (2.4.0) | ||
| bigdecimal | ||
| hana (~> 1.3) | ||
|
|
@@ -550,9 +551,11 @@ GEM | |
| mutex_m (0.3.0) | ||
| mysql2 (0.5.6) | ||
| n_plus_one_control (0.6.2) | ||
| net-http (0.9.1) | ||
| uri (>= 0.11.1) | ||
| net-http-digest_auth (1.4.1) | ||
| net-http-persistent (4.0.2) | ||
| connection_pool (~> 2.2) | ||
| net-http-persistent (4.0.8) | ||
| connection_pool (>= 2.2.4, < 4) | ||
| net-imap (0.5.7) | ||
| date | ||
| net-protocol | ||
|
|
@@ -597,8 +600,8 @@ GEM | |
| ruby-rc4 | ||
| ttfunk | ||
| pg (1.3.5) | ||
| pisoni (1.30.0) | ||
| faraday (~> 2.0, <= 2.9) | ||
| pisoni (1.31.0) | ||
| faraday (~> 2.0, >= 2.14.3) | ||
| faraday-net_http_persistent (~> 2.1) | ||
| injectedlogger (= 0.0.13) | ||
| json (~> 2.7, >= 2.7.1) | ||
|
|
@@ -973,6 +976,7 @@ GEM | |
| rack | ||
| unicorn | ||
| uniform_notifier (1.17.0) | ||
| uri (1.1.1) | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. You can remove this one and let bundle pick the builtin ruby 3 gem which is |
||
| version_gem (1.1.3) | ||
| webmock (3.24.0) | ||
| addressable (>= 2.8.0) | ||
|
|
@@ -1044,6 +1048,7 @@ DEPENDENCIES | |
| coffee-rails (~> 5.0) | ||
| colorize | ||
| commonmarker (~> 0.23.10) | ||
| connection_pool (~> 2.2, < 3) | ||
| cssbundling-rails (~> 1.4.3) | ||
| cucumber (~> 7.0) | ||
| cucumber-rails (~> 3.0.0) | ||
|
|
@@ -1058,7 +1063,7 @@ DEPENDENCIES | |
| escape_utils | ||
| factory_bot_rails (~> 6.2) | ||
| fakefs | ||
| faraday (~> 2.0, <= 2.9) | ||
| faraday (~> 2.0, >= 2.14.3) | ||
| formtastic (~> 5.0) | ||
| hashie | ||
| hiredis-client | ||
|
|
@@ -1097,7 +1102,7 @@ DEPENDENCIES | |
| open_id_authentication | ||
| pdf-inspector | ||
| pg (~> 1.3.5) | ||
| pisoni (~> 1.30) | ||
| pisoni (~> 1.31) | ||
| prawn | ||
| prawn-svg | ||
| prawn-table! | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -29,7 +29,7 @@ class Proxy < ApplicationRecord # rubocop:disable Metrics/ClassLength | |
|
|
||
| validates :error_status_no_match, :error_status_auth_missing, :error_status_auth_failed, :error_status_limits_exceeded, presence: true | ||
|
|
||
| uri_pattern = URI::DEFAULT_PARSER.pattern | ||
| uri_pattern = URI::RFC2396_Parser.new.pattern | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I faced this same problem in #4325. And this solution doesn't work. The problem is In my PR, what I did it to remove the reference to the Another problem is the As you may see, the issue is bigger than expected and deservers its own Jira ticket for investigation and careful testing. For this pr, just don't touch the uri gem.
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Makes sense. But I'd add the dependency with a comment to Also is there any reason not to use the newer RFC parser? We can in general switch the default back too as evident in the issue you linked to URI.parser = URI::RFC2396_PARSER
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I think it's not gonna be so easy.
This wouldn't work if we are mentioning
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I already said that I agree that a separate JIRA is needed. The question was whether we actually need the old parser or is it just how it worked for a long time so we don't want to fix it as it ain't broken. The |
||
|
|
||
| URI_OR_LOCALHOST = /\A(https?:\/\/([a-zA-Z0-9._:\/?-])+|.*localhost.*)\Z/ | ||
| OPTIONAL_QUERY_FORMAT = "(?:\\?(#{uri_pattern.fetch(:QUERY)}))?" | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What if you just remove this and leave the reference to
connection_poolun the lockfile untouched? I don't like the idea of adding dependencies to our Gemfile when they are not our dependenciesThere was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Then the next
bundle installmay bring it back. I'd rather put a comment unless you give me a better alternative.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fine for me