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

Adding streamers causes a RuntimeError: dictionary changed size during iteration #7

Open
rkantos opened this issue Oct 27, 2024 · 0 comments

Comments

@rkantos
Copy link

rkantos commented Oct 27, 2024

I've had this problem for a while when using Nedry. Seems to require a restart everytime a new streamer is added.

[2024-10-27 20:33:50,497][INFO][discord_bot:75]: connected to guild "BF2 Playerbase"
Exception in thread Thread-1 (_streamer_check_loop):
Traceback (most recent call last):
  File "/usr/lib/python3.11/threading.py", line 1038, in _bootstrap_inner
    self.run()
  File "/usr/lib/python3.11/threading.py", line 975, in run
    self._target(*self._args, **self._kwargs)
  File "/home/csgo/.venv/lib/python3.11/site-packages/nedry/twitch_monitor.py", line 136, in _streamer_check_loop
    self._check_streamers()
  File "/home/csgo/.venv/lib/python3.11/site-packages/nedry/twitch_monitor.py", line 90, in _check_streamers
    channels = self.read_all_streamer_info()
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/csgo/.venv/lib/python3.11/site-packages/nedry/twitch_monitor.py", line 187, in read_all_streamer_info
    return [self._twitch_op_retry(self._read_streamer_info, u) for u in self.usernames]
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/csgo/.venv/lib/python3.11/site-packages/nedry/twitch_monitor.py", line 187, in <listcomp>
    return [self._twitch_op_retry(self._read_streamer_info, u) for u in self.usernames]
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
RuntimeError: dictionary changed size during iteration
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant