We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
ruby 2.2.3, syck 1.0.4
require 'yaml' require 'syck' require 'safe_yaml' yaml = <<-YAML common: &common adapter: postgresql development: <<: *common YAML SafeYAML::OPTIONS[:default_mode] = :safe YAML.load(yaml) # => {"common"=>{"adapter"=>"postgresql"}, "development"=>{"adapter"=>"postgresql"}}, as expected SafeYAML::OPTIONS[:raise_on_unknown_tag] = true YAML.load(yaml) # RuntimeError: Unknown YAML tag 'tag:yaml.org,2002:merge'
The text was updated successfully, but these errors were encountered:
Oh, and to continue:
SafeYAML::OPTIONS[:whitelisted_tags] = ['tag:yaml.org,2002:merge'] YAML.load(yaml) # => {"common"=>{"adapter"=>"postgresql"}, "development"=>{#<Syck::MergeKey:0x007f89aaa379c0>=>{"adapter"=>"postgresql"}}}
Sorry, something went wrong.
fix merge constructs with safe_yaml
a582434
see dtao/safe_yaml#81 and dtao/safe_yaml#82 test plan: * have a merge construct in your database.yml * canvas should boot Change-Id: Ie5ca4dfac5d9fe4e62ad89474a2eb7d84feae02c Reviewed-on: https://gerrit.instructure.com/69083 Tested-by: Jenkins Reviewed-by: Simon Williams <[email protected]> Product-Review: August Thornton <[email protected]> QA-Review: August Thornton <[email protected]>
No branches or pull requests
ruby 2.2.3, syck 1.0.4
The text was updated successfully, but these errors were encountered: