Skip to content

add with support to Python cursor #208

Open
@larkost

Description

@larkost

The Connection class in the Python driver currently supports the Python with structure, but our Cursor class does not. I just ran into a case where it would be nice to have this. An example for clarity:

with r.db('foo').table('bar').run(conn) as full_table:
     for row in full_table:
          pass # do something in reality

While our Cursors are not that expensive, it does make sure that things get cleaned up on-time.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions