[ https://issues.apache.org/jira/browse/IGNITE-14432?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Ivan Daschinskiy reassigned IGNITE-14432: ----------------------------------------- Assignee: Ivan Daschinskiy > Python thin: Support "with" statement for connection method > ----------------------------------------------------------- > > Key: IGNITE-14432 > URL: https://issues.apache.org/jira/browse/IGNITE-14432 > Project: Ignite > Issue Type: Improvement > Components: python, thin client > Reporter: Igor Sapego > Assignee: Ivan Daschinskiy > Priority: Major > Fix For: python-0.4.0 > > > [pep-0343|https://www.python.org/dev/peps/pep-0343/] > instead of this: > {code:python}client.connect(environ['DB_HOST'], int(environ['DB_PORT'])) > try: > return client.sql(q, query_args=q_args, include_field_names=True) > finally: > client.close(){code} > The user will be able to use this: > {code:python}with client.connect(environ['DB_HOST'], int(environ['DB_PORT'])): > return client.sql(q, query_args=q_args, include_field_names=True){code} -- This message was sent by Atlassian Jira (v8.3.4#803005)