Another getset_descriptor is not callable error

I’ve made a rectangle in a python node using:

rectangle = Rectangle.ByCornerPoints(my_function ())

Which works and outputs a rectangle.

But within the same node if I try to get its width and length using:

width = Rectangle.Width (rectangle)
length = Rectangle.Length (rectangle)

The node outputs:

Warning: IronPythonEvaluator.EvaluateIronPythonScript operation failed.
Traceback (most recent call last):
File “”, line 188, in
TypeError: getset_descriptor is not callable <<<

How do I get the width and length of the rectangle?

Can you provide the python code using the preformatted code button, or post the DYN? How you’re building and calling the functions will matter here.

Ah, it’s cool… I tried this:

width = rectangle.Width

length = rectangle.Height

And it worked. :slight_smile:

Strangely though I tried:
length = rectangle.Length and I got a totally different figure. I’m wondering what the length of a rectangle is in dynamo now. It’s all 2d.

1 Like