hashie/hashie

`Psych::BadAlias` after bumping hashie to 3.6.0

arekt opened this issue · 3 comments

arekt commented

Still investigating where is the problem: in the Hashie, our App or Psych but we started getting this today in our CI errors:

Gem Load Error is: Unknown alias: base_accounts
Backtrace for gem load error is:
/home/rof/.rvm/rubies/ruby-2.3.1/lib/ruby/2.3.0/psych/visitors/to_ruby.rb:402:in `visit_Psych_Nodes_Alias'
/home/rof/.rvm/rubies/ruby-2.3.1/lib/ruby/2.3.0/psych/visitors/visitor.rb:16:in `visit'
/home/rof/.rvm/rubies/ruby-2.3.1/lib/ruby/2.3.0/psych/visitors/visitor.rb:6:in `accept'
/home/rof/.rvm/rubies/ruby-2.3.1/lib/ruby/2.3.0/psych/visitors/to_ruby.rb:32:in `accept'
/home/rof/.rvm/rubies/ruby-2.3.1/lib/ruby/2.3.0/psych/visitors/to_ruby.rb:338:in `block in revive_hash'
/home/rof/.rvm/rubies/ruby-2.3.1/lib/ruby/2.3.0/psych/visitors/to_ruby.rb:336:in `each'
/home/rof/.rvm/rubies/ruby-2.3.1/lib/ruby/2.3.0/psych/visitors/to_ruby.rb:336:in `each_slice'
/home/rof/.rvm/rubies/ruby-2.3.1/lib/ruby/2.3.0/psych/visitors/to_ruby.rb:336:in `revive_hash'
...
...
...
Caused by:
Psych::BadAlias: Unknown alias: base_accounts
/home/rof/cache/bundler/ruby/2.3.0/gems/hashie-3.6.0/lib/hashie/extensions/parsers/yaml_erb_parser.rb:17:in `perform'
/home/rof/cache/bundler/ruby/2.3.0/gems/hashie-3.6.0/lib/hashie/extensions/parsers/yaml_erb_parser.rb:21:in `perform'
/home/rof/cache/bundler/ruby/2.3.0/gems/hashie-3.6.0/lib/hashie/mash.rb:105:in `load'

base_accounts is an alias to in the yaml file

Might be related to ruby/psych#307

Hmm, that's an odd one. I'm happy to help, but could you please share the Yaml file that's failing (sanitized, of course) or, better yet, a failing test?

arekt commented

Added spec to reproduce problem #459, it works if you cherry pick on the top of v3.5.7

closed via #474