Skip to content

Commit

Permalink
Remove irc.client.VERSION*
Browse files Browse the repository at this point in the history
  • Loading branch information
jaraco committed Jul 18, 2020
1 parent 7266f2e commit 313620f
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 13 deletions.
6 changes: 6 additions & 0 deletions CHANGES.rst
@@ -1,3 +1,9 @@
v19.0.0
=======

* ``irc.client`` no longer exposes a ``VERSION`` or ``VERSION_STRING``.
To get the version, call ``importlib.metadata.version('irc')`` directly.

v18.0.0
=======

Expand Down
13 changes: 0 additions & 13 deletions irc/client.py
Expand Up @@ -62,11 +62,6 @@
import contextlib
import warnings

try:
from importlib import metadata # type: ignore
except ImportError:
import importlib_metadata as metadata # type: ignore

import jaraco.functools
from jaraco.functools import Throttler
from jaraco.stream import buffer
Expand All @@ -81,14 +76,6 @@

log = logging.getLogger(__name__)

# set the version tuple
try:
VERSION_STRING = metadata.version('irc')
VERSION = tuple(int(res) for res in re.findall(r'\d+', VERSION_STRING))
except Exception:
VERSION_STRING = 'unknown'
VERSION = ()


class IRCError(Exception):
"An IRC exception"
Expand Down

2 comments on commit 313620f

@sbraz
Copy link
Contributor

@sbraz sbraz commented on 313620f Aug 8, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hey @jaraco, there's still a reference to importlib_metadata here, should it be removed?

irc/setup.cfg

Line 29 in a2e8405

importlib_metadata; python_version < "3.8"

@jaraco
Copy link
Owner Author

@jaraco jaraco commented on 313620f Sep 28, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just now seeing this comment. This requirement was restored due to #174.

Please sign in to comment.