Skip to content

Commit

Permalink
SW-1182 remove repo and user from dependency archive format (#34)
Browse files Browse the repository at this point in the history
* Remove repo and user from dependency archive format
* Change regex for dependencies to match pep-440
  • Loading branch information
Josef-MrBeam authored Mar 31, 2022
1 parent c5edbb4 commit 9f2dd90
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions octoprint_netconnectd/scripts/update_script.py
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,7 @@ def get_dependencies(path):
list of dependencie dict [{"name", "version"}]
"""
dependencies_path = os.path.join(path, "dependencies.txt")
dependencies_pattern = r"([a-z]+(?:[_-][a-z]+)*)(.=)+((0|[1-9]\d*)\.(0|[1-9]\d*)\.(0|[1-9]\d*)(?:-((?:0|[1-9]\d*|\d*[a-zA-Z-][0-9a-zA-Z-]*)(?:\.(?:0|[1-9]\d*|\d*[a-zA-Z-][0-9a-zA-Z-]*))*))?(?:\+([0-9a-zA-Z-]+(?:\.[0-9a-zA-Z-]+)*))?)"
dependencies_pattern = r"([a-z]+(?:[_-][a-z]+)*)(.=)+(([1-9][0-9]*!)?(0|[1-9][0-9]*)(\.(0|[1-9][0-9]*))*((a|b|rc)(0|[1-9][0-9]*))?(\.post(0|[1-9][0-9]*))?(\.dev(0|[1-9][0-9]*))?)"
"""
Example:
input: iobeam==0.7.15
Expand Down Expand Up @@ -281,8 +281,6 @@ def build_queue(update_info, dependencies, plugin_archive):
)
if dependency_config.get("pip"):
archive = dependency_config["pip"].format(
repo=dependency_config["repo"],
user=dependency_config["user"],
target_version="v{version}".format(version=dependency["version"]),
)
else:
Expand Down

0 comments on commit 9f2dd90

Please sign in to comment.