[ https://issues.apache.org/jira/browse/TINKERPOP-3169?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=18004507#comment-18004507 ]
Andrea C commented on TINKERPOP-3169: ------------------------------------- I believe what you're seeing is the debugger consuming the iterator when the debug point is placed on the line which calls `next()`. When the code is resumed after the breakpoint, the StopIteration error is thrown because the iterator has already been consumed by the debugger. > Vertex Creation Return StopItteraion() Error > -------------------------------------------- > > Key: TINKERPOP-3169 > URL: https://issues.apache.org/jira/browse/TINKERPOP-3169 > Project: TinkerPop > Issue Type: Bug > Affects Versions: 3.7.3 > Reporter: Alfredo > Priority: Major > > The vertex gets created with all its properties, however there's a > stopItteration() error that is thrown. > Maybe i'm not doing this correctly but haven't found a way to do it. > What i'm trying to do is build my vertex and its properties dynamically from > a list, then "commit" it all in one transaction or call to db engine. Im > using latest gremlin python library. > {code:java} > t = g.add_v("person") > for prop, value in property_list: > t = t.property(prop, value) > response = t.next() # this creates vertex, throws stopIteration() error > response = t.to_list() # this creates vertex, throws no error but returns > empty list > ver_count_after = g.V().count().next() # Shows increase in vertices > # is there a way to create a vertex with dynamic list of properties in one > transaction. > # I cant daisy-chain .property().property() on the command as I don't have a > finite number of properties {code} > -- This message was sent by Atlassian Jira (v8.20.10#820010)