Hello!
For example, some TV can be slowly, so when I run the app, i don't know its current state, and can't be sure, that I can continue to execute another actions with app via code. Now I use sleep for it, but it is still too flaky code.
Here is my piece of code:
dev_mode = [x for x in apps if 'developer' in x['title'].lower()][0]
app.launch(dev_mode)
sleep(7) # it needs because smarttv too slowly, may be needed more
Or, may be you can show me more effective way for it?
app.subscribe_get_current(..) would let you know when the foreground application has changed. However, this may or may not be what you're looking for. The application could still be loading after this message gets delivered to you.
Hello! For example, some TV can be slowly, so when I run the app, i don't know its current state, and can't be sure, that I can continue to execute another actions with app via code. Now I use sleep for it, but it is still too flaky code. Here is my piece of code:
Or, may be you can show me more effective way for it?