Skip to content

Commit

Permalink
Add packaging to list of dependencies
Browse files Browse the repository at this point in the history
Now that packaging is no longer part of the standard library, we need
to add it to the list of dependencies. This solves the issue seen when
trying to run `broker --help`.
  • Loading branch information
JacobCallahan committed Oct 2, 2023
1 parent a8a9da6 commit ab3a662
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
5 changes: 2 additions & 3 deletions broker/commands.py
Original file line number Diff line number Diff line change
Expand Up @@ -156,14 +156,13 @@ def provider_cmd(ctx, *args, **kwargs): # the actual subcommand
def cli(version):
"""Command-line interface for interacting with providers."""
if version:
from packaging.version import Version
import pkg_resources
import requests

broker_version = pkg_resources.get_distribution("broker").version
# check the latest version publish to PyPi
try:
from packaging.version import Version
import requests

latest_version = Version(
requests.get("https://pypi.org/pypi/broker/json", timeout=60).json()["info"][
"version"
Expand Down
1 change: 1 addition & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ dependencies = [
"click",
"dynaconf<4.0.0",
"logzero",
"packaging",
"pyyaml",
"setuptools",
"ssh2-python",
Expand Down

0 comments on commit ab3a662

Please sign in to comment.