Skip to content

Commit d47847a

Browse files
committed
i really think it should be like this and in 3.12 it otherwise doesn't work
1 parent 2840d1a commit d47847a

File tree

1 file changed

+10
-5
lines changed

1 file changed

+10
-5
lines changed

src/compas_occ/geometry/curves/__init__.py

Lines changed: 10 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,25 @@
11
from .curve2d import OCCCurve2d # noqa : F401
2-
from .curve import OCCCurve
2+
from .curve import OCCCurve # noqa: F401
33
from .nurbs import OCCNurbsCurve
44

5+
from compas.geometry import Curve
6+
from compas.geometry import NurbsCurve
7+
58
from compas.plugins import plugin
69

710

811
@plugin(category="factories", requires=["compas_occ"])
912
def new_curve(cls, *args, **kwargs):
10-
curve = object.__new__(OCCCurve)
11-
return curve
13+
# curve = object.__new__(OCCCurve)
14+
# return curve
15+
return super(Curve, cls).__new__(cls)
1216

1317

1418
@plugin(category="factories", requires=["compas_occ"])
1519
def new_nurbscurve(cls, *args, **kwargs):
16-
curve = object.__new__(OCCNurbsCurve)
17-
return curve
20+
# curve = object.__new__(OCCNurbsCurve)
21+
# return curve
22+
return super(NurbsCurve, cls).__new__(cls)
1823

1924

2025
@plugin(category="factories", requires=["compas_occ"])

0 commit comments

Comments
 (0)