Closed slidingshade closed 6 years ago
@slidingshade wow, thank you! Sorry for the inconvenience, the issue should be fixed now. Can you please pull the code and try again?
Hi!
shade@manjaro:~/tmp/plexiglas/ > plexiglas -d /home/shade/tmp/media -s 5% --debug -w -n plexiglas [30/08/2018 12:59:14] [DEBUG] [plexiglas] [cli:21] Username provided, updating in keyring [30/08/2018 12:59:14] [INFO] [plexiglas] [cli:69] Setting disk usage limit to 5.98 GiB [30/08/2018 12:59:14] [INFO] [plexiglas] [plex:58] Logging to myplex with username sliding_shade [30/08/2018 12:59:14] [DEBUG] [plexiglas] [plex:62] Password-based Traceback (most recent call last): File "/bin/plexiglas", line 11, in <module> load_entry_point('plexiglas==0.1.0', 'console_scripts', 'plexiglas')() File "/usr/lib/python3.7/site-packages/plexiglas/cli.py", line 188, in main opts.resume_downloads, opts.rate_limit) File "/usr/lib/python3.7/site-packages/plexiglas/plexsync.py", line 51, in sync sync_items = plex.syncItems().items AttributeError: 'MyPlexAccount' object has no attribute 'syncItems'
Where I supposed to mention which items I need to sync? Now I've added file to be synced to "plexiglas" device (the name which was set with option -n when starting plexiglas) through Plex web application. See attached screenshots.
By the way, thank you for such a quick response and great job! I've been looking a lot for some file-based sync solution to use on my Linux-laptop and WD My Passport Wireless Pro. Plex Downloader works only in my local network without authentification.
AttributeError: 'MyPlexAccount' object has no attribute 'syncItems'
It seems like you have another version of plexapi
installed, can you please run following commands and try again?
sudo pip3 uninstall plexapi
sudo pip3 install https://github.com/andrey-yantsen/python-plexapi/tarball/sync#egg=plexapi-3.0.6
Where I supposed to mention which items I need to sync? Now I've added file to be synced to "plexiglas" device (the name which was set with option -n when starting plexiglas) through Plex web application.
Yep, I'm using the same approach myself. IMO it's the most easiest way to do sync
.
Just in case, about syncing via web ui: you can use any filters before creating a new sync item
, e.g. I've creating following:
Top Movies
with 10 unwatched movies sorted by critics ratingNew Movies
10 recently released unwatched moviesRecently downloaded movies
, you know what to expect here :)Watch me again
10 watched movies sorted by download dateIf there is any intersections between items (e.g. the movie could be in New Movies
and Recently downloaded
), the video would be downloaded only once (actually it's the default Plex's behaviour).
When the new movie arrive — it will be automatically added to a collection
, converted and synced. And probably some other movie would be removed from the drive :)
BTW, if you've missed, I was able to run the script directly on my WD My Passport Wireless Pro, you can find the manual in the wiki, if you're interested.
Running with
pipenv run python3 -m plexiglas.__init__ -d /home/shade/tmp/media -s 10% --debug -w
Result:[28/08/2018 23:29:58] [INFO] [plexiglas] [__init__:75] Settings disk usage limit to 40.34 GiB Traceback (most recent call last): File "/usr/lib64/python3.6/runpy.py", line 193, in _run_module_as_main "__main__", mod_spec) File "/usr/lib64/python3.6/runpy.py", line 85, in _run_code exec(code, run_globals) File "/home/shade/tmp/plexiglas/plexiglas/__init__.py", line 189, in <module> main() File "/home/shade/tmp/plexiglas/plexiglas/__init__.py", line 166, in main disk_used = db.get_downloaded_size() File "/home/shade/tmp/plexiglas/plexiglas/db.py", line 155, in get_downloaded_size with _get_db() as conn: File "/usr/lib64/python3.6/contextlib.py", line 81, in __enter__ return next(self.gen) File "/home/shade/tmp/plexiglas/plexiglas/db.py", line 17, in _get_db _init_db(conn) File "/home/shade/tmp/plexiglas/plexiglas/db.py", line 70, in _init_db conn.execute('ALTER TABLE items ADD COLUMN media_type VARCHAR(50)') sqlite3.OperationalError: duplicate column name: media_type