MCPcopy Create free account
hub / github.com/apache/impala / __enter__

Method __enter__

tests/util/cancel_util.py:50–54  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

48 return
49
50 def __enter__(self):
51 self.handle = self.client.execute_async(self.sql, user=self.user)
52 self.poll_thread = threading.Thread(target=lambda: self.poll())
53 self.poll_thread.start()
54 return self.client.handle_id(self.handle)
55
56 def __exit__(self, exc_type, exc_value, traceback): # noqa: U100
57 self.poll_thread.join()

Callers

nothing calls this directly

Calls 5

pollMethod · 0.95
startMethod · 0.65
execute_asyncMethod · 0.45
ThreadMethod · 0.45
handle_idMethod · 0.45

Tested by

no test coverage detected