{"action":"opened","issue":{"url":"https://api.github.com/repos/springdoc/springdoc-openapi/issues/59","repository_url":"https://api.github.com/repos/springdoc/springdoc-openapi","labels_url":"https://api.github.com/repos/springdoc/springdoc-openapi/issues/59/labels{/name}","comments_url":"https://api.github.com/repos/springdoc/springdoc-openapi/issues/59/comments","events_url":"https://api.github.com/repos/springdoc/springdoc-openapi/issues/59/events","html_url":"https://github.com/springdoc/springdoc-openapi/issues/59","id":484723068,"node_id":"MDU6SXNzdWU0ODQ3MjMwNjg=","number":59,"title":"Parameter documentation overriden by schema calculation based on type","user":{"login":"antechrestos","id":5700545,"node_id":"MDQ6VXNlcjU3MDA1NDU=","avatar_url":"https://avatars1.githubusercontent.com/u/5700545?v=4","gravatar_id":"","url":"https://api.github.com/users/antechrestos","html_url":"https://github.com/antechrestos","followers_url":"https://api.github.com/users/antechrestos/followers","following_url":"https://api.github.com/users/antechrestos/following{/other_user}","gists_url":"https://api.github.com/users/antechrestos/gists{/gist_id}","starred_url":"https://api.github.com/users/antechrestos/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/antechrestos/subscriptions","organizations_url":"https://api.github.com/users/antechrestos/orgs","repos_url":"https://api.github.com/users/antechrestos/repos","events_url":"https://api.github.com/users/antechrestos/events{/privacy}","received_events_url":"https://api.github.com/users/antechrestos/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2019-08-23T21:41:46Z","updated_at":"2019-08-23T21:41:46Z","closed_at":null,"author_association":"NONE","body":"Hi,\r\n\r\nI spotted a potential issue [in AbstractRequestBuilder](https://github.com/springdoc/springdoc-openapi/blob/91c437a8b903254b9cf6fb3d885114d5167ad01e/springdoc-openapi-common/src/main/java/org/springdoc/core/AbstractRequestBuilder.java#L75)\r\n\r\nIn the following code,\r\n\r\n```kotlin\r\nfun list(   @Parameter(name = \"trackerId\", `in` = ParameterIn.PATH, required = true, schema = Schema(type = \"string\", example = \"the-tracker-id\"))\r\n            @PathVariable trackerId: String,\r\n            @Parameter(name = \"start\", `in` = ParameterIn.QUERY, required = false, schema = Schema(type = \"string\", format = \"date-time\", required = false, example = \"1970-01-01T00:00:00.000Z\"))\r\n            @RequestParam(value = \"start\", required = false) startDate: Instant?,\r\n            @Parameter(name = \"end\", `in` = ParameterIn.QUERY, required = false, schema = Schema(type = \"string\", format = \"date-time\", required = false, example = \"1970-01-01T00:10:00.000Z\"))\r\n            @RequestParam(value = \"end\", required = false) endDate: Instant?): Collection<Result> \r\n```\r\n\r\nThe parameters schemas are read from documentation, yet it gets overriden by the call to `buildParams`.\r\n\r\nIn my understanding the code should more be something like\r\n\r\n\r\n```java\r\n                       if (parameterDoc != null) {\r\n\t\t\t\tif (parameterDoc.hidden()) {\r\n\t\t\t\t\tcontinue;\r\n\t\t\t\t}\r\n\t\t\t\tparameter = parameterBuilder.buildParameterFromDoc(parameterDoc, null);\r\n\t\t\t}\r\n\t\t\telse if (!isParamTypeToIgnore(paramType)) {\r\n```\r\n\r\nFor now the  `Parameter` annotation is useless as the  `Instant` calculation leads to a `int64`, whatever the documentation.\r\n\r\n\r\n"}}
{"actor":{"display_login":"antechrestos"}}