Skip to content

Commit

Permalink
Drop check for ancient dbus versions
Browse files Browse the repository at this point in the history
This check warned against using a very old dbus version that caused
breakage. However, the check used the `distutils` package for version
comparison, but that package is deprecated and will be removed in an
upcoming python version. Since there does not seem to be a direct
alternative for version comparisons in the core Python libraries and
this check is about a 4-year old dbus version anyway, just remove the
check rather than adding an extra dependency just for this.
  • Loading branch information
matthijskooijman committed Nov 27, 2023
1 parent bcbfaee commit f14e427
Showing 1 changed file with 0 additions and 11 deletions.
11 changes: 0 additions & 11 deletions src/hamster/client.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,6 @@
import sys

from calendar import timegm
from distutils.version import LooseVersion
from gi.repository import GObject as gobject
from textwrap import dedent

Expand All @@ -42,16 +41,6 @@
from hamster.lib import datetime as dt


# bug fixed in dbus-python 1.2.14 (released on 2019-11-25)
assert not (
sys.version_info >= (3, 8)
and LooseVersion(dbus.__version__) < LooseVersion("1.2.14")
), """python3.8 changed str(<dbus integers>).
That broke hamster (https://github.com/projecthamster/hamster/issues/477).
Please upgrade to dbus-python >= 1.2.14.
"""


class Storage(gobject.GObject):
"""Hamster client class, communicating to hamster storage daemon via d-bus.
Subscribe to the `tags-changed`, `facts-changed` and `activities-changed`
Expand Down

0 comments on commit f14e427

Please sign in to comment.