spree
spree copied to clipboard
Error loading Doorkeeper v5.6.0
I tried updating Doorkeeper to v5.6.0 (released a week ago), but it seems that a change to their autoloading code breaks this initializer:
/usr/local/lib/ruby/gems/3.1.0/gems/spree_api-4.2.6/config/initializers/doorkeeper.rb:31:in `<main>': uninitialized constant Doorkeeper::AccessGrant
Did you mean? Doorkeeper::AccessGrantMixin (NameError)
from /usr/local/lib/ruby/gems/3.1.0/gems/railties-6.1.7/lib/rails/engine.rb:681:in `block in load_config_initializer'
Downgrading to v5.5.4 works.
Your Environment
- Version used: Spree v4.2.6 and Doorkeeper v5.6.0. I have not tried Spree v4.3 and up.
Hi @zavan - thank you for creating this one! How is the PR that you assigned to it, related to this issue? Was the error caused by lack of permitted classes in the initializer?
@rafalcymerys Hey! Nope, it's my second comment on that PR references this issue actually, the CI there is failing due to this issue here.
since this 5.5.0 release, Doorkeeper has required client authentication which current version of Spree_api doesn't satisfy anymore, so I think we should change this version's gemspec to (~> 5.2, >= 5.2.1, <5.5.0)
( it's (~> 5.2, >= 5.2.1)
currently)
Hey @zavan . Could you please try with
# Gemfile
gem "doorkeeper", github: "doorkeeper-gem/doorkeeper", branch: "fixes/lazy-load-associations"
And report if issue still present?