<div dir="ltr">I discovered a simple workaround. Always pass a children parameter, even if empty.</div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Tue, May 12, 2020 at 5:16 PM Andreas Plesch <<a href="mailto:andreasplesch@gmail.com">andreasplesch@gmail.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr">Hi,<br><br>after some debugging I discovered another issue with x3d.py. It can be boiled down t o a few lines of code:<br><br><font face="monospace">import x3d.x3d as x<br><br>my_scene = x.Scene()<br>group = x.Group()<br>my_scene.children.append(group)<br>print(my_scene.XML())<br><br>=> output<br>=> <Scene><br>=>  <Group/><br>=> </Scene><br><br>my_other_scene = x.Scene()<br>print(my_other_scene.XML())<br><br>=> output<br>=> <Scene><br>=>  <Group/><br>=> </Scene><br><br></font>I think my_other_scene should be empty but remembers the content of the first scene.<div>Can you reproduce that ?</div><div>On the other hand this works (in a new session):</div><div><font face="monospace"><br></font></div><div><font face="monospace">my_scene = x.Scene( children = [x.Group()] )<br>print(my_scene.XML())<br><br>=> output<br>=> <Scene><br>=>  <Group/><br>=> </Scene><br><br>my_other_scene = x.Scene()<br>print(my_other_scene.XML()) </font> <br></div><div><br></div><div><font face="monospace">=> output<br>=> <Scene><br>=> </Scene></font><br></div><div><br>-- <br>Andreas Plesch<br>Waltham, MA 02453</div></div>
</blockquote></div><br clear="all"><div><br></div>-- <br><div dir="ltr" class="gmail_signature"><div dir="ltr"><div>Andreas Plesch<br>Waltham, MA 02453</div></div></div>