Skip to content

Infinite Recursion #150

@ottojas

Description

@ottojas

Hit problem by accident. reduced code to this:

l=[s.sphere(1),s.cube([.5,.6,2])]
l.append(l)
l
[<solid.objects.sphere object at 0x7f55db249eb8>, <solid.objects.cube object at 0x7f55db249f28>, [...]]
sum(l)

.... GIANT SNIP ....
File "/home/otto/.local/lib/python3.7/site-packages/solid/solidpython.py", line 246, in
[self.add(c) for c in child]
File "/home/otto/.local/lib/python3.7/site-packages/solid/solidpython.py", line 246, in add
[self.add(c) for c in child]
File "/home/otto/.local/lib/python3.7/site-packages/solid/solidpython.py", line 246, in
[self.add(c) for c in child]
File "/home/otto/.local/lib/python3.7/site-packages/solid/solidpython.py", line 241, in add
if isinstance(child, (list, tuple)):
RecursionError: maximum recursion depth exceeded while calling a Python object

Regards
Otto

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions