ruby / psych

A libyaml wrapper for Ruby
MIT License
566 stars 207 forks source link

v4 conflicts with sidekiq matchers #514

Closed Paul-Yves closed 3 years ago

Paul-Yves commented 3 years ago

I don't know the internal specifics but upgrading to psych 4 breaks all the sidekiq rspec matchers such as be_delayed. The message is Psych::DisallowedClass: Tried to load unspecified class: Date.

Any one encountered this issue ? Is there a way to deactivate psych new default secure reading on a global scale (in specs) ?

olleolleolle commented 3 years ago

Thanks for asking, this is a change in Psych 4.0, that libraries may need to adapt to.

See for example https://github.com/ruby/psych/issues/503 where the library adapted to the changes: https://github.com/sparklemotion/http-cookie/pull/34/.

Hope these examples help! Perhaps register an Issue in https://github.com/philostler/rspec-sidekiq/issues ?

Paul-Yves commented 3 years ago

Ok, I contacted them to see if they are willing to change it.

olleolleolle commented 3 years ago

@Paul-Yves Thanks, I'll close this issue.