Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Exception when show that is currently being tracked is removed from the list #684

Open
FichteFoll opened this issue Apr 16, 2023 · 0 comments

Comments

@FichteFoll
Copy link
Collaborator

Steps to reproduce

  1. Add a show to the list without sending it to remote.
  2. Start playing an episode of this show (using the mpris tracker here, but should happen with any).
  3. Force-retrieve the list from remote, essentially undoing the addition of the show earlier.
  4. Close the player.

Result

Traceback (most recent call last):
  File "/home/fichte/code/trackma/trackma/engine.py", line 418, in get_show_info
    return showdict[showid]
KeyError: 98595

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/home/fichte/code/trackma/trackma/tracker/mpris.py", line 225, in observe_async
    await asyncio.gather(*tasks)
  File "/home/fichte/code/trackma/trackma/tracker/mpris.py", line 103, in properties_watcher
    handle_properties_changed(tracker, msg)
  File "/home/fichte/code/trackma/trackma/tracker/mpris.py", line 113, in handle_properties_changed
    tracker.on_playback_status_change(sender, playback_status)
  File "/home/fichte/code/trackma/trackma/tracker/mpris.py", line 273, in on_playback_status_change
    self._handle_player_update(player)
  File "/home/fichte/code/trackma/trackma/tracker/mpris.py", line 287, in _handle_player_update
    self._handle_player_stopped()
  File "/home/fichte/code/trackma/trackma/tracker/mpris.py", line 343, in _handle_player_stopped
    self.update_show_if_needed(state, show_tuple)
  File "/home/fichte/code/trackma/trackma/tracker/tracker.py", line 220, in update_show_if_needed
    self._update_state(state)
  File "/home/fichte/code/trackma/trackma/tracker/tracker.py", line 163, in _update_state
    self._emit_signal(
  File "/home/fichte/code/trackma/trackma/tracker/tracker.py", line 106, in _emit_signal
    self.signals[signal](*args)
  File "/home/fichte/code/trackma/trackma/engine.py", line 147, in _tracker_playing
    show = self.get_show_info(showid)
  File "/home/fichte/code/trackma/trackma/engine.py", line 420, in get_show_info
    raise utils.EngineError("Show not found.")
trackma.utils.EngineError: Show not found.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants