GithubHelp home page GithubHelp logo

pyloopenergy's People

Contributors

pavoni avatar tocklime avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

pyloopenergy's Issues

Loses connection after some period of days.

Looks like running for a long period (several days) can result in some sort of disconnection that isn't caught.

Perhaps add a watchdog timer that restarts if no updates are seen for 5 minutes.

Also look at running for a long period in a debug environment to see of there are any log messages

Exception in new socket code after some time

python demo.py                                                                                                                  โŽ
Electricity = 0.456
Gas = 0.0
Electricity = 0.453
Electricity = 0.46
Electricity = 0.456
Exception in thread LoopEnergy Event Thread:
Traceback (most recent call last):
 File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/threading.py", line 917, in _bootstrap_inner
   self.run()
 File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/threading.py", line 865, in run
   self._target(*self._args, **self._kwargs)
 File "/Users/greg/ha/pyloopenergy/pyloopenergy/loop_energy.py", line 168, in _run_event_thread
   socket_io.wait(seconds=WAIT_BEFORE_POLL)
 File "/Users/greg/ha/pyloopenergy/env/lib/python3.7/site-packages/socketIO_client_nexus/__init__.py", line 251, in wait
   self._process_packets()
 File "/Users/greg/ha/pyloopenergy/env/lib/python3.7/site-packages/socketIO_client_nexus/__init__.py", line 276, in _process_packets
   for engineIO_packet in self._transport.recv_packet():
 File "/Users/greg/ha/pyloopenergy/env/lib/python3.7/site-packages/socketIO_client_nexus/transports.py", line 158, in recv_packet
   packet_text)
 File "/Users/greg/ha/pyloopenergy/env/lib/python3.7/site-packages/socketIO_client_nexus/parsers.py", line 96, in parse_packet_text
   packet_type = int(get_character(packet_text, 0))
 File "/Users/greg/ha/pyloopenergy/env/lib/python3.7/site-packages/socketIO_client_nexus/symmetries.py", line 33, in get_character
   return chr(get_byte(x, index))
 File "/Users/greg/ha/pyloopenergy/env/lib/python3.7/site-packages/socketIO_client_nexus/symmetries.py", line 29, in get_byte
   return indexbytes(x, index)
IndexError: index out of range

Unknown Exception

Exception in thread LoopEnergy Event Thread:
Traceback (most recent call last):
  File "/usr/lib/python2.7/threading.py", line 801, in __bootstrap_inner
    self.run()
  File "/usr/lib/python2.7/threading.py", line 754, in run
    self.__target(*self.__args, **self.__kwargs)
  File "/usr/local/lib/python2.7/dist-packages/pyloopenergy-0.0.13-py2.7.egg/pyloopenergy/loop_energy.py", line 133, in _run_event_thread
    Namespace) as socket_io:
  File "/usr/local/lib/python2.7/dist-packages/socketIO_client-0.5.6-py2.7.egg/socketIO_client/__init__.py", line 206, in __init__
    self.define(Namespace)
  File "/usr/local/lib/python2.7/dist-packages/socketIO_client-0.5.6-py2.7.egg/socketIO_client/__init__.py", line 223, in define
    namespace = Namespace(self._transport, path)
  File "/usr/local/lib/python2.7/dist-packages/socketIO_client-0.5.6-py2.7.egg/socketIO_client/__init__.py", line 320, in _transport
    socketIO_session = self._get_socketIO_session()
  File "/usr/local/lib/python2.7/dist-packages/socketIO_client-0.5.6-py2.7.egg/socketIO_client/__init__.py", line 348, in _get_socketIO_session
    self.is_secure, self._base_url, **self._kw)
  File "/usr/local/lib/python2.7/dist-packages/socketIO_client-0.5.6-py2.7.egg/socketIO_client/__init__.py", line 522, in _get_socketIO_session
    heartbeat_timeout=int(response_parts[1]),
ValueError: invalid literal for int() with base 10: '100%;             background'

Exception ValueError: ValueError("invalid literal for int() with base 10: '100%;             background'",) in <bound method SocketIO.__del__ of <socketIO_client.SocketIO object at 0x7f842e7323d0>> ignored

Memory / handle leak since uograde to Socket IO 2.0

Since upgrading to the new version of Socket IO, there is some sort of memory or handle leak.

