-
Notifications
You must be signed in to change notification settings - Fork 44
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
Channel metadata and thumbnail not appearing but episode metadata and thumbnails work fine #92
Comments
No search log in logs provided INFO (logkit:16) - Place correct Plex token in X-Plex-Token.id file in logs folder or in PLEX_LIBRARY_URL variable to have a log per library - https://support.plex.tv/hc/en-us/articles/204059436-Finding-your-account-token-X-Plex-TokenHTTP Error 401: Unauthorized (https://github.com/ZeroQI/YouTube-Agent.bundle/blob/master/Contents/Code/__init__.py#L533) UCXvKUavCtDOlA8bT1i2tI3w is 22 chars after UC and match description Missing search log in logs so cannot check guide assignment but missing token ID file... |
Sorry and thanks for your time. Here's both logs after:
It still isn't working unfortunately… com.plexapp.agents.youtube.log
Language is set to If it's any help I'm using Library file tree
I tried an old version of This old version: YouTube-Agent.bundle.zip |
Can access library file now but issue persists. |
I'm sorry I don't understand if I should search something on Plex or you're referring to the agent not searching? |
I need you to match manually the series so I have that in logs, the agent search() funct89n assign a unique I'd and it seems it is what doesn't work here |
Hello again, hope you have a good week. If you meant "Fix match" and then manually matching the YouTube channel, I did just that and the correct metadata for the channel got scraped BUT now the episodes metadata don't get collected. Here are the logs: |
Just wanted to chime in that I'm also seeing this issue - episode metadata is loading fine but series metadata no longer is. No images for the series and the [RANDOM LETTERS AND NUMBERS] are still in the title of the series. Let me know if you'd like me to get logs also. |
@cbartondock please do! That way ZeroQI can see your logs together with mine as soon as they have time. I'm pasting the instructions to attach the logs if it's of any help:
|
Same error as you looks like, the key line being |
@mileyvirus Does the X-Plex-Token.id file just have the token string and nothing else in it? Doesn't seem to be working for me. |
@cbartondock yes, just the token string and nothing else and no line breaks either. I put mine in two places since I didn't figure which was the right path.
The content of
|
Okay yeah, I just worked out by looking over |
It seems to be grabbing the guid from a random episode of the channel rather than for the channel itself. |
"No GUID so random folder" so it considers the folder doesn't have a channel ID indicated... |
I believe this is occurring as early as |
The reason it says No GUID is because the GUID is an episode GUID, which it doesn't recognize since it doesn't start with UC or HC |
ASS scanner let the title with square brackets with channel I'd pass and the agent search function assign a forced guid. Plex scanner will drop square brackets and would cause that exact behaviour, so is ASS the scanner? Edit: Please test https://github.com/ZeroQI/YouTube-Agent.bundle/blob/master/Contents/Code/__init__.py line 120 should be display_name instead of filename |
Ah I see, I don't think I am using ASS and I see now that it is a requirement for YouTube-Agent. Weird that it was working before. If you don't mind my asking, the documentation for ASS (what it does and how to use it for YouTube-Agent) is pretty opaque, how do I set-up ASS? If not no worries, I got it working in the end without ASS by patching
Basically it just forcibly gets the good guid from the correct |
@ZeroQI I tried that change but it still won't work for me. I have the latest ASS.
@cbartondock I tried your change but it won't work for me. I'm a Python 3 dev but opening the Agent's code it looks like it's all Python 2 and it has limited libraries. I'm going to look more into how Plex agents work. I tried the other YouTube agent and that works but with some other issues… |
ASS is a requirement for playlist and channel guide in title functionality, as well as numbering playlist correctly... My agent also read metadata from local Json file if present like the other agent... Where are the search agent logs after the change? |
We need code working within Json then working with local Json file so it benefits everybody. I unfortunately don't use Plex anymore, so don't reproduce libraries, and so need the log to do the coding on the phone most of times |
I was able to recreate this issue and resolve it ( at least for myself). Initially I was using the TV scanner, and I inserted a "air date" into the file name to make that scanner happy. I also configured youtube-dl to create an "info.json" file for each episode. The fix was to change the scanner to the ASS scanner, and remove the "info.json" files from the series folder. To verify the .json file was the issue, I recreated the library with 2 "series", one with the info.json files and one without. The series without the json file has the correct series title, the other has "foldername + channel id" in the name. One think I could not do was remove the json file and rescan the library to correct the series name. Perhaps I am being impatient, or I'm not performing the correct steps to fix the series name. Ideas? |
Without Jason it works |
I can't attach files here. I'll open another issue. with logs and additional details. edit 1: it looks like github doesn't let you attach logs to issues. I'm looking for an alternative way to share the logs. edit 2: it accepts .log but not archive file like .tgz. I'll post logs and details in another post. |
It does but depends the extension, try txt |
IssueChannel metadata inc poster missing. episode name/metadata is correct. Channel name is the channel folder name. *Example: * Folder is Don_t_Walk_Run_Productions [UCwpDBy43upJR7LZLrgnKkPA], and channel name is Don_t_Walk_Run_Productions [UCwpDBy43upJR7LZLrgnKkPA]. Notable Observations
Environment
Plex Token ID File: /var/lib/plexmediaserver/Library/Application Support/Plex Media Server/X-Plex-Token.id Log ExcerptsPlex token and json from top part of com.plex.agent.youtube.log: 2022-05-20 14:06:57,086 (7f162ad1c808) : INFO (__init__:549) - 'X-Plex-Token.id' file present
2022-05-20 14:06:57,100 (7f1626e3bb38) : WARNING (data:179) - Error decoding with simplejson, using demjson instead (this will cause a performance hit) - Expecting value: line 5 column 1 (char 518) Exception getting hosted resource hashes from com.plex.agent.youtube.log: 2022-05-20 12:53:17,364 (7fc7e8ad8808) : DEBUG (networking:143) - Requesting 'http://127.0.0.1:32400/:/plugins/com.plexapp.system/resourceHashes'
2022-05-20 12:53:17,367 (7fc7e8ad8808) : ERROR (networking:196) - Error opening URL 'http://127.0.0.1:32400/:/plugins/com.plexapp.system/resourceHashes'
2022-05-20 12:53:17,369 (7fc7e8ad8808) : CRITICAL (runtime:1299) - Exception getting hosted resource hashes (most recent call last):
File "/usr/lib/plexmediaserver/Resources/Plug-ins-5bd057d2b/Framework.bundle/Contents/Resources/Versions/2/Python/Framework/components/runtime.py", line 1293, in get_resource_hashes
json = self._core.networking.http_request("http://127.0.0.1:32400/:/plugins/com.plexapp.system/resourceHashes", timeout=10).content
File "/usr/lib/plexmediaserver/Resources/Plug-ins-5bd057d2b/Framework.bundle/Contents/Resources/Versions/2/Python/Framework/components/networking.py", line 242, in content
return self.__str__()
File "/usr/lib/plexmediaserver/Resources/Plug-ins-5bd057d2b/Framework.bundle/Contents/Resources/Versions/2/Python/Framework/components/networking.py", line 220, in __str__
self.load()
File "/usr/lib/plexmediaserver/Resources/Plug-ins-5bd057d2b/Framework.bundle/Contents/Resources/Versions/2/Python/Framework/components/networking.py", line 158, in load
f = self._opener.open(req, timeout=self._timeout)
File "/usr/lib/plexmediaserver/Resources/Python/python27.zip/urllib2.py", line 435, in open
response = meth(req, response)
File "/usr/lib/plexmediaserver/Resources/Python/python27.zip/urllib2.py", line 548, in http_response
'http', request, response, code, msg, hdrs)
File "/usr/lib/plexmediaserver/Resources/Python/python27.zip/urllib2.py", line 473, in error
return self._call_chain(*args)
File "/usr/lib/plexmediaserver/Resources/Python/python27.zip/urllib2.py", line 407, in _call_chain
result = func(*args)
File "/usr/lib/plexmediaserver/Resources/Python/python27.zip/urllib2.py", line 556, in http_error_default
raise HTTPError(req.get_full_url(), code, msg, hdrs, fp)
HTTPError: HTTP Error 404: Not Found Data for single channel from com.plex.agent.youtube.log: 2022-05-20 14:10:27,045 (7f1626e3bb38) : DEBUG (networking:143) - Requesting 'http://127.0.0.1:32400/library/metadata/226165/tree'
2022-05-20 14:10:27,053 (7f1626e3bb38) : INFO (__init__:165) - === update(lang=xn, force=True, movie=False) ===
2022-05-20 14:10:27,053 (7f1626e3bb38) : INFO (__init__:40) - /mnt/smb/youtube2/Don_t_Walk_Run_Productions [UCwpDBy43upJR7LZLrgnKkPA]/The_Press_vs_Trump_-_Volume_Three_The_Charlottesville_Lie [4jTf3CMbHrk].mp4
2022-05-20 14:10:27,054 (7f1626e3bb38) : INFO (__init__:509) - =============================================================================================================================================================
2022-05-20 14:10:27,054 (7f1626e3bb38) : INFO (__init__:252) - [ ] library: "YT"
2022-05-20 14:10:27,054 (7f1626e3bb38) : INFO (__init__:253) - [ ] root: "/mnt/smb/youtube2"
2022-05-20 14:10:27,054 (7f1626e3bb38) : INFO (__init__:254) - [ ] path: "Don_t_Walk_Run_Productions [UCwpDBy43upJR7LZLrgnKkPA]"
2022-05-20 14:10:27,054 (7f1626e3bb38) : INFO (__init__:255) - [ ] dir: "/mnt/smb/youtube2/Don_t_Walk_Run_Productions [UCwpDBy43upJR7LZLrgnKkPA]"
2022-05-20 14:10:27,054 (7f1626e3bb38) : INFO (__init__:260) - [ ] series_root_folder: "/mnt/smb/youtube2/Don_t_Walk_Run_Productions [UCwpDBy43upJR7LZLrgnKkPA]"
2022-05-20 14:10:27,056 (7f1626e3bb38) : INFO (__init__:263) - [ ] subfolder_count: "0"
2022-05-20 14:10:27,057 (7f1626e3bb38) : INFO (__init__:378) - Grouping folder not found or single folder, root: /mnt/smb/youtube2, path: Don_t_Walk_Run_Productions [UCwpDBy43upJR7LZLrgnKkPA], Grouping folder: Don_t_Walk_Run_Productions [UCwpDBy43upJR7LZLrgnKkPA], subdirs: 0, reverse_path: [u'Don_t_Walk_Run_Productions [UCwpDBy43upJR7LZLrgnKkPA]']
2022-05-20 14:10:27,057 (7f1626e3bb38) : INFO (__init__:400) - No GUID so random folder
2022-05-20 14:10:27,057 (7f1626e3bb38) : INFO (__init__:410) - =============================================================================================================================================================
Log file attachmentscom.plexapp.agents.youtube.log ASS Scanner Logs for channel I'm focusing on were empty so I can't attach them. Here are their names.
|
ok.I redownloaded my library again with better results. Since I started, I made the following changes
Channel Names , episode names, metadata, and images are all correct now. ( yay!) . However, I found a new problem. Youtube episodes released on the same day are absent. I had a case where 5 of them had the same modified date and none of them were discovered by the scanner., The Plex scanner log has the write number of episodes, but doesn't add them. This is my file naming convention, is correct? Or should I change it? I don't use playlist so there isn't a playlist id. The overall script looks like this I made the mistake of touching all of 24 file in a channel folder, and not only one is shown in Plex. So the scanner seems to be using the modified date and only allowing one episode per day. I tried a few things, but what got me results was adding MMDDhhmm to the file name. The scanner picks up these files and I see them in Plex. So I need a file naming format that makes both ASS and Youtube Agent happy. |
I resolved the episode issue with 2 changes
# generate random hour/minute
HH=$(( 1 + $RANDOM % 23))
MM=$((1 + $RANDOM % 60))
# change modified date using touch command
touch -m -t "${date_string}${HH}${MM}" "${DESTPATH}${FILENAME}" ASS will process all of the video files include those with identical release dates. I'm creating a dev environment to see if I come up with a way to have ASS handle identical release dates on it's own. Moving responsibility for this from the end user to the application. Btw, ASS/Youtube-Agent are great tools. I threw a donation the dev's way and recommend others do the same. I believe the root causes for the issue I ran into were the missing Plex token, the non-ascii characters, and duplicate release_dates on video files in the same series. |
Hello there, excellent work with the agent. Unfortunately it seems there's an issue with the channel metadata and thumbnail not appearing but episode metadata and thumbnails work fine.
--output "/Media/YouTube/%(uploader)s [%(channel_id)s]/%(upload_date>%Y-%m-%d)s - %(title)s [%(id)s].%(ext)s"
which resolves to/Media/YouTube/belle delphine [UCXvKUavCtDOlA8bT1i2tI3w]/2020-06-17 - I'M BACK -belle delphine [TL470fJMi7w].mkv
Screenshot of "Channel metadata and thumbnail not appearing"
Some channel metadata gets scraped apparently
Screenshot of "episode metadata and thumbnails working fine"
Log file with API key redacted
com.plexapp.agents.youtube.log
The text was updated successfully, but these errors were encountered: