From 907f6c80d2c3d97b6421c5a6f80243bf58a40568 Mon Sep 17 00:00:00 2001 From: Marko Hauptvogel Date: Thu, 23 Jul 2026 20:54:45 +0200 Subject: [PATCH] fix: renderpath for type-extensions The `child_path` variable can still be set from the attribute loop above, but then it has the wrong value. Without any attributes it is unset and causes an UnboundLocalError. Set it always to a proper value. Fixes: 0c8a3fc4f9a8 ("Add support to pass base-types to type extensions") --- src/zeep/xsd/types/complex.py | 1 + 1 file changed, 1 insertion(+) diff --git a/src/zeep/xsd/types/complex.py b/src/zeep/xsd/types/complex.py index 776fdeb0..d63f94ca 100644 --- a/src/zeep/xsd/types/complex.py +++ b/src/zeep/xsd/types/complex.py @@ -279,6 +279,7 @@ def render( and not isinstance(value, (list, dict, CompoundValue)) ): element = self.elements_nested[0][1] + child_path = render_path + [element.name] element.type.render(node, value, None, child_path) return