This might be me not understanding how to use it correctly (I've taken a look at this post, but that didn't help me much).
I have created a sketch point, construction plane and circular sketch that is parallel to the face of the cube as shown in the image below. I would like to then run a script which extrudes this sketch through the cube.
When I try and use the `ThroughAllExtentDefition`, like below:
app = adsk.core.Application.get()
design = adsk.fusion.Design.cast(app.activeProduct)
root = design.rootComponent
extrudes = root.features.extrudeFeatures
extent = adsk.fusion.ThroughAllExtentDefinition.create()
e_input = extrudes.createInput(profile, adsk.fusion.FeatureOperations.CutFeatureOperation)
e_input.setTwoSidesExtent(extent, extent)
extrudes.add(e_input) # Create extrude
It fails with the following error:
Traceback (most recent call last):
File "C:\Users/angus/AppData/Roaming/Autodesk/Autodesk Fusion 360/API/AddIns/cadify-fusion\commands\agent\operations\helper.py", line 130, in try_op
f()
File "C:\Users/angus/AppData/Roaming/Autodesk/Autodesk Fusion 360/API/AddIns/cadify-fusion\commands\agent\operations\extrude.py", line 46, in two_sides_extent
extrudes.add(e_input) # Create extrude
^^^^^^^^^^^^^^^^^^^^^
File "C:\Users/angus/AppData/Local/Autodesk/webdeploy/production/b0c303e70bd97cfdc195adab65922cfeffcb363a/Api/Python/packages\adsk\fusion.py", line 20926, in add
return _fusion.ExtrudeFeatures_add(self, input)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
RuntimeError: 5 : EXTRUDE_CREATION_FAIL_ERROR - Cannot complete extrusion.
But I can see the extrude in the timeline and when I manually click, 'Edit Feature' then click `Ok` without changing anything it successfully creates the extrude cut.
Sometimes I have the sketch on a curved surface like
And I get the error
Cadify: Failed to execute operation: 2 : InternalValidationError : isCalFarestBody
Traceback (most recent call last):
File "C:\Users/angus/AppData/Roaming/Autodesk/Autodesk Fusion 360/API/AddIns/cadify-fusion\commands\agent\operations\helper.py", line 130, in try_op
f()
File "C:\Users/angus/AppData/Roaming/Autodesk/Autodesk Fusion 360/API/AddIns/cadify-fusion\commands\agent\operations\extrude.py", line 71, in negative_extent
extrudes.add(e_input) # Create extrude
^^^^^^^^^^^^^^^^^^^^^
File "C:\Users/angus/AppData/Local/Autodesk/webdeploy/production/b0c303e70bd97cfdc195adab65922cfeffcb363a/Api/Python/packages\adsk\fusion.py", line 20926, in add
return _fusion.ExtrudeFeatures_add(self, input)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
RuntimeError: 2 : InternalValidationError : isCalFarestBody
Whereas in all the situations, using the `DistanceExtentDefinition` works perfectly fine. Is there a reason behind this?
Solved! Go to Solution.
This might be me not understanding how to use it correctly (I've taken a look at this post, but that didn't help me much).
I have created a sketch point, construction plane and circular sketch that is parallel to the face of the cube as shown in the image below. I would like to then run a script which extrudes this sketch through the cube.
When I try and use the `ThroughAllExtentDefition`, like below:
app = adsk.core.Application.get()
design = adsk.fusion.Design.cast(app.activeProduct)
root = design.rootComponent
extrudes = root.features.extrudeFeatures
extent = adsk.fusion.ThroughAllExtentDefinition.create()
e_input = extrudes.createInput(profile, adsk.fusion.FeatureOperations.CutFeatureOperation)
e_input.setTwoSidesExtent(extent, extent)
extrudes.add(e_input) # Create extrude
It fails with the following error:
Traceback (most recent call last):
File "C:\Users/angus/AppData/Roaming/Autodesk/Autodesk Fusion 360/API/AddIns/cadify-fusion\commands\agent\operations\helper.py", line 130, in try_op
f()
File "C:\Users/angus/AppData/Roaming/Autodesk/Autodesk Fusion 360/API/AddIns/cadify-fusion\commands\agent\operations\extrude.py", line 46, in two_sides_extent
extrudes.add(e_input) # Create extrude
^^^^^^^^^^^^^^^^^^^^^
File "C:\Users/angus/AppData/Local/Autodesk/webdeploy/production/b0c303e70bd97cfdc195adab65922cfeffcb363a/Api/Python/packages\adsk\fusion.py", line 20926, in add
return _fusion.ExtrudeFeatures_add(self, input)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
RuntimeError: 5 : EXTRUDE_CREATION_FAIL_ERROR - Cannot complete extrusion.
But I can see the extrude in the timeline and when I manually click, 'Edit Feature' then click `Ok` without changing anything it successfully creates the extrude cut.
Sometimes I have the sketch on a curved surface like
And I get the error
Cadify: Failed to execute operation: 2 : InternalValidationError : isCalFarestBody
Traceback (most recent call last):
File "C:\Users/angus/AppData/Roaming/Autodesk/Autodesk Fusion 360/API/AddIns/cadify-fusion\commands\agent\operations\helper.py", line 130, in try_op
f()
File "C:\Users/angus/AppData/Roaming/Autodesk/Autodesk Fusion 360/API/AddIns/cadify-fusion\commands\agent\operations\extrude.py", line 71, in negative_extent
extrudes.add(e_input) # Create extrude
^^^^^^^^^^^^^^^^^^^^^
File "C:\Users/angus/AppData/Local/Autodesk/webdeploy/production/b0c303e70bd97cfdc195adab65922cfeffcb363a/Api/Python/packages\adsk\fusion.py", line 20926, in add
return _fusion.ExtrudeFeatures_add(self, input)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
RuntimeError: 2 : InternalValidationError : isCalFarestBody
Whereas in all the situations, using the `DistanceExtentDefinition` works perfectly fine. Is there a reason behind this?
Solved! Go to Solution.
Solved by siliconlad. Go to Solution.
I'm able to reproduce this issue, it looks like a bug. I've logged this to a ticket to be fixed - thank you for finding and posting this!
I'm able to reproduce this issue, it looks like a bug. I've logged this to a ticket to be fixed - thank you for finding and posting this!
No worries! Is there a way to track when this gets fixed?
No worries! Is there a way to track when this gets fixed?
We don't have anything public facing but I could see this issue being picked up fairly quickly, so hopefully a fix will be included in the next release. I can post here when that becomes clearer
We don't have anything public facing but I could see this issue being picked up fairly quickly, so hopefully a fix will be included in the next release. I can post here when that becomes clearer
Thank you!
The fix for this issue will be included in the release towards the end of March, thank you for your patience!
The fix for this issue will be included in the release towards the end of March, thank you for your patience!
Seems to work now!
Seems to work now!
Can't find what you're looking for? Ask the community or share your knowledge.