-
Notifications
You must be signed in to change notification settings - Fork 41
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
Update to Psych 4.0.x #134
base: master
Are you sure you want to change the base?
Conversation
Psych.safe_load changed it's method signature and requires keyword args for 'permitted_classes' Update the calls to Psych.safe_load and add it as an explicit gem dependency with a pessimistic lock on the version.
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.
Thanks for providing this gem. We're looking to incorporate it with our pre-push git hooks, but need it to work with the latest versions of Psych and Ruby.
spec.add_development_dependency "rake", "~> 10.0" | ||
spec.add_development_dependency "rspec", "~> 3.0" | ||
spec.add_development_dependency 'rubocop', ">= 0.56" | ||
spec.add_development_dependency 'rubocop-rspec' | ||
spec.add_development_dependency 'simplecov' | ||
spec.add_development_dependency 'sqlite3', "~> 1.3.13" | ||
spec.add_development_dependency 'sqlite3', "~> 1.4.2" |
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.
An earlier version of sqlite was not building on my Mac, this upgrade was to unblock me from running the setup and the tests.
@@ -33,7 +33,7 @@ def read_files(path) | |||
|
|||
paths.map do |file| | |||
metadata, *example_groups = file.read.split("---\n").reject(&:empty?).map do |yaml| | |||
YAML.safe_load(yaml, [Symbol]) | |||
YAML.safe_load(yaml, permitted_classes: [Symbol]) |
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.
This version: YAML.safe_load(yaml, [Symbol])
was deprecated by Psych, then removed in version 4.
See commit here: ruby/psych@0767227#diff-659eac8589abc82c9a0ab3699e4e4be4774d9c09c6c9934af5d9dae0d264439cR322
@pluff or @jaimerson - Any chance this could be reviewed? |
👀 |
The arguments were no longer accepted by the Git gem, updating to fix the method invocation to send a list of arguments (rather than two arguments with the second being an array)
Psych.safe_load changed it's method signature and requires
keyword args for 'permitted_classes'
Update the calls to Psych.safe_load and add it as an explicit
gem dependency with a pessimistic lock on the version.