This eventually caused problem on the machine running the code.

I think it's in the code that recovers from disconnections (it seems to be stable where the network connection is stable).

Best workround for now is to restart regularly - but it's far from ideal!

Exception in thread LoopEnergy Event Thread

I've tried running the sample code and am getting;

Exception in thread LoopEnergy Event Thread: Traceback (most recent call last): File "/usr/lib/python2.7/threading.py", line 810, in __bootstrap_inner self.run() File "/usr/lib/python2.7/threading.py", line 763, in run self.__target(*self.__args, **self.__kwargs) File "/home/pi/pyloopenergy/pyloopenergy/loop_energy.py", line 134, in _run_event_thread Namespace) as socket_io: File "/usr/local/lib/python2.7/dist-packages/socketIO_client/__init__.py", line 353, in __init__ resource, hurry_interval_in_seconds, **kw) File "/usr/local/lib/python2.7/dist-packages/socketIO_client/__init__.py", line 54, in __init__ self._transport File "/usr/local/lib/python2.7/dist-packages/socketIO_client/__init__.py", line 62, in _transport self._engineIO_session = self._get_engineIO_session() File "/usr/local/lib/python2.7/dist-packages/socketIO_client/__init__.py", line 76, in _get_engineIO_session transport.recv_packet()) StopIteration

Doesn't re-connect after failure

16-04-01 21:14:38 socketIO_client: [connection error] [Errno 60] Operation timed out
16-04-01 21:14:39 pyloopenergy.loop_energy: Disconnected from https://www.your-loop.com, will retry
16-04-01 21:14:39 socketIO_client: [connection error] connection closed (Connection is already closed.)
16-04-01 21:14:40 pyloopenergy.loop_energy: Disconnected from https://www.your-loop.com, will retry

No handlers could be found

I'm getting an error: No handlers could be found for logger "pyloopenergy.loop_energy"

Exception in thread LoopEnergy Event Thread:
Traceback (most recent call last):
  File "/usr/lib/python2.7/threading.py", line 801, in __bootstrap_inner
    self.run()
  File "/usr/lib/python2.7/threading.py", line 754, in run
    self.__target(*self.__args, **self.__kwargs)
  File "build/bdist.linux-x86_64/egg/pyloopenergy/loop_energy.py", line 165, in _run_event_thread
    LOG.debug('LoopEnergy thread poll')
  File "/usr/local/lib/python2.7/dist-packages/socketIO_client-0.5.6-py2.7.egg/socketIO_client/__init__.py", line 215, in __exit__
    self.disconnect()
  File "/usr/local/lib/python2.7/dist-packages/socketIO_client-0.5.6-py2.7.egg/socketIO_client/__init__.py", line 299, in disconnect
    namespace.on_disconnect()
  File "build/bdist.linux-x86_64/egg/pyloopenergy/loop_energy.py", line 123, in on_disconnect
    self.terminate()
  File "build/bdist.linux-x86_64/egg/pyloopenergy/loop_energy.py", line 230, in terminate
    self._event_thread.join()
  File "/usr/lib/python2.7/threading.py", line 931, in join
    raise RuntimeError("cannot join current thread")
RuntimeError: cannot join current thread

High/erroneous reads being received

I've integrated pyloopenergy with Domoticz to provide realtime gas and electricity consumption to my home automation platform but at the moment it is plagued with reads which are off the scale in terms of what I would expect, at least one read per hour from the electricity feed and one every couple of hours from the gas feed.

The values are unique in their appearance - they all have the value 18 446 744 073 709 552 000 Wh

My integration simply takes your sample script (with both gas and electricity enabled) which I've added a line to call the Domoticz web service using Python (I simply pass the value from your script to the Domoticz URL on my network and Domoticz registers that read).

Do you have any idea what this strangely random value might be that the service is returning?

division by zero for gas useage

The period calculation is causing problems:

Period is calculated as 0 - is this line correct:
period = (self.gas_device_timestamp - self.gas_old_timestamp)/(60*60)

variables:
('Electricity =', 1.0)
('Gas Used =', 80)
('self.gas_device_timestamp =', 1460049300)
('self.gas_old_timestamp =', 1460048400)
('period =', 0)

