Skip to content

Commit

Permalink
Merge pull request #377 from openedx/feanil/fix_update_py_sh_script
Browse files Browse the repository at this point in the history
fix: Don't filter out extras for a pip dependency.
  • Loading branch information
Feanil Patel authored Aug 7, 2023
2 parents 72ff1ac + c340961 commit 46cfcb7
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ def load_requirements(*requirements_paths):
constraint_files = set()

# groups "pkg<=x.y.z,..." into ("pkg", "<=x.y.z,...")
requirement_line_regex = re.compile(r"([a-zA-Z0-9-_.]+)([<>=][^#\s]+)?")
requirement_line_regex = re.compile(r"([a-zA-Z0-9-_.\[\]]+)([<>=][^#\s]+)?")

def add_version_constraint_or_raise(current_line, current_requirements, add_if_not_present):
regex_match = requirement_line_regex.match(current_line)
Expand Down
2 changes: 1 addition & 1 deletion scripts/update_setup_py.sh
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ echo -e "rules:
constraint_files = set()
# groups \"my-package-name<=x.y.z,...\" into (\"my-package-name\", \"<=x.y.z,...\")
requirement_line_regex = re.compile(r\"([a-zA-Z0-9-_.]+)([<>=][^#\s]+)?\")
requirement_line_regex = re.compile(r\"([a-zA-Z0-9-_.\[\]]+)([<>=][^#\s]+)?\")
def add_version_constraint_or_raise(current_line, current_requirements, add_if_not_present):
regex_match = requirement_line_regex.match(current_line)
Expand Down

0 comments on commit 46cfcb7

Please sign in to comment.