Closed pghpete closed 3 years ago
I may be reverting back to an older version though... If I can't replicate this same functionality in my cron script...
#!/bin/bash
# ytcc.get.sh: update/get videos from youtube subscriber list
# requires: youtube-dl, ytcc, minidlna
# output directory
output_dir="/export/dlna"
# Update videos list, from subscribers
/usr/local/bin/ytcc -u
# get new videos from the last 3 days that were not already downloaded
/usr/local/bin/ytcc -d -s $(date -d "-3 day" +%Y-%m-%d) -p $output_dir -g
# Redownload, even watched from last 24h
#/usr/local/bin/ytcc -n -d -s $(date -d "-1 day" +%Y-%m-%d) -p $output_dir -g
You're not installing it from pypi.org? What's the pip command you used to install it?
The migration script from master should be working with the current master. The script at tag v2.0.1 should work with 2.0.1. Also, check ytcc --loglevel debug subscriptions
and post the error message if possible
And regarding the pip error: you might be missing the wheel
package.
Installed the wheel package but still no dice.
A DB migration attempt...
pete@omv: src]$ python3 migrate.py --olddb ~/.local/share/ytcc/ytcc.db.v1 --newdb ~/.local/share/ytcc/ytcc.db
Wm. Walker Co. is already subscribed.
Adding videos for Wm. Walker Co.
Traceback (most recent call last):
File "migrate.py", line 123, in <module>
core_v2.database.add_videos(videos, ytcc.Playlist(c_name, url))
File "/usr/local/lib/python3.7/dist-packages/ytcc/database.py", line 258, in add_videos
for video in videos:
File "migrate.py", line 120, in <genexpr>
for yt_videoid, title, description, publish_date, watched
TypeError: __init__() got an unexpected keyword argument 'watch_date'
ytcc version
[pete@omv: src]$ ytcc --version
ytcc, version 2.0.1
a ytcc subscriptions run with debug
[pete@omv: src]$ ytcc --loglevel debug subscriptions
[1608698736.744235] [MainProcess/MainThread] ytcc.config.DEBUG: Trying to read config from following locations: ['/etc/ytcc/ytcc.conf', '/home/pete/.config/ytcc/ytcc.conf', '/home/pete/.ytcc.conf']
[1608698736.747499] [MainProcess/MainThread] ytcc.config.DEBUG: Config was read from following locations: ['/home/pete/.config/ytcc/ytcc.conf']
[1608698736.749665] [MainProcess/MainThread] ytcc.database.DEBUG: PRAGMA foreign_keys = ON;
[1608698736.749979] [MainProcess/MainThread] ytcc.database.DEBUG: PRAGMA USER_VERSION;
[1608698736.750940] [MainProcess/MainThread] ytcc.database.DEBUG: SELECT p.id AS id, p.name AS name, p.url AS url, t.name AS tag FROM playlist AS p LEFT OUTER JOIN tag AS t ON p.id = t.playlist;
name │ url │ tags
────────────────┼─────────────────────────────────────────────────────────────────┼──────
Wm. Walker Co. │ https://www.youtube.com/channel/UCievvwx_-UU-rP28103rUCw/videos │
I don't want to trouble you anymore though if the feature which allowed you to download by date is no longer in ytcc. Is it? or am I missing something? Specifically...
Update subscription available videos...
usr/local/src/ytcc/ytcc.py -u
# get new videos from the last 3 days, not already downloaded
/usr/local/src/ytcc/ytcc.py -d -s $(date -d "-3 day" +%Y-%m-%d) -p $output_dir -g
oh and I think I forgot to mention I believe I was just using "pip3 install ytcc"
I release version 2.1.0 yesterday. Does that fix your migration problem? Make sure you also get the latest migration script.
I don't want to trouble you anymore though if the feature which allowed you to download by date is no longer in ytcc. Is it? or am I missing something?
No, it's still there: ytcc ls --since 2021-01-28 | ytcc download
While following the migration instructions to migrate using the migration script, it fails...
The install using pip throws some errors but appears to function over all...
Version appears to have been updated properly...
The migrate.py script is then run using...
This also appears to complete successfully without any errors. However, when I go to run ytcc and list subscriptions... I get this...
Environment, configuration and version information
Bug report output