Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Warnings in management-api documentation lead to incorrectly generated clients #4115

Closed
jhauckisst opened this issue Apr 16, 2024 · 4 comments
Labels
documentation Improvements or additions to documentation stale Open for x days with no activity triage all new issues awaiting classification

Comments

@jhauckisst
Copy link

Bug Report

Describe the Bug

Warnings:

  • Unused model: JsonArray
  • Unused model: JsonValue
  • Unused model: JsonObject

These warnings show up when the eclipse-edc-bot-management-api-0.6.0-resolved.yaml (Source: swaggerhub.com) is used with the openAPI-Generator (JAR Version 7.4.0) and the command "validate".

Similar warnings also show up on swaggerhub.com:
Line 2170, Definition was declared but never used in document
Line 2190, Definition was declared but never used in document

Expected Behavior

No warnings in the management-api document about unused models

Observed Behavior

Warnings:

  • Unused model: JsonArray
  • Unused model: JsonValue
  • Unused model: JsonObject

Context Information

Warnings in versions:

  • management-api 0.6.0
  • management-api 0.5.1
  • management-api 0.5.0

Detailed Description

When trying to generate a python client with the openAPI-generator and the above mentioned management-api document, errors are present in the generated client. The errors are syntax errors and are linked to the JsonArray and JsonValue classes.
If the definitions of JsonArray, JsonValue and JsonObject are removed from the management-api document these syntax errors are not generated in the python client.

@github-actions github-actions bot added the triage all new issues awaiting classification label Apr 16, 2024
Copy link

Thanks for your contribution 🔥 We will take a look asap 🚀

@ndr-brt
Copy link
Member

ndr-brt commented Apr 16, 2024

those are unfortunately generated by the swagger documentation generator tool we're using, I remember I did a short investigation looking for excluding them but I didn't find a way to do it.

A general suggestion here is to avoid generated clients because they don't typically work well with json-ld.
There are some open source client implementations already available, it could worth taking a glance:

PS: please note that swaggerhub has been deprecated by the EDC, we're now publishing the ui to github pages:

@ndr-brt ndr-brt added the documentation Improvements or additions to documentation label Apr 16, 2024
Copy link

github-actions bot commented May 1, 2024

This issue is stale because it has been open for 14 days with no activity.

@github-actions github-actions bot added the stale Open for x days with no activity label May 1, 2024
Copy link

github-actions bot commented May 9, 2024

This issue was closed because it has been inactive for 7 days since being marked as stale.

@github-actions github-actions bot closed this as not planned Won't fix, can't repro, duplicate, stale May 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation stale Open for x days with no activity triage all new issues awaiting classification
Projects
None yet
Development

No branches or pull requests

2 participants