Unable to serialize as ActiveSupport::HashWithIndifferentAccess anymore

前端 未结 4 1566
無奈伤痛
無奈伤痛 2021-01-18 16:46

For reasons that I\'m so far completely unable to decipher, I\'m no longer able to use ActiveSupport::HashWithIndifferentAccess anymore.

The relevant part of model l

4条回答
  •  一生所求
    2021-01-18 17:26

    1.9.2 normally includes Psych as the YAML library. However, libyaml is an external dependency, and 1.9.2 defaults to using Syck (the old library) if libyaml is not available when Ruby is compiled: link

    The fact that Psych YAML-izes ActiveSupport::HashWithIndifferentAccess as a standard hash is an oustanding issue on Psych's Github. Seems to be fixed in 1.9.3 though.

提交回复
热议问题