error:
Exception in thread LoopEnergy Event Thread:
Traceback (most recent call last):
File "/usr/lib64/python2.7/threading.py", line 801, in *bootstrap_inner
self.run()
File "/usr/lib64/python2.7/threading.py", line 754, in run
self.__target(_self.__args, _self.__kwargs)
File "/boot/config/plugins/hive2mqtt/pyloopenergy/loop_energy.py", line 134, in _run_event_thread
socket_io.wait(seconds=15)
File "/usr/lib64/python2.7/site-packages/socketIO_client/__init
.py", line 252, in wait
self._process_events(timeout)
File "/usr/lib64/python2.7/site-packages/socketIO_client/init.py", line 271, in _process_events
self._process_packet(packet)
File "/usr/lib64/python2.7/site-packages/socketIO_client/init.py", line 279, in _process_packet
delegate(packet, namespace._find_event_callback)
File "/usr/lib64/python2.7/site-packages/socketIO_client/init.py", line 444, in _on_event
find_event_callback(event)(*args)
File "/boot/config/plugins/hive2mqtt/pyloopenergy/loop_energy.py", line 190, in _update_gas
self.gas_kw = (CONVERSION_FACTOR * gas_used / period)/1000
ZeroDivisionError: float division by zero

Feature request: Expose the gas_used value directly

In my home assistant, I'm using the loop energy sensor to monitor my gas and electric. I use the integration sensor to recover 'total energy used ever', and then the utility_meter sensor to get 'kWh used today'. The integration sensor works great for the constantly varying electricity, but is quite inaccurate over the slowly updating gas.

It looks like pyloopenergy actually receives the total used (current gas meter reading?) and then calculates a current rate from that.

I think it would be useful to also expose the gas meter reading so that I don't need to do the kWh -> kW -> kWh conversions I'm doing at the moment (and having true gas meter reading in home assistant would be super useful when I submit my meter readings to the energy company).

What do you think?

I see you're not very active on this project. I'd be interested in putting a pull request together if you think it would be useful.

Conversion value

How do I work out the conversion value, any tips?. My reading is 2.83 x higher on Loop dashboard than the value... Do I just fudge it or is there a more scientific way? :-)

Exception after long run kills monitor thread.

WARNING:socketIO_client:[connection error] connection closed (Connection is already closed.)
WARNING:socketIO_client:www.your-loop.com:443/socket.io/1: [connection error] connection closed (Connection is already closed.)
INFO:requests.packages.urllib3.connectionpool:Starting new HTTPS connection (1): www.your-loop.com
Exception in thread LoopEnergy Event Thread:
Traceback (most recent call last):
  File "/usr/local/Cellar/python3/3.5.1/Frameworks/Python.framework/Versions/3.5/lib/python3.5/threading.py", line 914, in _bootstrap_inner
    self.run()
  File "/usr/local/Cellar/python3/3.5.1/Frameworks/Python.framework/Versions/3.5/lib/python3.5/threading.py", line 862, in run
    self._target(*self._args, **self._kwargs)
  File "/usr/local/lib/python3.5/site-packages/pyloopenergy/loop_energy.py", line 165, in _run_event_thread
    LOG.debug('LoopEnergy thread poll')
  File "/usr/local/lib/python3.5/site-packages/socketIO_client/__init__.py", line 215, in __exit__
    self.disconnect()
  File "/usr/local/lib/python3.5/site-packages/socketIO_client/__init__.py", line 294, in disconnect
    self._transport.disconnect(path)
  File "/usr/local/lib/python3.5/site-packages/socketIO_client/__init__.py", line 320, in _transport
    socketIO_session = self._get_socketIO_session()
  File "/usr/local/lib/python3.5/site-packages/socketIO_client/__init__.py", line 348, in _get_socketIO_session
    self.is_secure, self._base_url, **self._kw)
  File "/usr/local/lib/python3.5/site-packages/socketIO_client/__init__.py", line 522, in _get_socketIO_session
    heartbeat_timeout=int(response_parts[1]),
ValueError: invalid literal for int() with base 10: '100%;\n            background'

TypeError: cafile, capath and cadata cannot be all omitted

seem to be having an issue connecting, not sure what has changed...
(downloaded the latest version)

