add_swagger_documentation not working with grape >= 1.2.0
darcang opened this issue · comments
Vadim Sitak commented
After introducing this change by Grape https://github.com/ruby-grape/grape/pull/1803/files#diff-f411a5009131db5a6c7242b49ca78488f2d274ef9e5e5f4de9262a42108a5386R8-R13
add_swagger_documentation
raises an error 'NoMethodError: undefined method `endpoints' for module' from https://github.com/ruby-grape/grape-swagger/blob/master/lib/grape-swagger.rb#L154
For some reason, the target_class here is the module instead of a class
peter scholz commented
maybe updating/upgrade your app will help 😉
your referenced grape changes are relatively old and grape-swagger works well together since their introduction, see also CI pipeline results