[Python] fix tags with underscore for python (#3995)

* fix tag with underscore for python

* remove log
This commit is contained in:
wing328
2016-10-14 17:49:43 +08:00
committed by GitHub
parent 2dcddb79bc
commit 5de338d781
8 changed files with 303 additions and 1 deletions

View File

@@ -430,7 +430,7 @@ public class PythonClientCodegen extends DefaultCodegen implements CodegenConfig
// replace - with _ e.g. created-at => created_at
name = name.replaceAll("-", "_");
// e.g. PhoneNumberApi.rb => phone_number_api.rb
// e.g. PhoneNumberApi.py => phone_number_api.py
return underscore(name) + "_api";
}
@@ -608,6 +608,12 @@ public class PythonClientCodegen extends DefaultCodegen implements CodegenConfig
p.example = example;
}
@Override
public String sanitizeTag(String tag) {
return sanitizeName(tag);
}
@Override
public String escapeQuotationMark(String input) {