fix chat stats

This commit is contained in:
mose 2019-09-02 00:43:01 +08:00
parent 02ca989ee8
commit 573278b81f
3 changed files with 6 additions and 6 deletions

View file

@ -7,6 +7,6 @@ Ceci est la page d'atterrissage du site des crapauds fous.
Pour bosser localement, lancez `python -m http.server` a la base du repo et puis `open http://localhost:8000`
Pour toute demande d'info passez donc sur https://coa.crapaud-fou.org et demandez dans le canal #animation-crapauds
Pour toute demande d'info passez donc sur <https://coa.crapaud-fou.org> et demandez dans le canal #animation-crapauds
mose

View file

@ -22,9 +22,9 @@ def main():
rocket = Connection()
print("Check users")
users = getAllActiveUsers(rocket)
crapauds_total = len(users)
# print("Check users")
# users = getAllActiveUsers(rocket)
# crapauds_total = len(users)
print("Check channels")
channels = getAllChannels(rocket)
@ -44,7 +44,7 @@ def main():
if channel_date > recent_date:
channels_recent += 1
messages = getAllMessages(rocket, channel["_id"], begindate= recent_date)
messages = getAllMessages(rocket, channel["_id"], begindate= recent_date, enddate = datetime.now())
nbMessages = len(messages)
print("Check messages for channels {} ({})".format(channel['name'], nbMessages))

View file

@ -1 +1 @@
{"crapauds": {"total": 2180, "recent": 98}, "canaux": {"total": 184, "recent": 107, "liste": ["semourais", "techos", "right-to-repair", "libre", "cratube", "reflexion-sur-lamour", "reflexion-sur-l-argent", "animation-crapauds", "lucarn", "empowerment"]}, "messages": {"total": 192117, "recent": 12337}, "cohortes": ["2607", "34", "barcelone", "belgique", "bourgogne", "bretagne", "centre", "grand-est", "grece", "grenoble", "hdf", "ile-de-france", "la-reunion", "loire", "lyon-st-etienne", "normandie", "paca", "paysdesavoie", "sud-ouest", "suisse"]}
{"crapauds": {"total": 2180, "recent": 0}, "canaux": {"total": 184, "recent": 103, "liste": ["activite-et-travail", "agenda", "algoculture", "animation-crapauds", "audio-visuel-libre", "bresil", "cause-animale", "cercle-autonomie-energetique", "cercle-blockchain-crypto", "cercle-collaboratif"]}, "messages": {"total": 192177, "recent": 0}, "cohortes": ["2607", "34", "barcelone", "belgique", "bourgogne", "bretagne", "centre", "grand-est", "grece", "grenoble", "hdf", "ile-de-france", "la-reunion", "loire", "lyon-st-etienne", "normandie", "paca", "paysdesavoie", "sud-ouest", "suisse"]}