PlexConnect 0.7.3 - No Images and won't see Pillow

Everything has been running fine for a very long time now but with the latest PMS revision PlexConnect is no longer showing any of the thumbnails (only text for movies and tv shows). I upgraded PlexConnect to 0.7.3 hoping that would resolve the issue but it did not.

I also noticed that in the settings area it said PIL/Pillow not installed so I ensured that Pillow was indeed installed (used 6.0.0 for python 2.7.16). When I run sudo “/Applications/PlexConnect-master/PlexConnect.py” it sees Pillow just fine and shows the fan art but still no thumbnails for any media. However, when I launch PlexConnect via sudo launchctl load /Library/LaunchDaemons/com.plex.plexconnect.bash.plist it says PIL/Pillow is not installed.

So, to summarize:

  1. I would really like my thumbnails back and I’m not sure how to proceed to resolve this
  2. Running PlexConnect via launchctl does not find Pillow but running it via PlexConnect.py does

My settings.cfg is:

[PlexConnect]
enable_plexgdm = False
ip_pms = 127.0.0.1
port_pms = 32400
enable_dnsserver = True
port_dnsserver = 53
ip_dnsmaster = 8.8.8.8
prevent_atv_update = True
intercept_atv_icon = True
enable_plexconnect_autodetect = False
ip_plexconnect = 10.0.1.1
use_custom_dns_bind_ip = False
custom_dns_bind_ip = 0.0.0.0
hosttointercept = trailers.apple.com
icon = movie-trailers
certfile = ./assets/certificates/trailers.pem
port_webserver = 80
enable_webserver_ssl = True
port_ssl = 443
allow_gzip_atv = False
allow_gzip_pmslocal = False
allow_gzip_pmsremote = True
fanart_quality = High
loglevel = Normal
logpath = .

This is running on Mac OS X Big Sur 11.2.2

I think I was able to replicate the thumbnail problem. What happens in my case, with fanart enabled, is that thumbnails do not appear but when I select a movie the fanart appears. It will take me some time to diagnose and fix this.

Regarding running PlexConnect as a service not finding PIL, the log will tell if it’s using the same python version of the line mode command. If not you will need to edit PlexConnect_daemon.bash and, on line 22, specify the full path of your python install.

I solved the Pillow issue. It seems that since the LaunchDaemon runs as root, you must sudo to root and do a pip list to see the installed modules for root’s python home as they are apparently not global.

So, steps to resolve the Pillow issue:

  1. sudo su -
  2. Type your password
  3. pip list
  4. See if Pillow is installed (should be 6.2.2) and if it is not in the list
  5. pip install Pillow

Now when you start via the LaunchDaemon, Pillow will be found and FanArt will show.

Thumbnails are still all missing unfortunately. No thumbnails display for any media no matter if fanart is turned on or off.

Well here on my side, since the upgrade. I don’t get any thumbnails and I also get “An error occured loading this content. Try again later”. Basically Plexconnect stopped working :frowning:

DNS intercept works fine as the server starts normally.