Exception in thread LoopEnergy Event Thread:
Traceback (most recent call last):
File "/usr/lib64/python2.7/threading.py", line 801, in __bootstrap_inner
self.run()
File "/usr/lib64/python2.7/threading.py", line 754, in run
self.__target(*self.__args, **self.__kwargs)
File "/boot/config/plugins/loop2mqtt/pyloopenergy/loop_energy.py", line 134, in _run_event_thread
Namespace) as socket_io:
File "/usr/lib64/python2.7/site-packages/socketIO_client/init.py", line 206, in init
self.define(Namespace)
File "/usr/lib64/python2.7/site-packages/socketIO_client/init.py", line 223, in define
namespace = Namespace(self._transport, path)
File "/usr/lib64/python2.7/site-packages/socketIO_client/init.py", line 333, in _transport
socketIO_session, self._transport_name)
File "/usr/lib64/python2.7/site-packages/socketIO_client/init.py", line 381, in _get_transport
}[transport_name](session, self.is_secure, self._base_url, **self._kw)
File "/usr/lib64/python2.7/site-packages/socketIO_client/transports.py", line 147, in init
self._connection = websocket.create_connection(url, header=headers)
File "/usr/lib64/python2.7/site-packages/websocket/_core.py", line 487, in create_connection
websock.connect(url, **options)
File "/usr/lib64/python2.7/site-packages/websocket/_core.py", line 211, in connect
options.pop('socket', None))
File "/usr/lib64/python2.7/site-packages/websocket/_http.py", line 77, in connect
sock = _ssl_socket(sock, options.sslopt, hostname)
File "/usr/lib64/python2.7/site-packages/websocket/_http.py", line 182, in _ssl_socket
sock = _wrap_sni_socket(sock, sslopt, hostname, check_hostname)
File "/usr/lib64/python2.7/site-packages/websocket/_http.py", line 138, in _wrap_sni_socket
context.load_verify_locations(cafile=sslopt.get('ca_certs', None), capath=sslopt.get('ca_cert_path', None))
TypeError: cafile, capath and cadata cannot be all omitted

No handlers could be found for logger "socketio_client"

Hi there @pavoni

My update script appears to have just stopped working out of the blue yesterday afternoon. Reboot usually solves, but that didn't work. The virtual machine running this has no other services, so there's no conflict.

When trying to execute getloopvalue.py manually I see

[root@pvout pvout]# python getloopvalue.py
/usr/lib/python2.7/site-packages/requests/init.py:80: RequestsDependencyWarning: urllib3 (1.22) or chardet (2.2.1) doesn't match a supported version!
RequestsDependencyWarning)
No handlers could be found for logger "socketIO_client"

And then the process just hangs.

Done a yum update on the OS
Updated pip + did a pip update of pyloopenergy

Still no luck.

Any idea what the problem could be? Happy to provide any logging files if that helps!

Thank you!

Simple subscription example - Not returning anything

import pyloopenergy
import time

def elec_trace():
    print("Electricity =", le.electricity_useage)

elec_serial = '000000000000' #Not my actual serial!
elec_secret = 'secret'

le = pyloopenergy.LoopEnergy(elec_serial, elec_secret)
le.subscribe_elecricity(elec_trace)
time.sleep(120)
le.terminate()
time.sleep(60)

Calling this script outputs nothing - even after waiting a couple of minutes!

Another exception to catch

