An error occurred while fetching the assigned milestone of the selected merge_request.
@@ -116,13 +116,13 @@ end:
@@ -135,7 +135,7 @@ end:
@@ -148,7 +148,7 @@ end:
@@ -161,7 +161,7 @@ end:
@@ -174,7 +174,7 @@ end:
@@ -183,7 +183,7 @@ end:
Created by: ityuhui
When the path parameter name is a C/C++ keyword, e.g. namespace
, the generated code will escape the parameter name, e.g. _namespace
:
snprintf(localVarPath, sizeOfPath, "/apis/apps/v1/namespaces/{namespace}/controllerrevisions");
// Path Params
long sizeOfPathParams__namespace = strlen(_namespace)+3 + strlen("{ _namespace }");
...
char* localVarToReplace__namespace = malloc(sizeOfPathParams__namespace);
sprintf(localVarToReplace__namespace, "{%s}", "_namespace"); //<--- This is not right, {_namespace} cannot replace namespace in localVarPath "/apis/apps/v1/namespaces/{namespace}/controllerrevisions"
localVarPath = strReplace(localVarPath, localVarToReplace__namespace, _namespace);
The {_namespace}
in localVarToReplace__namespace
should not be escaped, it should be {namespace}
, then it can be used to replace in localVarPath "/apis/apps/v1/namespaces/{namespace}/controllerrevisions"
So this PR will disable escaping the parameter name in URL path string.
This PR relays the PR https://github.com/OpenAPITools/openapi-generator/pull/8205
./bin/generate-samples.sh
to update all Petstore samples related to your fix. This is important, as CI jobs will verify all generator outputs of your HEAD commit as it would merge with master. These must match the expectations made by your contribution. You may regenerate an individual generator by passing the relevant config(s) as an argument to the script, for example ./bin/generate-samples.sh bin/configs/java*
. For Windows users, please run the script in Git BASH.master
@wing328 @zhemant @michelealbano
Preferences