-
-
Notifications
You must be signed in to change notification settings - Fork 7k
Move all kotlin-client samples in subfolder kotlin #5718
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
Move all kotlin-client samples in subfolder kotlin #5718
Conversation
@@ -0,0 +1,61 @@ | |||
package org.openapitools.client.auth |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think there are some files like this that don't belong to this PR.
Because the OAuth supports is still pending in the PR #5697
Can you please generate the sample projects again?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I forgott to mvn clean install before rerun generate all sample projects. Fixed with a9a01a4
@@ -10,28 +10,28 @@ import okhttp3.MultipartBody | |||
import org.openapitools.client.models.User | |||
|
|||
interface UserApi { | |||
@POST("/user") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not sure if this change is right or not...
Can someone else give some feedback here?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There is still a bug in kotlin-retrofit2 generator. These releative pathes have to start WITHOUT slashes. See java-retrofit2 generator. I fixed it within my PR #5697
aaef017#diff-b60a03ff3897718b90d1c4d54850d0de in file KotlinClientCodegen.java
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you elaborate a bit more on why that's a bug?
I thought that "/user" was the correct behaviour.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
/user was the behaviour before my PR #5697. Retrofit2 does not allow a baseURL without trailing slash. That means, the relative path has to start without slash. The current version of kotlin-retrofit2 didnt worked in our projekt. We checked the java-retrofit2 templates. The relative pathes in the api files in java-retrofit2 didnt start with slash.
We ran into following issue: square/retrofit#907
Looks good to me. 👍 |
I think you will also need to update Lines 1451 to 1461 in a9a01a4
|
Should I edit the file manually or is it generated by a shell script |
That file is manually maintained |
I updated the pom.xml in root path, but still errors in Shippable Ci. Missing pom.xml files in all kotlin projects. Anything to todo? |
We manually added a (unique) pom.xml file in the Kotlin sample folder. You will need to move the pom.xml to the new directory in order for maven to run the integration tests |
Anything to do? Don't know why these ci builds failed |
I don't know what's the problem, but looking at the travis config file, Maybe something needs to be updated there? |
….com/Dataport/openapi-generator into kotlin-sample-projects-in-sub-folder
…rator into kotlin-sample-projects-in-sub-folder
Pre PR for Merging #5697
PR checklist
./bin/
(or Windows batch scripts under.\bin\windows
) to update Petstore samples related to your fix. This is important, as CI jobs will verify all generator outputs of your HEAD commit, and these must match the expectations made by your contribution. You only need to run./bin/{LANG}-petstore.sh
,./bin/openapi3/{LANG}-petstore.sh
if updating the code or mustache templates for a language ({LANG}
) (e.g. php, ruby, python, etc).master
,4.3.x
,5.0.x
. Default:master
.PR Description
This PR moves all kotlin-client sample projects into subfolder named 'kotlin' for better merging and less diffs in PR #5697
@jimschubert @dr4ke616 @karismann @Zomzog @andrewemery @4brunu