-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
Call conf.clamp for puma options to convert the default :environment Proc into a String #2413
Call conf.clamp for puma options to convert the default :environment Proc into a String #2413
Conversation
I don't know that I agree it should be the calling codes responsibility to call |
@@ -28,6 +28,7 @@ | |||
options = default_options.merge(options) | |||
|
|||
conf = Rack::Handler::Puma.config(app, options) | |||
conf.options.finalize_values |
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.
I think you can do this instead
conf.options.finalize_values | |
conf.clamp |
See
bfca069
to
43a2b2a
Compare
Thanks @dentarg, you're right! This looks like the public API that we are meant to call. I have updated the PR |
49b0737
to
59de6e0
Compare
59de6e0
to
b21d90d
Compare
Note: I opened a different PR to fix some RuboCop warnings on the master branch: #2417 I've also included that commit in here just to check that the build is also passing for this branch |
Thanks |
Fixed upstream: teamcapybara/capybara#2413
Fixed upstream: teamcapybara/capybara#2413
Hello,
I just saw a deprecation warning when running Puma 5.0.3 in Ruby 2.7:
warning: deprecated Object#=~ is called on Proc
. I initially raised the issue on the puma repo: puma/puma#2455But it turns out that this was a bug in Capybara: puma/puma#2455 (comment)
Capybara was not calling
#finalize_values
to convert default Proc into a string. I've also tried to add a test to confirm that this is fixed, but not sure if it's the best way to test this.