groupbyfix
This commit is contained in:
parent
1b46184781
commit
520b39cb0b
2
cache/precache.py
vendored
2
cache/precache.py
vendored
|
@ -84,7 +84,7 @@ async def precache_data():
|
|||
q = select(Topic).where(Topic.community == 1)
|
||||
topics = get_with_stat(q)
|
||||
for topic in topics:
|
||||
topic_dict = topic.dict() if hasattr(topic, 'dict') else topic
|
||||
topic_dict = topic.dict() if hasattr(topic, "dict") else topic
|
||||
await cache_topic(topic_dict)
|
||||
await asyncio.gather(
|
||||
precache_topics_followers(topic["id"], session), precache_topics_authors(topic_dict["id"], session)
|
||||
|
|
|
@ -126,7 +126,7 @@ def query_shouts():
|
|||
reaction_stats_subquery.c.comments_stat,
|
||||
reaction_stats_subquery.c.rating_stat,
|
||||
authors_subquery.c.authors,
|
||||
topics_subquery.c.topics
|
||||
topics_subquery.c.topics,
|
||||
)
|
||||
|
||||
return q, aliased_reaction
|
||||
|
|
Loading…
Reference in New Issue
Block a user