z411 / trackma

Open multi-site list manager for Unix-like systems. (ex-wMAL)
https://z411.github.io/trackma
GNU General Public License v3.0
779 stars 81 forks source link

'generator' object is not subscriptable #740

Open EnigmaticJihad opened 1 month ago

EnigmaticJihad commented 1 month ago

Installed Trackma with pipx.

Here's the output I get when run trackma, trackma-gtk, trackma-curses.

Trackma v0.8.6  Copyright (C) 2012-2023  z411
This program comes with ABSOLUTELY NO WARRANTY; for details type `about'
This is free software, and you are welcome to redistribute it
under certain conditions; see the COPYING file for details.

Initializing engine...
Engine: Trackma v0.8.6 - using account Zed(anilist).
Engine: Reading config files...
Data: Initializing...
libanilist: Initializing...
Data: Using libanilist (anime)
Engine: Parsing redirection file...
Engine: Scanning local library...
Tracker (inotify): Initializing...
Tracker (inotify): Using inotify.

Ready. Type 'help' for a list of commands.
Press tab for autocompletion and up/down for command history.
Available statuses: watching, completed, rewatching, paused, dropped, plantowatch

zedxot [anilist] (anime) watching >> Exception in thread Thread-2 (observe):
Traceback (most recent call last):
  File "/usr/lib/python3.12/threading.py", line 1075, in _bootstrap_inner
    self.run()
  File "/usr/lib/python3.12/threading.py", line 1012, in run
    self._target(*self._args, **self._kwargs)
  File "/home/zed/.local/pipx/venvs/trackma/lib/python3.12/site-packages/trackma/tracker/inotify.py", line 46, in observe
    i = inotify.adapters.InotifyTrees(paths, mask=mask)
        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/zed/.local/pipx/venvs/trackma/lib/python3.12/site-packages/inotify/adapters.py", line 372, in __init__
    self.__load_trees(paths)
  File "/home/zed/.local/pipx/venvs/trackma/lib/python3.12/site-packages/inotify/adapters.py", line 381, in __load_trees
    current_path = q[0]
                   ~^^^
TypeError: 'generator' object is not subscriptable
Derkelf commented 1 month ago

I'm facing the same issue as well. Did you find a workaround?

FichteFoll commented 1 month ago

Hm, the inotify package hasn't been updated in 6 years so this seems like a weird regression. I personally don't use the inotify tracker and recommend using mpris, if your player supports it – ideally from the master branch because that has unreleased changes.