Always set contract sub state

kivy_mainline_and_py3.8
Tyler Goodlet 2019-01-14 21:13:22 -05:00
parent 4753dc2db8
commit c94ce47aa6
1 changed files with 3 additions and 0 deletions

View File

@ -365,6 +365,8 @@ class OptionChain(object):
label.symbol = symbol
if table:
table.add_widget(label)
# always keep track of current subscription
self.symbol, self.expiry = symbol, expiry
return
# start streaming soonest contract by default if not provided
@ -498,5 +500,6 @@ async def _async_main(
# trio-kivy entry point.
await async_runTouchApp(chain.widgets['root']) # run kivy
finally:
await chain._quote_gen.aclose()
# cancel GUI update task
nursery.cancel_scope.cancel()