Duplicate OperationIDs
The fork is close to complete, with only one last set of errors popping up:
The endpoints with duplicate OperationIDs are:
/api/v4/groups/{id}/-/search, /api/v4/groups/{id}/search >> getApiV4GroupsIdSearch
/api/v4/projects/{id}/-/search, /api/v4/projects/{id}/search >> getApiV4ProjectsIdSearch
/api/v4/projects/{id}/releases/permalink/latest, /api/v4/projects/{id}/releases/permalink/latest/ >> getApiV4ProjectsIdReleasesPermalinkLatest
/api/v4/projects/{id}/releases/permalink/latest{suffix_path}, /api/v4/projects/{id}/releases/permalink/latest/{suffix_path} >> getApiV4ProjectsIdReleasesPermalinkLatestSuffixPath
The duplicate OperationIDs are partly because of the way Operation IDs are generated by grape-swagger:
def manipulate(path)
operation = path.split('/').map(&:capitalize).join
operation.gsub!(/-(\w)/, &:upcase).delete!('-') if operation[/-(\w)/]
operation.gsub!(/_(\w)/, &:upcase).delete!('_') if operation.include?('_')
operation.gsub!(/\.(\w)/, &:upcase).delete!('.') if operation[/\.(\w)/]
if path.include?('{')
operation.gsub!(/\{(\w)/, &:upcase)
operation.delete!('{').delete!('}')
end
operation
end
The method removes - and / which would have distinguished the operation IDs for the affected endpoints. At the same time, the permalink endpoints have a bit of a strange endpoint output because it uses the optional segments :id/releases/permalink/latest(/)(*suffix_path) - I'm not sure if this is entirely intentional.