Open file in rw
All checks were successful
Build and Publish college-bot-v2 / build_and_publish (push) Successful in 16s
All checks were successful
Build and Publish college-bot-v2 / build_and_publish (push) Successful in 16s
This commit is contained in:
parent
d24dc99a8e
commit
babc888422
1 changed files with 2 additions and 1 deletions
|
@ -128,10 +128,11 @@ class Client(commands.Bot):
|
||||||
db = redis.asyncio.Redis(**CONFIG["redis"])
|
db = redis.asyncio.Redis(**CONFIG["redis"])
|
||||||
|
|
||||||
while True:
|
while True:
|
||||||
|
await asyncio.sleep(1)
|
||||||
while not os.path.exists(fifo):
|
while not os.path.exists(fifo):
|
||||||
await asyncio.sleep(1)
|
await asyncio.sleep(1)
|
||||||
try:
|
try:
|
||||||
async with aiofiles.open(fifo, "a") as fifo_fd:
|
async with aiofiles.open(fifo, "w") as fifo_fd:
|
||||||
async for line in fifo_fd:
|
async for line in fifo_fd:
|
||||||
log.debug("Webhook reader got this line: %r", line)
|
log.debug("Webhook reader got this line: %r", line)
|
||||||
try:
|
try:
|
||||||
|
|
Loading…
Reference in a new issue