Fusion API Error when getting Chamfer Edge Set

Fusion API Error when getting Chamfer Edge Set

robertASTUP
Contributor Contributor
338 Views
1 Reply
Message 1 of 2

Fusion API Error when getting Chamfer Edge Set

robertASTUP
Contributor
Contributor

I am trying to get out the edge set for a chamfer in the attached model. When I create the chamfer by selecting a face and run the below script, I get a "RuntimeError: 2 : InternalValidationError : dataRef" error. When I select all 4 edges to form the edge set, this runs with no issues. Is this a bug in the API or does the script need modified for if the edge sets contain faces or edges?

 

import adsk.fusion, adsk.core 
app = adsk.core.Application.get()
design = adsk.fusion.Design.cast(app.activeProduct)

timeline = design.timeline
chamfer = timeline.item(1).entity

# roll timeline to before chamfer
timeline.item(1).rollTo(True)

# get edge sets
edge_sets = chamfer.edgeSets

print(edge_sets.item(0).edges)
0 Likes
339 Views
1 Reply
Reply (1)
Message 2 of 2

john.kirchner
Autodesk
Autodesk

This looks like a bug in the API, you shouldn't need to check in your script if the chamfer's edge sets contain faces, edges, etc before grabbing the edges.

I have reproduced the issue on my end and have created a bug ticket, thank you for posting this!



0 Likes