avoid deprecated IOLoop.instance
use our own handle on the main ioloop, retrieved while we are still in the main thread
@@ -41,6 +41,7 @@ class Build:
self.image_name = image_name
self.push_secret = push_secret
self.builder_image = builder_image
+ self.main_loop = IOLoop.current()
def get_cmd(self):
"""Get the cmd to run to build the image"""
@@ -63,7 +64,7 @@ class Build:
def progress(self, kind, obj):
"""Put the current action item into the queue for execution."""
- IOLoop.instance().add_callback(self.q.put, {'kind': kind, 'payload': obj})
+ self.main_loop.add_callback(self.q.put, {'kind': kind, 'payload': obj})
def submit(self):
"""Submit a image spec to openshift's s2i and wait for completion """