Exception in thread LoopEnergy Event Thread:
Traceback (most recent call last):
File "/usr/local/lib/python3.5/site-packages/requests/packages/urllib3/connection.py", line 141, in _new_conn
(self.host, self.port), self.timeout, **extra_kw)
File "/usr/local/lib/python3.5/site-packages/requests/packages/urllib3/util/connection.py", line 83, in create_connection
raise err
File "/usr/local/lib/python3.5/site-packages/requests/packages/urllib3/util/connection.py", line 73, in create_connection
sock.connect(sa)
socket.timeout: timed out

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "/usr/local/lib/python3.5/site-packages/requests/packages/urllib3/connectionpool.py", line 600, in urlopen
chunked=chunked)
File "/usr/local/lib/python3.5/site-packages/requests/packages/urllib3/connectionpool.py", line 345, in _make_request
self._validate_conn(conn)
File "/usr/local/lib/python3.5/site-packages/requests/packages/urllib3/connectionpool.py", line 844, in _validate_conn
conn.connect()
File "/usr/local/lib/python3.5/site-packages/requests/packages/urllib3/connection.py", line 284, in connect
conn = self._new_conn()
File "/usr/local/lib/python3.5/site-packages/requests/packages/urllib3/connection.py", line 146, in _new_conn
(self.host, self.timeout))
requests.packages.urllib3.exceptions.ConnectTimeoutError: (<requests.packages.urllib3.connection.VerifiedHTTPSConnection object at 0x110b74eb8>, 'Connection to www.your-loop.com timed out. (connect timeout=3)')

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "/usr/local/lib/python3.5/site-packages/requests/adapters.py", line 423, in send
timeout=timeout
File "/usr/local/lib/python3.5/site-packages/requests/packages/urllib3/connectionpool.py", line 649, in urlopen
_stacktrace=sys.exc_info()[2])
File "/usr/local/lib/python3.5/site-packages/requests/packages/urllib3/util/retry.py", line 376, in increment
raise MaxRetryError(_pool, url, error or ResponseError(cause))
requests.packages.urllib3.exceptions.MaxRetryError: HTTPSConnectionPool(host='www.your-loop.com', port=443): Max retries exceeded with url: /socket.io/1/xhr-polling/2296uLREc-zVzHeLAry1?t=1487640827 (Caused by ConnectTimeoutError(<requests.packages.urllib3.connection.VerifiedHTTPSConnection object at 0x110b74eb8>, 'Connection to www.your-loop.com timed out. (connect timeout=3)'))

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "/Users/gregdowling/.homeassistant/deps/socketIO_client/transports.py", line 318, in _get_response
response = request(*args, **kw)
File "/usr/local/lib/python3.5/site-packages/requests/sessions.py", line 501, in get
return self.request('GET', url, **kwargs)
File "/usr/local/lib/python3.5/site-packages/requests/sessions.py", line 488, in request
resp = self.send(prep, **send_kwargs)
File "/usr/local/lib/python3.5/site-packages/requests/sessions.py", line 609, in send
r = adapter.send(request, **kwargs)
File "/usr/local/lib/python3.5/site-packages/requests/adapters.py", line 479, in send
raise ConnectTimeout(e, request=request)
requests.exceptions.ConnectTimeout: HTTPSConnectionPool(host='www.your-loop.com', port=443): Max retries exceeded with url: /socket.io/1/xhr-polling/2296uLREc-zVzHeLAry1?t=1487640827 (Caused by ConnectTimeoutError(<requests.packages.urllib3.connection.VerifiedHTTPSConnection object at 0x110b74eb8>, 'Connection to www.your-loop.com timed out. (connect timeout=3)'))

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "/usr/local/Cellar/python3/3.5.1/Frameworks/Python.framework/Versions/3.5/lib/python3.5/threading.py", line 914, in _bootstrap_inner
self.run()
File "/usr/local/Cellar/python3/3.5.1/Frameworks/Python.framework/Versions/3.5/lib/python3.5/threading.py", line 862, in run
self._target(*self._args, **self._kwargs)
File "/Users/gregdowling/.homeassistant/deps/pyloopenergy/loop_energy.py", line 134, in _run_event_thread
Namespace) as socket_io:
File "/Users/gregdowling/.homeassistant/deps/socketIO_client/init.py", line 206, in init
self.define(Namespace)
File "/Users/gregdowling/.homeassistant/deps/socketIO_client/init.py", line 223, in define
namespace = Namespace(self._transport, path)
File "/Users/gregdowling/.homeassistant/deps/socketIO_client/init.py", line 333, in _transport
socketIO_session, self._transport_name)
File "/Users/gregdowling/.homeassistant/deps/socketIO_client/init.py", line 381, in _get_transport
}[transport_name](session, self.is_secure, self._base_url, **self._kw)
File "/Users/gregdowling/.homeassistant/deps/socketIO_client/transports.py", line 201, in init
for packet in self.recv_packet():
File "/Users/gregdowling/.homeassistant/deps/socketIO_client/transports.py", line 98, in recv_packet
for packet_text in self.recv(timeout=timeout):
File "/Users/gregdowling/.homeassistant/deps/socketIO_client/transports.py", line 226, in recv
stream=True)
File "/Users/gregdowling/.homeassistant/deps/socketIO_client/transports.py", line 320, in _get_response
raise TimeoutError(e)
socketIO_client.exceptions.TimeoutError: HTTPSConnectionPool(host='www.your-loop.com', port=443): Max retries exceeded with url: /socket.io/1/xhr-polling/2296uLREc-zVzHeLAry1?t=1487640827 (Caused by ConnectTimeoutError(<requests.packages.urllib3.connection.VerifiedHTTPSConnection object at 0x110b74eb8>, 'Connection to www.your-loop.com timed out. (connect timeout=3)'))

