-
Notifications
You must be signed in to change notification settings - Fork 65
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
Remove Ruby version constraint from the gemspec #76
Comments
IMHO with Ruby 3 just a few months to go, let’s nudge people towards using newer Ruby versions. 🚀 |
Why? Why forcing people to update their well-working scripts, gems, programs would be the way to go? Ruby version requirement should be dictated by the need of the language functionalities, as bundler.io suggests:
So, in my understanding, unless json_schemer specifically needs features that are not present in Ruby 2.4, it shouldn't be specified as a dependency. New applications should indeed be written in the highest Ruby versions possible, but please allow users that already have their use-cases covered to have their application still working without having to upgrade everything just so they can validate their JSON inputs. // EDIT: added linkage and quotation to bundler.io |
@Marahin Alright. Sounds plausible. |
Sounds great!
I originally enforced Ruby 2.5 because 2.4 is EOL and I'd like to use some of the features in 2.5. Would it work for you to pin your dependency on an older version of the gem? I believe 0.2.11 works on Ruby 2.4. In fact, bundler should pick up that version when running on 2.4. |
@davishmcclurg indeed we could pin down to the version before the Ruby 2.5 dependency was introduced, but this way we are giving up on the new features, fixes and changes in your library, such as more precise errors: #1 So while this would indeed allow us to include and use json_schemer, it:
This is a super valid point, but are there any features that json_schemer is making use of right now? If yes, then this indeed discards our request and is a great argument behind setting this dependency up. |
I think you're right that there aren't any. I was thinking of some things I changed when I dropped 2.3.
That's true. I'm open to supporting 2.4 again since it shouldn't require any other changes. How long do you plan to support it? I don't have a good sense for people's expectations on these types of things. Please open a PR with the changes, if you can. |
Merged 2.4 support and released in 0.2.14. |
Hello,
we would love to use this gem to validate JSON payloads on-failure in our gem, jsonapi_parameters. This gem provides a simple way to consume JSON:API compliant inputs in Ruby, with Rails support included. You can read more about the standard here: https://jsonapi.org
Sadly, we are facing an issue where choosing json_schemer as the validation engine would mean that we would have to give up support for Ruby 2.4. While we are aware that this Ruby version has reached its EOL, we would rather not limit our users to specific Ruby versions unless it is required by the gem's logic.
Because of that we are currently seeing three scenarios:
and, the third scenario is: reaching out and asking whether its possible (and if not - what is the reason for this decision) to remove the constraint in json_schemer that enforces Ruby versions above 2.4.0. This is the path that we decided to choose first.
Commit link: 8cbd5cc#diff-6f69d521c8f547072ea493be84d7a52eL23-R23
The text was updated successfully, but these errors were encountered: