Description
recently got error :
in lib/grape-swagger.rb:96:in setup': undefined method
merge!' for nil:NilClass (NoMethodError)
in create_documentation_class:setup
the culprit is line
@last_description.merge!(api_doc)
I don't know what changed, but would it be safer to initialise @last_description to an empty hash
before merging, in case this member is not previously set properly / as expected ?
note : after making some safe guard I got other errors, in mounting API.
But after debugging, it seems that there is ongoing PR that aren't completed around removing Endpoint.settings.
def combine_namespaces(app)
app.endpoints.each do |endpoint|
ns = endpoint.settings.stack.last[:namespace]
where settings is no longer a member of an Endpoint.
So I guess, this is not a grape-swagger issue, but a transient problem around this unfinished PR.
see here : ruby-grape/grape#712 and ruby-grape/grape#719
reverting to Grape 0.9.0 work.
Good luck for the upgrade ;-)