From: Jakob Cornell Date: Mon, 26 Sep 2022 18:58:47 +0000 (-0500) Subject: Fix request prioritization bug X-Git-Tag: strikebot-0.0.7~19 X-Git-Url: https://jcornell.net/gitweb/gitweb.cgi?a=commitdiff_plain;h=4116bc82ff3fd957c6cf21b075d6544fd243e4a5;p=counting.git Fix request prioritization bug --- diff --git a/strikebot/setup.cfg b/strikebot/setup.cfg index c22a71f..2165396 100644 --- a/strikebot/setup.cfg +++ b/strikebot/setup.cfg @@ -1,6 +1,6 @@ [metadata] name = strikebot -version = 0.0.3 +version = 0.0.4 [options] package_dir = diff --git a/strikebot/src/strikebot/__init__.py b/strikebot/src/strikebot/__init__.py index d9e4302..abe6065 100644 --- a/strikebot/src/strikebot/__init__.py +++ b/strikebot/src/strikebot/__init__.py @@ -1,3 +1,5 @@ +"""Count tracking logic.""" + from contextlib import nullcontext as nullcontext from dataclasses import dataclass from functools import total_ordering diff --git a/strikebot/src/strikebot/reddit_api.py b/strikebot/src/strikebot/reddit_api.py index 3e69e6c..2059707 100644 --- a/strikebot/src/strikebot/reddit_api.py +++ b/strikebot/src/strikebot/reddit_api.py @@ -89,7 +89,7 @@ class DeleteRequest(_Request): } def _subtype_cmp_key(self): - return -self.update_ts + return -self.update_ts.timestamp() @dataclass(eq = False)