-
Notifications
You must be signed in to change notification settings - Fork 2.1k
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
use middleware prevents from migrating to ruby 3 #1720
Comments
That should work after #1701 but that change is still unreleased so could you try installing Sinatra from the |
👋 @EduardoSimon did you try to use Sinatra from |
I had the same issue and can confirm that this solution works! Tested with
where |
Context
Hi folks, I am trying to migrate a sinatra app from ruby 2.7 to ruby 3. My tests are failing when using a sinatra middleware like so when passing a keyword argument:
use MyMiddleware, keyword_argument: 'foo'
AFAIK there has been a breaking change regarding keyword arguments, now its mandatory to specify them in the method signature as such:
Possible solution
After reviewing the code it seems like the use method needs a simple signature change, but I don't know how this could impact the library. If the change is that simple and backwards-compatible, are you accepting PRs?
Thanks in advance.
The text was updated successfully, but these errors were encountered: