tintin10q / headless-henk Goto Github PK
View Code? Open in Web Editor NEWA headless place nl client
A headless place nl client
This error keeps occurring repeatedly, no pixels being placed:
File "C:\Users\-----\AppData\Local\Programs\Python\Python310\lib\threading.py", line 1009, in _bootstrap_inner
self.run()
File "C:\Users\-----\AppData\Local\Programs\Python\Python310\lib\threading.py", line 1371, in run
self.function(*self.args, **self.kwargs)
File "C:\Users\-----\github\headless-henk\client.py", line 103, in place_pixel
self.differences = loop2.run_until_complete(
File "C:\Users\-----\AppData\Local\Programs\Python\Python310\lib\asyncio\base_events.py", line 641, in run_until_complete
return future.result()
File "C:\Users\-----\github\headless-henk\images.py", line 94, in get_pixel_differences_with_canvas_download
canvas = await build_canvas_image(canvas_indexes, username=username)
File "C:\Users\-----\github\headless-henk\canvas.py", line 43, in build_canvas_image
canvas_part = await get_canvas_part(image_id, username=username)
File "C:\Users\-----\github\headless-henk\canvas.py", line 15, in get_canvas_part
canvas_url = await reddit.get_canvas_url(canvas_id, username=username)
File "C:\Users\-----\github\headless-henk\reddit.py", line 151, in get_canvas_url
await websocket.recv() # This is also ack
File "C:\Users\-----\github\headless-henk\.venv\lib\site-packages\websockets\legacy\protocol.py", line 568, in recv
await self.ensure_open()
File "C:\Users\-----\github\headless-henk\.venv\lib\site-packages\websockets\legacy\protocol.py", line 935, in ensure_open
raise self.connection_closed_exc()
websockets.exceptions.ConnectionClosedOK: received 1000 (OK) terminated; then sent 1000 (OK) terminated
We checken nu bij het plaatsen van een pixel of we 200 terugkrijgen. Alleen is Reddit gemeen, want ze sturen ook 200 terug als we ratelimited of banned zijn. We zouden in de response moeten kijken of er een errors
object is en welke message erin staat. Ik merk alleen dat mijn Python skills hiervoor even ontbreken.
{
"errors":[
{
"message":"Ratelimited",
"path":[
"act"
],
"extensions":{
"nextAvailablePixelTs":2147483647000
}
},
{
"message":"ratelimit ''hit, next available: 2147483647000",
"path":[
"act"
]
}
],
"data":null
}
Error occurs as soon as it tries placing a pixel. Logs below:
File "C:\Users\Downloads\headless-henk-main\headless-henk-main\gaanmetdiebanaan.py", line 83, in
gaan()
File "C:\Users\Downloads\headless-henk-main\headless-henk-main\gaanmetdiebanaan.py", line 79, in gaan
asyncio.get_event_loop().run_until_complete(metdiebanaan())
File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.11_3.11.1264.0_x64__qbz5n2kfra8p0\Lib\asyncio\base_events.py", line 653, in run_until_complete
return future.result()
^^^^^^^^^^^^^^^
File "C:\Users\Downloads\headless-henk-main\headless-henk-main\gaanmetdiebanaan.py", line 70, in metdiebanaan
await run_with_accounts_toml()
File "C:\Users\Downloads\headless-henk-main\headless-henk-main\gaanmetdiebanaan.py", line 65, in run_with_accounts_toml
await asyncio.gather(*run_client_coreroutines)
File "C:\Users\Downloads\headless-henk-main\headless-henk-main\client.py", line 477, in run_client
await client.connect()
File "C:\Users\Downloads\headless-henk-main\headless-henk-main\client.py", line 81, in connect
async with websockets.connect(self.uri) as websocket:
File "C:\Users\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.11_qbz5n2kfra8p0\LocalCache\local-packages\Python311\site-packages\websockets\legacy\client.py", line 637, in aenter
return await self
^^^^^^^^^^
File "C:\Users\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.11_qbz5n2kfra8p0\LocalCache\local-packages\Python311\site-packages\websockets\legacy\client.py", line 655, in await_impl_timeout
return await self.await_impl()
^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.11_qbz5n2kfra8p0\LocalCache\local-packages\Python311\site-packages\websockets\legacy\client.py", line 659, in await_impl
_transport, _protocol = await self._create_connection()
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.11_3.11.1264.0_x64__qbz5n2kfra8p0\Lib\asyncio\base_events.py", line 1045, in create_connection
infos = await self._ensure_resolved(
^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.11_3.11.1264.0_x64__qbz5n2kfra8p0\Lib\asyncio\base_events.py", line 1419, in _ensure_resolved
return await loop.getaddrinfo(host, port, family=family, type=type,
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.11_3.11.1264.0_x64__qbz5n2kfra8p0\Lib\asyncio\base_events.py", line 867, in getaddrinfo
return await self.run_in_executor(
^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.11_3.11.1264.0_x64__qbz5n2kfra8p0\Lib\concurrent\futures\thread.py", line 58, in run
result = self.fn(*self.args, **self.kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.11_3.11.1264.0_x64__qbz5n2kfra8p0\Lib\socket.py", line 962, in getaddrinfo
for res in _socket.getaddrinfo(host, port, family, type, proto, flags):
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
socket.gaierror: [Errno 11001] getaddrinfo failed
Just a suggestion to add proxy support to avoid getting rate limied when using multiple accounts.
Hi, I'm trying to use the Docker container but despite having an accounts.toml
this is spammed in logs:
You did not configure your username in config.toml it is still 'ENTER USERNAME HERE!'
I understand that I can use a volume for the config.toml
and fix it manually but I would like to keep the setup as easy as possible for the members of our community.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.