AppleTV Plugin not finding any devices

Posted on
Fri Jun 11, 2021 9:25 am
kw123 offline
User avatar
Posts: 8333
Joined: May 12, 2013
Location: Dallas, TX

Re: AppleTV Plugin not finding any devices

yes you might be right, I did install Xcode on my indigo client
Code: Select all
/usr/bin/xcodebuild -version
Xcode 12.5
Build version 12E262
I will update my how to post
Karl

Posted on
Fri Jun 11, 2021 10:49 am
danieljmorel offline
Posts: 42
Joined: Dec 11, 2016

Re: AppleTV Plugin not finding any devices

After entering the 1st commands into terminal and restarting my computer, here is what I got for the which and --versions commands I received in terminal:
djm@WorkOutNW ~ % which python
which python3
python --version
python3 --version
/usr/bin/python
/usr/bin/python3
Python 2.7.16
Python 3.8.2
djm@WorkOutNW ~ %

Posted on
Fri Jun 11, 2021 11:33 am
autolog offline
Posts: 3988
Joined: Sep 10, 2013
Location: West Sussex, UK [GMT aka UTC]

Re: AppleTV Plugin not finding any devices

Looks like you are all set then?

The python versions 2.7.16 and 3.8.2 look like the Mac versions as they are using the system /usr/bin/ directories.

Posted on
Fri Jun 11, 2021 11:39 am
autolog offline
Posts: 3988
Joined: Sep 10, 2013
Location: West Sussex, UK [GMT aka UTC]

Re: AppleTV Plugin not finding any devices

kw123 wrote:
yes you might be right, I did install Xcode on my indigo client
Code: Select all
/usr/bin/xcodebuild -version
Xcode 12.5
Build version 12E262
I will update my how to post
Karl

Actually Karl, I think are correct about python 3 being installed by default on MacOS Big Sur. :oops:

I can confirm that is isn't in the beta of MacOS Monterey which I installed on my MacBook Pro this morning..

When you type python3 into a terminal session on MacOS Monterey, it asks if you want to install Xcode developer tools.
When you do that, python 3 is installed (same version 3.8.2) as part of the Xcode Developer Tools install.

So it looks like it is changing (as they said it would) for the next version of MacOS. :)

Posted on
Fri Jun 11, 2021 12:11 pm
jay (support) offline
Site Admin
User avatar
Posts: 18200
Joined: Mar 19, 2008
Location: Austin, Texas

Re: AppleTV Plugin not finding any devices

autolog wrote:
When you type python3 into a terminal session on MacOS Monterey, it asks if you want to install Xcode developer tools.
When you do that, python 3 is installed (same version 3.8.2) as part of the Xcode Developer Tools install.)


I'm maybe 80% sure that this is the way it works in Big Sur as well. My Big Sur install has 2 version of Python 3 installed, but neither is the version that you guys are referencing. Both are in fact versions I explicitly installed from python.org (via their respective installers). I surmise that I didn't run the python3 command BEFORE I manually installed those other versions, so therefore didn't get prompted to install from the developer tools. Again, I'm not positive, but I'm pretty sure that's what happened.

Code: Select all
MightyMini-2:bin jay$ ls /Library/Frameworks/Python.framework/Versions/
3.6   3.7

Jay (Indigo Support)
Twitter | Facebook | LinkedIn

Posted on
Fri Jun 11, 2021 7:57 pm
danieljmorel offline
Posts: 42
Joined: Dec 11, 2016

Re: AppleTV Plugin not finding any devices

so I tried to scan for new devices and I still get:
11 21:56:35 =========getscriptScan out:('', 'Traceback (most recent call last):\n File "/Library/Application Support/Perceptive Automation/Indigo 7.5/Plugins/appleTV.indigoPlugin/Contents/Server Plugin/atvscript.py", line 13, in <module>\n from pyatv import connect, const, scan\nModuleNotFoundError: No module named \'pyatv\'\n')
11 21:56:35 =========getNewDevices scan result:{}
11 21:56:45 in loop #4
any other suggestions or opinions?

Posted on
Fri Jun 11, 2021 9:11 pm
kw123 offline
User avatar
Posts: 8333
Joined: May 12, 2013
Location: Dallas, TX

Re: AppleTV Plugin not finding any devices

could you open a terminal and copy and paste
Code: Select all
python3
from pyatv import connect

