KOSASIH / ExoGenesis

Audit: Starting a process with a partial executable path BAN-B607
Security
Minor
3 months ago3 months old
Starting a process with a partial executable path
10        subprocess.run(['npm', 'install'], check=True)
11    elif os.path.exists('requirements.txt'):
12        print("Installing dependencies from requirements.txt...")
13        subprocess.run(['pip', 'install', '-r', 'requirements.txt'], check=True)14    else:
15        print("No package.json or requirements.txt file found. Please provide a package.json or requirements.txt file to install dependencies.")
Starting a process with a partial executable path
 7    """
 8    if os.path.exists('package.json'):
 9        print("Installing dependencies from package.json...")
10        subprocess.run(['npm', 'install'], check=True)11    elif os.path.exists('requirements.txt'):
12        print("Installing dependencies from requirements.txt...")
13        subprocess.run(['pip', 'install', '-r', 'requirements.txt'], check=True)