From 4ed754f120b315af96e43749bc404f6f910b17af Mon Sep 17 00:00:00 2001 From: Michael van Tellingen Date: Sat, 6 Apr 2024 08:49:02 +0200 Subject: [PATCH] fix(python): use correct base client init MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit We don’t need to pass `self` to super(), this resulted in passing the invalid value twice --- .../codegen/languages/python/client/ApiRootFileProducer.kt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/languages/python/src/main/kotlin/io/vrap/codegen/languages/python/client/ApiRootFileProducer.kt b/languages/python/src/main/kotlin/io/vrap/codegen/languages/python/client/ApiRootFileProducer.kt index 9c943a38e..323745ce2 100644 --- a/languages/python/src/main/kotlin/io/vrap/codegen/languages/python/client/ApiRootFileProducer.kt +++ b/languages/python/src/main/kotlin/io/vrap/codegen/languages/python/client/ApiRootFileProducer.kt @@ -30,14 +30,14 @@ class ApiRootFileProducer constructor( content = """| |$pyGeneratedComment |${type.imports("client")} - |from commercetools.client import BaseClient + |from commercetools.base_client import BaseClient | | |class Client(BaseClient): | | def __init__(self, *args, **kwargs): | kwargs.setdefault("url", "${api.baseUri?.template}") - | super().__init__(self, **kwargs) + | super().__init__(**kwargs) | | <${type.subResources("self").escapeAll()}> |