Skip to content

Commit

Permalink
Fix importing pip_requirements_parser
Browse files Browse the repository at this point in the history
  • Loading branch information
akaihola committed Jul 29, 2024
1 parent 9697431 commit d388ebc
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions action/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
import os
import shlex
import sys
from importlib import import_module
from pathlib import Path
from subprocess import PIPE, STDOUT, run # nosec

Expand Down Expand Up @@ -39,8 +40,8 @@ def pip_install(*packages, python):


pip_install("pip-requirements-parser", python=sys.executable)

from pip_requirements_parser import parse_reqparts_from_string
pip_requirements_parser = import_module("pip_requirements_parser")
parse_reqparts_from_string = pip_requirements_parser.parse_reqparts_from_string

run([sys.executable, "-m", "venv", str(ENV_PATH)], check=True) # nosec

Expand Down

0 comments on commit d388ebc

Please sign in to comment.