Exception in LoopEnergy Event Thread

Exception in thread LoopEnergy Event Thread:
Traceback (most recent call last):
  File "/usr/lib/python2.7/threading.py", line 801, in __bootstrap_inner
    self.run()
  File "/usr/lib/python2.7/threading.py", line 754, in run
    self.__target(*self.__args, **self.__kwargs)
  File "/usr/local/lib/python2.7/dist-packages/pyloopenergy/loop_energy.py", line 134, in _run_event_thread
    Namespace) as socket_io:
  File "/usr/local/lib/python2.7/dist-packages/socketIO_client/__init__.py", line 353, in __init__
    resource, hurry_interval_in_seconds, **kw)
  File "/usr/local/lib/python2.7/dist-packages/socketIO_client/__init__.py", line 54, in __init__
    self._transport
  File "/usr/local/lib/python2.7/dist-packages/socketIO_client/__init__.py", line 62, in _transport
    self._engineIO_session = self._get_engineIO_session()
  File "/usr/local/lib/python2.7/dist-packages/socketIO_client/__init__.py", line 76, in _get_engineIO_session
    transport.recv_packet())
StopIteration

This seems to be happening if the script is left running for a while - any ideas?

Exception kills connection - requests.exceptions.TooManyRedirects: Exceeded 30 redirects

Exception in thread LoopEnergy Event Thread:
Traceback (most recent call last):
File "/usr/local/Cellar/python3/3.5.1/Frameworks/Python.framework/Versions/3.5/lib/python3.5/threading.py", line 914, in _bootstrap_inner
self.run()
File "/usr/local/Cellar/python3/3.5.1/Frameworks/Python.framework/Versions/3.5/lib/python3.5/threading.py", line 862, in run
self._target(_self._args, *_self._kwargs)
File "/usr/local/lib/python3.5/site-packages/pyloopenergy/loop_energy.py", line 134, in _run_event_thread
Namespace) as socket_io:
File "/usr/local/lib/python3.5/site-packages/socketIO_client/init.py", line 206, in init
self.define(Namespace)
File "/usr/local/lib/python3.5/site-packages/socketIO_client/init.py", line 223, in define
namespace = Namespace(self._transport, path)
File "/usr/local/lib/python3.5/site-packages/socketIO_client/init.py", line 320, in _transport
socketIO_session = self._get_socketIO_session()
File "/usr/local/lib/python3.5/site-packages/socketIO_client/init.py", line 348, in _get_socketIO_session
self.is_secure, self._base_url, **self._kw)
File "/usr/local/lib/python3.5/site-packages/socketIO_client/init.py", line 516, in _get_socketIO_session
response = _get_response(requests.get, server_url, *_kw)
File "/usr/local/lib/python3.5/site-packages/socketIO_client/transports.py", line 318, in _get_response
response = request(_args, *_kw)
File "/usr/local/lib/python3.5/site-packages/requests/api.py", line 70, in get
return request('get', url, params=params, *_kwargs)
File "/usr/local/lib/python3.5/site-packages/requests/api.py", line 56, in request
return session.request(method=method, url=url, *_kwargs)
File "/usr/local/lib/python3.5/site-packages/requests/sessions.py", line 475, in request
resp = self.send(prep, *_send_kwargs)
File "/usr/local/lib/python3.5/site-packages/requests/sessions.py", line 617, in send
history = [resp for resp in gen] if allow_redirects else []
File "/usr/local/lib/python3.5/site-packages/requests/sessions.py", line 617, in
history = [resp for resp in gen] if allow_redirects else []
File "/usr/local/lib/python3.5/site-packages/requests/sessions.py", line 110, in resolve_redirects
raise TooManyRedirects('Exceeded %s redirects.' % self.max_redirects, response=resp)
requests.exceptions.TooManyRedirects: Exceeded 30 redirects.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.