cafca / souma

Souma is a distributed and end-to-end encrypted community platform based on humanist ideals
Apache License 2.0
5 stars 3 forks source link

Souma hangs loading Group page /w single post without upvotes #172

Open cafca opened 10 years ago

cafca commented 10 years ago

SQLAlchemy enters an infinite loop trying to return upvote count.

This does not happen if there is more than one post in the group or if the post has received at least one upvote.

Reproduce:

  1. Create a new group
  2. Post a single Star
  3. Visit the group page

At this point, nothing more happens. If execution is halted, stacktrace shows that the interpreter was always somewhere within Oneup.oneup_count method, but always at a different point. I already tried rewriting the filter in that method, but don't know a way around using the count() method.