2021-02-11, 23:23
Thanks. Posted on the Emby Forum
(2021-02-11, 23:23)LongMan Wrote: Thanks. Posted on the Emby ForumThanks. I just gave it a quick spin and something is wrong with the behaviour of the settings in the media import info dialog. It doesn't properly update the setting controls when switching from "Local" to "Emby Connect" authentication or when switching from "Local" to "MyPlex" authentication. So this must be something in Kodi core. Maybe I broke something in my rework because I made some minor changes there. If someone runs into these issues just perform the Emby Connect / MyPlex login procedure and then save and close the dialog even if it hasn't been properly updated. When you re-open it everything will look fine. So the settings are stored properly but the dialog is not updated as expected.
mediaimporter.emby
to 0.0.11
. This contains2021-02-13 14:14:35.893 T:1392 DEBUG <general>: [mediaimporter.plex] failed to connect to 'MediaServer' at http://192.168.0.5:32400
2021-02-13 14:23:04.645 T:16508 ERROR <general>: EXCEPTION Thrown (PythonToCppException) : -->Python callback/script returned the following error<--
- NOTE: IGNORING THIS CAN LEAD TO MEMORY LEAKS!
Error Type: <class 'xml.etree.ElementTree.ParseError'>
Error Contents: not well-formed (invalid token): line 2, column 27
Traceback (most recent call last):
File "C:\Users\kompl\AppData\Roaming\Kodi\addons\mediaimporter.plex\importer.py", line 20, in <module>
importer.run(sys.argv)
File "C:\Users\kompl\AppData\Roaming\Kodi\addons\mediaimporter.plex\lib\importer.py", line 1176, in run
actionMethod(handle, options)
File "C:\Users\kompl\AppData\Roaming\Kodi\addons\mediaimporter.plex\lib\importer.py", line 541, in discoverProvider
provider = discoverProviderLocally(handle, options)
File "C:\Users\kompl\AppData\Roaming\Kodi\addons\mediaimporter.plex\lib\importer.py", line 199, in discoverProviderLocally
plexServer = PlexServer(baseUrl, timeout=plex.constants.REQUEST_TIMEOUT)
File "C:\Users\kompl\AppData\Roaming\Kodi\addons\mediaimporter.plex\plexapi\server.py", line 104, in __init__
data = self.query(self.key, timeout=timeout)
File "C:\Users\kompl\AppData\Roaming\Kodi\addons\mediaimporter.plex\plexapi\server.py", line 438, in query
return ElementTree.fromstring(data) if data.strip() else None
File "C:\Program Files\Kodi\system\python\Lib\xml\etree\ElementTree.py", line 1320, in XML
parser.feed(text)
File "<string>", line None
xml.etree.ElementTree.ParseError: not well-formed (invalid token): line 2, column 27
-->End of Python script error report<--
2021-02-13 14:23:04.645 T:16508 DEBUG <general>: CPythonInvoker::onExecutionDone(14, C:\Users\kompl\AppData\Roaming\Kodi\addons\mediaimporter.plex\importer.py)
(2021-02-14, 01:39)LongMan Wrote: @komplex, Thanks for testing and providing feedback.
Since you are already aware of the problem, can you provide some more details about the problem and how it was addressed. Pointing to the code changes could also be useful.
Cheers,
LongMan
(2021-02-13, 16:30)komplex Wrote: Gave this another go, still have issues. It adds my Plex account fine but fails when adding the server.Thanks for your report. Unfortunately there are two issues at hand:
Code:2021-02-13 14:14:35.893 T:1392 DEBUG <general>: [mediaimporter.plex] failed to connect to 'MediaServer' at http://192.168.0.5:32400
It fails to add it because 192.168.0.5:32400 doesn't open plex, it would be http://192.168.0.5/plex which redirects to https://mydomain/plex/web/index.html. I have nginx reverse proxy.
@anxdpanic fixed a similar issue when I was testing Composite. If I try to use the Local Only part and add http://192.168.0.5/plex it throws an error
Code:2021-02-13 14:23:04.645 T:16508 ERROR <general>: EXCEPTION Thrown (PythonToCppException) : -->Python callback/script returned the following error<--
- NOTE: IGNORING THIS CAN LEAD TO MEMORY LEAKS!
Error Type: <class 'xml.etree.ElementTree.ParseError'>
Error Contents: not well-formed (invalid token): line 2, column 27
Traceback (most recent call last):
File "C:\Users\kompl\AppData\Roaming\Kodi\addons\mediaimporter.plex\importer.py", line 20, in <module>
importer.run(sys.argv)
File "C:\Users\kompl\AppData\Roaming\Kodi\addons\mediaimporter.plex\lib\importer.py", line 1176, in run
actionMethod(handle, options)
File "C:\Users\kompl\AppData\Roaming\Kodi\addons\mediaimporter.plex\lib\importer.py", line 541, in discoverProvider
provider = discoverProviderLocally(handle, options)
File "C:\Users\kompl\AppData\Roaming\Kodi\addons\mediaimporter.plex\lib\importer.py", line 199, in discoverProviderLocally
plexServer = PlexServer(baseUrl, timeout=plex.constants.REQUEST_TIMEOUT)
File "C:\Users\kompl\AppData\Roaming\Kodi\addons\mediaimporter.plex\plexapi\server.py", line 104, in __init__
data = self.query(self.key, timeout=timeout)
File "C:\Users\kompl\AppData\Roaming\Kodi\addons\mediaimporter.plex\plexapi\server.py", line 438, in query
return ElementTree.fromstring(data) if data.strip() else None
File "C:\Program Files\Kodi\system\python\Lib\xml\etree\ElementTree.py", line 1320, in XML
parser.feed(text)
File "<string>", line None
xml.etree.ElementTree.ParseError: not well-formed (invalid token): line 2, column 27
-->End of Python script error report<--
2021-02-13 14:23:04.645 T:16508 DEBUG <general>: CPythonInvoker::onExecutionDone(14, C:\Users\kompl\AppData\Roaming\Kodi\addons\mediaimporter.plex\importer.py)
mediaimporter.plex
uses python-plexapi to communicate with PMS. All I can do is pass it a base URL and after that I don't have any influence over what happens. I can bring the topic up with them but without being able to reproduce the issue myself it's hard to provide feedback. Can you send me your nginx reverse proxy setup for PMS so I can try to replicate it?(2021-02-14, 22:48)Montellese Wrote: Can you send me your nginx reverse proxy setup for PMS so I can try to replicate it?
php:
# Plex Reverse Proxy
location /plex/ {
include /nginx/conf/errorV2.conf;
auth_request /auth-4;
proxy_pass http://127.0.0.1:32400/;
add_header X-Frame-Options "SAMEORIGIN";
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
#Websockets
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "upgrade";
proxy_read_timeout 36000s;
proxy_next_upstream error timeout invalid_header http_500 http_502 http_503 http_504;
}
if ($http_referer ~* /plex/) {
rewrite ^/web/(.*) /plex/web/$1? redirect;
}
location ~ /auth-(.*) {
rewrite ^/auth-(.*) /api/v2/auth?group=$1;
} #Org Auth
(2021-02-15, 09:02)Lorddeff Wrote: This is very interesting. Like Pkc on steroids.
(2021-02-15, 10:41)webmaher Wrote:@Lorddeff is interested in Kodi to Kodi Sharing. He wants to avoid Plex.(2021-02-15, 09:02)Lorddeff Wrote: This is very interesting. Like Pkc on steroids.
do you try import lets just say over 10k episodes from Plex... see here
https://forum.kodi.tv/showthread.php?tid...pid3001112
Quote:Is there anything we can support you? @LongMan maybe we can try to regularly provide LE builds with Media Importing enabled.I have been able to build for Generic and Pi4. Haven't tried the others. Not too familiar with hosting though.
Quote:Is there a partial job for Media Importing that could be accomplished by a student? Maybe Media Importing could participate at GSoC 2021.Maybe music importing.
(2021-02-15, 11:18)LongMan Wrote:Yup. As is, I have been using plex for over a year or two. But back on Kodi, plex does some strange shit. First, it insists on transcoding stuff that your native device may even be able to play and then it will not work well without an internet connection.(2021-02-15, 10:41)webmaher Wrote:@Lorddeff is interested in Kodi to Kodi Sharing. He wants to avoid Plex.(2021-02-15, 09:02)Lorddeff Wrote: This is very interesting. Like Pkc on steroids.
do you try import lets just say over 10k episodes from Plex... see here
https://forum.kodi.tv/showthread.php?tid...pid3001112