Skip to content

Commit

Permalink
Merge pull request #71 from rlad78/main
Browse files Browse the repository at this point in the history
fix: Support parsing inline-table format of Poetry dependency spec
  • Loading branch information
jdrew82 authored Oct 3, 2024
2 parents 84abbba + 94e3e58 commit 14b88df
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion tasks.py
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,10 @@ def is_truthy(arg):
with open("pyproject.toml", "r", encoding="utf8") as pyproject:
parsed_toml = toml.load(pyproject)

NAUTOBOT_VERSION = parsed_toml["tool"]["poetry"]["dependencies"]["nautobot"]
try:
NAUTOBOT_VERSION = parsed_toml["tool"]["poetry"]["dependencies"]["nautobot"]["version"]
except TypeError:
NAUTOBOT_VERSION = parsed_toml["tool"]["poetry"]["dependencies"]["nautobot"]


def task(function=None, *args, **kwargs): # pylint: disable=keyword-arg-before-vararg
Expand Down

0 comments on commit 14b88df

Please sign in to comment.