-
Notifications
You must be signed in to change notification settings - Fork 0
Open
Description
- Python JNE Peru version: 0.1.0
- Python version: 3.7.12
- Operating System: mac osx
Description
Le han puesto proteccion antibot a las paginas del JNE. Corrí este código:
from pyjne_peru.client import JNE
client = JNE()
# obtener listado de los procesos electorales
items = client.get_election_processes()
What I Did
Las paginas devuelven response 403
---------------------------------------------------------------------------
JNEException Traceback (most recent call last)
<ipython-input-27-b6fc4bbbfba3> in <module>
----> 1 items = client.get_election_processes()
~/.virtualenvs/otorongo.club/lib/python3.7/site-packages/pyjne_peru/client.py in get_election_processes(self)
39 return self._make_request(
40 "GET", "/Resoluciones/GetListProcesosCR",
---> 41 payload_type="election_process", payload_list=True)
42
43 def get_election_types_by_process(self, proceso_electoral: int):
~/.virtualenvs/otorongo.club/lib/python3.7/site-packages/pyjne_peru/client.py in _make_request(self, method, path, payload_type, payload_list, post_data, params, **kwargs)
22 response = request_method(self._build_url(path), params=params or {}, data=post_data or {})
23 if response.status_code != 200:
---> 24 raise JNEException(f"JNE error response: status code = {response.status_code}")
25
26 result = self.parser.parse(response.json(), payload_list=payload_list, payload_type=payload_type)
JNEException: JNE error response: status code = 403
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels