smbaker / pynest

python API for talking to nest thermostat
165 stars 81 forks source link

Error with script #13

Open scott2000 opened 10 years ago

scott2000 commented 10 years ago

I wrote a program that relies on your script and recently (at 5:00 PM on 3/17) it stopped being able to get any data from the nest. The traceback is very similar to issue #12

Traceback (most recent call last):
  File "/Users/scott/Desktop/nest.py", line 239, in <module>
    main()
  File "/Users/scott/Desktop/nest.py", line 214, in main
    n.get_status()
  File "/Users/scott/Desktop/nest.py", line 77, in get_status
    res = urllib2.urlopen(req).read()
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 127, in urlopen
    return _opener.open(url, data, timeout)
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 404, in open
    response = self._open(req, data)
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 422, in _open
    '_open', req)
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 382, in _call_chain
    result = func(*args)
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 1222, in https_open
    return self.do_open(httplib.HTTPSConnection, req)
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 1184, in do_open
    raise URLError(err)
urllib2.URLError: \<urlopen error [Errno 8] _ssl.c:504: EOF occurred in violation of protocol>
digilord commented 10 years ago

I am getting this same error on OSX 10.9.2 & Python 2.7.5

wazime commented 10 years ago

I'm wondering if there is a way to fix this error. This script was amazing and I'd like to get it up and working again. Any help would be great.

digilord commented 10 years ago

I was able to repair it. I'll post a fix in the next few days.

wazime commented 10 years ago

sweet you rock.

digilord commented 10 years ago

I posted it as a pull request. Here is the link https://github.com/digilord/pynest

ronyoung commented 10 years ago

digilord,

I just tried to install your version of nest.py on my CentOS 5.10 server and got the below responses:

(root@myserver Linux) (/root/nestdigilord/pynest-master)$ ll Mon Apr 21 12:54:01 EDT 2014 total 24 -rw-r--r-- 1 root root 389 Apr 14 10:37 LICENSE.md -rw-r--r-- 1 root root 37 Apr 14 10:37 MANIFEST.in -rwxr-xr-x 1 root root 4023 Apr 14 10:37 nest.py drwxr-xr-x 2 root root 4096 Apr 14 10:37 nest_thermostat/ -rw-r--r-- 1 root root 1541 Apr 14 10:37 README.md -rwxr-xr-x 1 root root 531 Apr 14 10:37 setup.py

(root@myserver Linux) (/root/nestdigilord/pynest-master)$ pip install ./nest_thermostat Mon Apr 21 12:54:11 EDT 2014 Directory './nest_thermostat' is not installable. File 'setup.py' not found. Storing complete log in /root/.pip/pip.log

I am not a python programmer but had been using the pynest project successfully until sometime in March when it suddenly stopped working.

Can you please help me get it working again?

Ron

digilord commented 10 years ago

I don't have a CentOS server to test on. Can you file an issue in my repo with the contents of pip.log please?

Thank you!

youngrh commented 10 years ago

Done. Issue #15

Thanks for your help

Ron

Ron Young 919-621-9015 http://www.linkedin.com/in/ronhyoung

+++++++++++++++++++ Little tiny dreams require little tiny thoughts and little tiny steps. Great big dreams require great big thoughts and little tiny steps. +++++++++++++++++++

On Mon, Apr 21, 2014 at 1:01 PM, D. Allen Morrigan <notifications@github.com

wrote:

I don't have a CentOS server to test on. Can you file an issue in my repo with the contents of pip.log please?

Thank you!

— Reply to this email directly or view it on GitHubhttps://github.com/smbaker/pynest/issues/13#issuecomment-40952494 .

blindguyinanorgy commented 10 years ago

see issue #18 for the fix that worked for me