davebshow / goblin

A Python 3.5 rewrite of the TinkerPop 3 OGM Goblin
Other
93 stars 21 forks source link

Add method to easily remove Vertex #111

Closed brean closed 5 years ago

brean commented 5 years ago

Hi,

I think it should be possible to easily delete a Vertex when I have its instance. The API might look like this:

class Foo(Vertex):
   ...

async def remove_all_foo():
    session = await app.session()
    foos = session.traversal(Foo)
    async for foo in foos:
        await foo.remove()
brean commented 5 years ago

looks at least more intuitive then await session.remove_vertex(foo)