mirror of
https://gitea.augustin64.fr/piair/MsRewards-Reborn.git
synced 2025-06-21 17:53:56 +02:00
ahhh
This commit is contained in:
@ -18,17 +18,16 @@ import redis
|
|||||||
pool = redis.ConnectionPool(host='localhost', port=6379, db=0)
|
pool = redis.ConnectionPool(host='localhost', port=6379, db=0)
|
||||||
r = redis.Redis(connection_pool=pool)
|
r = redis.Redis(connection_pool=pool)
|
||||||
|
|
||||||
pubsub = r.pubsub()
|
|
||||||
pubsub.subscribe('console')
|
|
||||||
|
|
||||||
def generate_output():
|
def generate_output():
|
||||||
|
pubsub = r.pubsub()
|
||||||
|
pubsub.subscribe('console')
|
||||||
try :
|
try :
|
||||||
for message in pubsub.listen():
|
for message in pubsub.listen():
|
||||||
if message['type'] == 'message':
|
if message['type'] == 'message':
|
||||||
print(message)
|
print(message)
|
||||||
yield f"data: {message['data'].decode()}\n\n"
|
yield f"data: {message['data'].decode()}\n\n"
|
||||||
except :
|
except Exception as e:
|
||||||
print("ya eu une erreur sad")
|
print(f"ya eu une erreur sad {e}")
|
||||||
|
|
||||||
# the end
|
# the end
|
||||||
|
|
||||||
|
2
version
2
version
@ -1 +1 @@
|
|||||||
v6.6.47
|
v6.6.48
|
||||||
|
Reference in New Issue
Block a user