Skip to content

Commit

Permalink
Open browser after listening
Browse files Browse the repository at this point in the history
  • Loading branch information
jtpio committed Jun 14, 2019
1 parent 6a1d979 commit b4819e0
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions voila/app.py
Original file line number Diff line number Diff line change
Expand Up @@ -451,14 +451,15 @@ def start(self):
])

self.app.add_handlers('.*$', handlers)
if self.open_browser:
self.launch_browser()
self.listen()

def listen(self):
self.app.listen(self.port)
self.log.info('Voila is running at:\n%s' % self.display_url)

if self.open_browser:
self.launch_browser()

self.ioloop = tornado.ioloop.IOLoop.current()
try:
self.ioloop.start()
Expand Down

0 comments on commit b4819e0

Please sign in to comment.