You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Sphere.scaled() calls the scale() function with keyword arguments for x,y and z. However, the inbuilt Sphere.scale() method requires only a factor for uniform scaling of the self.radius. This makes it not possible to use the scaled() method at all. I suspect similar behaviour in the Cylinder class due to similar implementation of scale.
To replicate, create any sphere and apply scaling: c = Sphere(10) scaled_c = c.scaled(0.5,10,10)
File "C:\Users\akango\Documents\github\compas_introduction_2025\.venv\lib\site-packages\compas\geometry\geometry.py", line 173, in scaled
geometry.scale(x=x, y=y, z=z)
TypeError: scale() got an unexpected keyword argument 'x'
Is there a reason why most Shape objects have their own transformation methods which are different from the methods it could inherit from Geometry?
Activity