exit()
you should either see:
Code: Select all
:python3
Python 3.8.2 (default, Apr  8 2021, 23:19:18)
[Clang 12.0.5 (clang-1205.0.22.9)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> from pyatv import connect

exit()
>>>
>>> exit()
or
Code: Select all
python3
Python 3.8.2 (default, Apr  8 2021, 23:19:18)
[Clang 12.0.5 (clang-1205.0.22.9)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> from pyatvx import connect
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
ModuleNotFoundError: No module named 'pyatv'
>>>
>>> exit()

if you see the second option, the installation is different: my problem.
if you see the first one, your setup is screwy

Karl

Posted on
Sat Jun 12, 2021 6:58 am
danieljmorel offline
Posts: 42
Joined: Dec 11, 2016

Re: AppleTV Plugin not finding any devices

Sorry Karl. Looks like the second one:
djm@WorkOutNW ~ % python3
Python 3.8.2 (default, Apr 8 2021, 23:19:18)
[Clang 12.0.5 (clang-1205.0.22.9)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> from pyatv import connect
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
ModuleNotFoundError: No module named 'pyatv'
>>> exit()
djm@WorkOutNW ~ %

Posted on
Sat Jun 12, 2021 7:01 am
danieljmorel offline
Posts: 42
Joined: Dec 11, 2016

Re: AppleTV Plugin not finding any devices

I did notice that yours said:

from pyatvx import connect

where my just says: (no "x")

from pyatv import connect

Posted on
Sat Jun 12, 2021 7:35 am
autolog offline
Posts: 3988
Joined: Sep 10, 2013
Location: West Sussex, UK [GMT aka UTC]

Re: AppleTV Plugin not finding any devices

To help out with testing, I have just installed the plugin. :)

I was having difficulties getting it to scan for my Apple TV; it wasn't finding it.

So I executed the python 3 atvscript.py script in a terminal window.
Doing this, I am also getting the error:
ModuleNotFoundError: No module named 'pyatv'

Looking at the plugin contents, I can't see that it is included. :|

Posted on
Sat Jun 12, 2021 7:37 am
kw123 offline
User avatar
Posts: 8333
Joined: May 12, 2013
Location: Dallas, TX

Re: AppleTV Plugin not finding any devices

There seems to be a new version on git hub for atv.

I will download it and check what has changed.


Sent from my iPhone using Tapatalk

Posted on
Sat Jun 12, 2021 7:54 am
danieljmorel offline
Posts: 42
Joined: Dec 11, 2016

Re: AppleTV Plugin not finding any devices

could this be part of the problem? When I open a terminal window and change the directory to /usr/bin and do an ls I get:
djm@WorkOutNW ~ % cd /usr
djm@WorkOutNW /usr % ls
X11 bin libexec sbin standalone
X11R6 lib local share
djm@WorkOutNW /usr % cd /bin
djm@WorkOutNW /bin % ls
[ dd launchctl pwd test
bash df link rm unlink
cat echo ln rmdir wait4path
chmod ed ls sh zsh
cp expr mkdir sleep
csh hostname mv stty
dash kill pax sync
date ksh ps tcsh
djm@WorkOutNW /bin %


No Python3 listed however Indigo thinks that it in that directory because the configuration does not say "does not exist"

When I go to finder and go to /usr/bin I see Python3 and when I double click it, it opens but I get:
Last login: Sat Jun 12 09:43:11 on ttys001
/usr/bin/python3 ; exit;
djm@WorkOutNW ~ % /usr/bin/python3 ; exit;
Python 3.8.2 (default, Apr 8 2021, 23:19:18)
[Clang 12.0.5 (clang-1205.0.22.9)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>>

This is very similar to the 1st option that was said to be screwy.

Do I need to re-install Python 3.8.2? If so, is it possible? How?

Posted on
Sat Jun 12, 2021 7:58 am
danieljmorel offline
Posts: 42
Joined: Dec 11, 2016

Re: AppleTV Plugin not finding any devices

Please excuse my newbness and the formatting on that last post. Please let me know if you would like me to stop poking around. I really do appreciate all the help on this. Thank you!

Posted on
Sat Jun 12, 2021 8:25 am
kw123 offline
User avatar
Posts: 8333
Joined: May 12, 2013
Location: Dallas, TX

Re: AppleTV Plugin not finding any devices

right now it have to check out the new version of atv

I will post a new version of the plugin that supports the new atv

wait until then

Karl

Posted on
Sat Jun 12, 2021 10:59 am
kw123 offline
User avatar
Posts: 8333
Joined: May 12, 2013
Location: Dallas, TX

Re: AppleTV Plugin not finding any devices

please try V 1.1.14

you might need to add some additional pip3 installs

sudo pip3 install pendulum
sudo pip3 install bidict
sudo pip3 install more_itertools
sudo pip3 install bitstruct

Who is online

Users browsing this forum: No registered users and 1 guest