"Jun 06,2021 23:04:30 PlexConnect: Started
Jun 06,2021 23:04:30 PlexConnect: Version: 0.7.3-280521
Jun 06,2021 23:04:30 PlexConnect: Python: 2.7.16 (default, Mar 25 2021, 03:11:28)
[GCC 4.2.1 Compatible Apple LLVM 11.0.3 (clang-1103.0.29.20) (-macos10.15-objc-
Jun 06,2021 23:04:30 PlexConnect: Host OS: darwin
Jun 06,2021 23:04:30 PlexConnect: PILBackgrounds: Is PIL installed? False
Jun 06,2021 23:04:30 PlexConnect: IP_self: 192.168.1.99
Jun 06,2021 23:04:30 DNSServer: Started
Jun 06,2021 23:04:30 DNSServer: Intercept Atv Icon: Enabled
Jun 06,2021 23:04:30 DNSServer: Prevent Atv Update: Enabled

"

As for PIL, same issue here running as daemon picks up version 2.7.16 with no PIL and running the sudo python PlexConnect.py command makes it run 2.7.18 and PIL is found?!?!? No server get discovered however when runnung the .py command.

I must say I’m confused.

I have tried @kittonian steps, and PILLOW 6.2.2 is really installed.

PlexConnect.log shows this however…
"Jun 06,2021 23:58:35 WebServer: Internal Server Error:
Traceback (most recent call last):
File “/Applications/PlexConnect/WebServer.py”, line 248, in do_GET
XML = XMLConverter.XML_PMS2aTV(PMSaddress, self.path + query, options)
File “/Applications/PlexConnect/XMLConverter.py”, line 399, in XML_PMS2aTV
PMS = PlexAPI.getXMLFromPMS(PMS_baseURL, path, options, auth_token, enableGzip)
File “/Applications/PlexConnect/PlexAPI.py”, line 449, in getXMLFromPMS
response = urllib2.urlopen(request, timeout=20)
File “/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py”, line 154, in urlopen
return opener.open(url, data, timeout)
File “/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py”, line 421, in open
protocol = req.get_type()
File “/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py”, line 283, in get_type
raise ValueError, “unknown url type: %s” % self.__original
ValueError: unknown url type: /library/sections/2

"

For Pillow to work correctly, you must not only install it as your own user, you must install it as root. To verify this, type pip list as your own user and verify that it is in the list of modules. Then sudo su - and type in your password to become the root user. Now type pip list again and it will show you the modules that are installed for use as the root user.

If you run PlexConnect via the launchdaemon script, PIL should now show installed as true.

I’m not sure what’s going on with your install where Plex won’t play your media, but I can assure you that with the latest PMS and 0.73 PlexConnect, media plays without issue. Perhaps removing everything and starting over? What about your settings.cfg file? Have you verified everything is properly configured?

What would be the best to install as root under MacOSX as Homebrew does not allow root install…?

You do not need to install anything new. Python is already on the system but the modules are installed per user. Simply follow my instructions and it will work. Nothing else needs to be done.

  1. Open Terminal
  2. pip list
    This will show you a list of the modules installed for your user account. Ensure Pillow is installed (it should be in the list, but if not, type pip install Pillow
  3. sudo su -
  4. Type your user password
  5. Now you are root and you are going to do the same thing you did for your user account
  6. pip list
    This will show you a list of the modules installed for the root user account. If Pillow is not in the list, do step 7. If it is, you’re all done.
  7. pip install Pillow

Hope that helps!

Thanks for taking the time to look into this.
for my user python version is 2.7.18 and pip list shows Pillow 6.2.2
for root I get the same version is 2.7.18 and pip list shows Pillow 6.2.2

Now the Console message shows the following:
"
Jun 07,2021 16:37:55 PlexConnect: Started
Jun 07,2021 16:37:55 PlexConnect: Version: 0.7.3-280521
Jun 07,2021 16:37:55 PlexConnect: Python: 2.7.16 (default, Mar 25 2021, 03:11:28)
[GCC 4.2.1 Compatible Apple LLVM 11.0.3 (clang-1103.0.29.20) (-macos10.15-objc-
Jun 07,2021 16:37:55 PlexConnect: Host OS: darwin
Jun 07,2021 16:37:55 PlexConnect: PILBackgrounds: Is PIL installed? False
"
Different Python version, plus PIL is not installed!?!

I must say I’m confused.

What would you suggest?

Claude

2.7.18 is not the default system python. The default is 2.7.16. This means you have installed another python version and PlexConnect is still trying to use the other 2.7.16 version. This also tells me that if you want it to use 2.7.18 you must set all your environment variables properly in order for the system to always use 2.7.18. Installing multiple versions of python is usually only done for very specific reasons, especially when it’s a minor revision like .16 to .18.

Fixing this for you is unfortunately beyond the scope of this forum, but now that I’ve explained what’s happening, hopefully you will be able to take it from here and get it cleaned up and working.

I’ve started to investigate the problem, but without much success. Here are my preliminar findings:

  1. If I don’t login to plex.tv all is ok (posters appear and play is ok)
  2. If I login to plex.tv neither posters nor play work

With my Python solution and logging in, content all plays just fine. If I don’t login it doesn’t see my Plex server because I have auto discovery disabled in settings.cfg

The new master version works perfectly. You should set it as an actual release on the Github page.

I am logged in, can see FanArt and all my thumbnails. Media plays perfectly too. Only thing I noticed was that I had to go into Settings and re-select everything I wanted to show/hide (no big deal). Thanks a bunch for fixing it!!!

1 Like

I see Pillow now… however I get this:
"
Jun 17,2021 17:25:07 PlexConnect: Started
Jun 17,2021 17:25:07 PlexConnect: Version: 0.7.3-110621
Jun 17,2021 17:25:07 PlexConnect: Python: 2.7.16 (default, Mar 25 2021, 03:11:28)
[GCC 4.2.1 Compatible Apple LLVM 11.0.3 (clang-1103.0.29.20) (-macos10.15-objc-
Jun 17,2021 17:25:07 PlexConnect: Host OS: darwin
Jun 17,2021 17:25:07 PlexConnect: PILBackgrounds: Is PIL installed? True
Jun 17,2021 17:25:07 PlexConnect: IP_self: 192.168.1.99
Jun 17,2021 17:25:07 DNSServer: Started
Jun 17,2021 17:25:07 DNSServer: Intercept Atv Icon: Enabled
Jun 17,2021 17:25:07 DNSServer: Prevent Atv Update: Enabled
Jun 17,2021 17:25:07 DNSServer: ***
Jun 17,2021 17:25:07 DNSServer: DNSServer: Serving DNS on 192.168.1.99 port 53.
Jun 17,2021 17:25:07 DNSServer: ***
Jun 17,2021 17:25:07 WebServer: Started
Jun 17,2021 17:25:07 WebServer: ***
Jun 17,2021 17:25:07 WebServer: WebServer: Serving HTTP on 192.168.1.99 port 80.
Jun 17,2021 17:25:07 WebServer: ***
Jun 17,2021 17:25:08 WebServer: Started
Jun 17,2021 17:25:08 WebServer: ***
Jun 17,2021 17:25:08 WebServer: WebServer: Serving HTTPS on 192.168.1.99 port 443.
Jun 17,2021 17:25:08 WebServer: ***
Jun 17,2021 17:25:14 WebServer: File Not Found:
Traceback (most recent call last):
File “/Applications/PlexConnect/WebServer.py”, line 264, in do_GET
self.sendResponse(f.read(), ‘text/html’, False)
File “/Applications/PlexConnect/WebServer.py”, line 95, in sendResponse
self.wfile.write(data)
File “/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/socket.py”, line 328, in write
self.flush()
File “/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/socket.py”, line 307, in flush
self._sock.sendall(view[write_offset:write_offset+buffer_size])
error: [Errno 41] Protocol wrong type for socket
"

any ideas what is wrong?

Try installing python from here

Tried that. For some reason the error is gone from the log but I still don’t get any thumbnails but fanart do work. When trying to play I get " An error occurred loading this content." without any error shoing in the log.

The daemon keeps loading OSX initial version 2.7.16 of python (maybe this one is broken on my side). Installing the package you pointed out (2.7.18) installs it for the user…

I must say I’m lost. don’t really want to reinstall the whole OS because I can’t “reset” it’s python installation.

I’m all ears if you have ideas.

THANKS

Ok I have tried this.
1- re-installed Python by following those instructions from iBaa’s PlexConnect Wiki. (link in wiki gives 404 error, had to use web archive to get the content.
https://web.archive.org/web/20150311052927/http://wolfpaulus.com/jounal/mac/installing_python_osx/

2- Since I’m on OS X 10.15 Catalina, I have to disable SIP

3- Also had to remove readonly to complete Python install
sudo mount -uw /
killall Finder

4- Re-installed PlexConnect
5- Did certificate procedure once again
6- Logged in plexconnect settings on AppleTV with my plex credentials

I now have python 2.7.18 with PIL installed and getting loaded even with system daemon. Yeah!

“Jun 18,2021 21:11:23 PlexConnect: Started
Jun 18,2021 21:11:23 PlexConnect: Version: 0.7.3-280521
Jun 18,2021 21:11:23 PlexConnect: Python: 2.7.18 (v2.7.18:8d21aa21f2, Apr 19 2020, 20:48:48)
[GCC 4.2.1 Compatible Apple LLVM 6.0 (clang-600.0.57)]
Jun 18,2021 21:11:23 PlexConnect: Host OS: darwin
Jun 18,2021 21:11:23 PlexConnect: PILBackgrounds: Is PIL installed? True
Jun 18,2021 21:11:23 PlexConnect: IP_self: 192.168.1.99
Jun 18,2021 21:11:23 DNSServer: Started
Jun 18,2021 21:11:23 DNSServer: Intercept Atv Icon: Enabled
Jun 18,2021 21:11:23 DNSServer: Prevent Atv Update: Enabled
Jun 18,2021 21:11:23 DNSServer: ***
Jun 18,2021 21:11:23 DNSServer: DNSServer: Serving DNS on 192.168.1.99 port 53.
Jun 18,2021 21:11:23 DNSServer: ***
Jun 18,2021 21:11:23 WebServer: Started
Jun 18,2021 21:11:23 WebServer: ***
Jun 18,2021 21:11:23 WebServer: WebServer: Serving HTTP on 192.168.1.99 port 80.
Jun 18,2021 21:11:23 WebServer: ***
Jun 18,2021 21:11:23 WebServer: Started
Jun 18,2021 21:11:23 WebServer: ***
Jun 18,2021 21:11:23 WebServer: WebServer: Serving HTTPS on 192.168.1.99 port 443.
Jun 18,2021 21:11:23 WebServer: ***
Jun 18,2021 21:11:42 PlexAPI: ***
Jun 18,2021 21:11:42 PlexAPI: PlexGDM - looking up Plex Media Server
Jun 18,2021 21:11:42 PlexAPI: ***
Jun 18,2021 21:11:43 PlexAPI: GDM: Servers discovered: 1
Jun 18,2021 21:11:43 PlexAPI: Plex Media Servers found: 1
Jun 18,2021 21:14:50 PlexAPI: MyPlex Sign In successfull
Jun 18,2021 21:14:50 PlexAPI: ***
Jun 18,2021 21:14:50 PlexAPI: poke plex.tv - request Plex Media Server list”

Still I can’t see thumbnails
I see Fanart
Movies won’t load. I get error “An error occured loading this content…”

I’m willing to assist and provide any information to get this fixed.

Thanks

Claude

Updated to 0.7.3-110621
Still no luck
No thumbnails - can’t play movies.

I’ve applied a temporary fix, can you pls test ? It’s not published as a release, you have to download a zip from

https://github.com/iBaa/PlexConnect/archive/refs/heads/master.zip

Tried the fix. No luck still
AppleTV A1427 - Software version: 7.7 (8153)
Plexconnect version: 0.7.3a-200621
Python version: 2.7.18
PIL is detected - Fanart shows
Thumbnails not showing, same for main library page (covers slideshow, not showing)
Unable to play anything - “An error occured loading this content…”

If you need more output from the log I could provide that if needed.

Thanks

Claude

At this point I need logs with loglevel = High in Settings.cfg. My ATV3 is A1469 with fw iOS/8.4.4 AppleTV/7.6.2