Skip to content
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

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open

Conversation

marksiemers
Copy link

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.

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.
Copy link
Author

@marksiemers marksiemers left a 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"
Copy link
Author

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])
Copy link
Author

@marksiemers marksiemers Jan 9, 2022

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

@marksiemers
Copy link
Author

@pluff or @jaimerson - Any chance this could be reviewed?

@mculp
Copy link

mculp commented Dec 17, 2022

👀

@kml kml changed the title [#123] Update to Psych 4.0.x Update to Psych 4.0.x Jan 17, 2023
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)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants