Giter Site home page Giter Site logo

wardpearce / sourcequerybot Goto Github PK

View Code? Open in Web Editor NEW
23.0 5.0 3.0 108 KB

Utilizing A2S, this discord bot allows you to display servers maps, player count & ip what refreshes at a set interval.

License: GNU General Public License v3.0

Python 100.00%
servers player-count refreshes live discord source gmod csgo list a2s

sourcequerybot's Introduction

sourcequerybot's People

Contributors

blueberryy avatar blueskyclouds avatar wardpearce avatar

Stargazers

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

Watchers

 avatar  avatar  avatar  avatar  avatar

sourcequerybot's Issues

Old Message Deletions

When the bit restarts, the old messages remain. Would be good for it to delete the old messages however do not delete all messages in the channel as we use it in our information channel.

new problem

Traceback (most recent call last):
File "run.py", line 36, in query_loop
async with aiohttp_session.get("https://districtnine.host/api/serverquery/?ip={}".format(values["server-ips"])) as r:
File "/usr/local/lib/python3.6/site-packages/aiohttp/client.py", line 1005, in aenter
self._resp = await self._coro
File "/usr/local/lib/python3.6/site-packages/aiohttp/client.py", line 476, in _request
timeout=real_timeout
File "/usr/local/lib/python3.6/site-packages/aiohttp/connector.py", line 522, in connect
proto = await self._create_connection(req, traces, timeout)
File "/usr/local/lib/python3.6/site-packages/aiohttp/connector.py", line 854, in _create_connection
req, traces, timeout)
File "/usr/local/lib/python3.6/site-packages/aiohttp/connector.py", line 959, in _create_direct_connection
raise ClientConnectorError(req.connection_key, exc) from exc
aiohttp.client_exceptions.ClientConnectorError: Cannot connect to host districtnine.host:443 ssl:None [No address associated with hostname]
Unclosed client session
client_session: <aiohttp.client.ClientSession object at 0x7fae7faeaba8>

bot gets problme after a certain time

===========================================
Name: Csgo-Bot#8026
Community: DistrictNine.Host
Discord.py version: 1.2.3
Source query rewrite version: 2.0.0

Task exception was never retrieved
future: <Task finished coro=<background_task() done, defined at /home/administrator/discordbots/Discord-Server-List-master/server-list.py:27> exception=ServerDisconnectedError(None,)>
Traceback (most recent call last):
File "/home/administrator/discordbots/Discord-Server-List-master/server-list.py", line 37, in background_task
async with session.get("http://districtnine.host/api/serverquery/?ip={}".format(values["server-ips"])) as r:
File "/usr/local/lib/python3.6/site-packages/aiohttp/client.py", line 1005, in aenter
self._resp = await self._coro
File "/usr/local/lib/python3.6/site-packages/aiohttp/client.py", line 497, in _request
await resp.start(conn)
File "/usr/local/lib/python3.6/site-packages/aiohttp/client_reqrep.py", line 844, in start
message, payload = await self._protocol.read() # type: ignore # noqa
File "/usr/local/lib/python3.6/site-packages/aiohttp/streams.py", line 588, in read
await self._waiter
aiohttp.client_exceptions.ServerDisconnectedError: None

the bot does not work for me

Hi, the bot throws me this error on heroku 2020-08-19T21: 11: 26.094454 + 00: 00 app [worker.1]: [WARNING]: 'ServerModel' object is not subscriptable and does not show the discord presence.

In pc throws me this error: Please wait I'm closing.
Traceback (most recent call last):
File "run.py", line 5, in
client.run("token")
File "D:\Usuario\Desktop\Programas\lib\site-packages\discord\client.py", line 640, in run
return future.result()
File "D:\Usuario\Desktop\Programas\lib\site-packages\discord\client.py", line 621, in runner
await self.start(*args, **kwargs)
File "D:\Usuario\Desktop\Programas\lib\site-packages\discord\client.py", line 585, in start
await self.connect(reconnect=reconnect)
File "D:\Usuario\Desktop\Programas\lib\site-packages\discord\client.py", line 499, in connect
await self._connect()
File "D:\Usuario\Desktop\Programas\lib\site-packages\discord\client.py", line 463, in _connect
await self.ws.poll_event()
File "D:\Usuario\Desktop\Programas\lib\site-packages\discord\gateway.py", line 471, in poll_event
await self.received_message(msg)
File "D:\Usuario\Desktop\Programas\lib\site-packages\discord\gateway.py", line 425, in received_message
func(data)
File "D:\Usuario\Desktop\Programas\lib\site-packages\discord\state.py", line 750, in parse_guild_create
guild = self._get_create_guild(data)
File "D:\Usuario\Desktop\Programas\lib\site-packages\discord\state.py", line 725, in _get_create_guild
guild._from_data(data)
File "D:\Usuario\Desktop\Programas\lib\site-packages\discord\guild.py", line 297, in _from_data
self._sync(guild)
File "D:\Usuario\Desktop\Programas\lib\site-packages\discord\guild.py", line 324, in _sync
self._add_channel(TextChannel(guild=self, data=c, state=self._state))
File "D:\Usuario\Desktop\Programas\lib\site-packages\discord\channel.py", line 107, in init
self._update(guild, data)
File "D:\Usuario\Desktop\Programas\lib\site-packages\discord\channel.py", line 131, in _update
self._fill_overwrites(data)
File "D:\Usuario\Desktop\Programas\lib\site-packages\discord\abc.py", line 294, in _fill_overwrites
self._overwrites.append(_Overwrites(id=overridden_id, **overridden))
TypeError: new() got an unexpected keyword argument 'deny_new'

The errors started from nowhere :/, I use the bot for my game server community, I tried the updated version and it doesn't work either.

Error

Any help?

File "run.py", line 1, in <module> from SourceQueryBot import SourceQueryBot File "/root/Tessste/SourceQueryBot/__init__.py", line 26 def __init__(self, catagories: list, ^ SyntaxError: invalid syntax

Can u help Bot works for 30 min and crash

===========================================
Name: CsGo Server List#9661
Community: DistrictNine.Host
Discord.py version: 1.2.3
Source query rewrite version: 3.0.0

Task exception was never retrieved
future: <Task finished coro=<query_loop() done, defined at run.py:25> exception=RuntimeError('Session is closed',)>
Traceback (most recent call last):
File "run.py", line 37, in query_loop
async with session.get("https://districtnine.host/api/serverquery/?ip={}".format(values["server-ips"])) as r:
File "/usr/local/lib/python3.6/site-packages/aiohttp/client.py", line 1005, in aenter
self._resp = await self._coro
File "/usr/local/lib/python3.6/site-packages/aiohttp/client.py", line 348, in _request
raise RuntimeError('Session is closed')
RuntimeError: Session is closed

new error

Hello sorry for the inconvenience, I fixed the previous error that was throwing me, but now it throws me a new error that makes the bot not work (The query or the presence does not work) the bot only stays on.
Error

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.