2020-07-17 16:45:53 +02:00
|
|
|
import sys
|
|
|
|
import subprocess
|
|
|
|
|
|
|
|
try:
|
|
|
|
import peewee
|
|
|
|
except ImportError:
|
|
|
|
print("Installing peewee")
|
|
|
|
p = subprocess.Popen([sys.executable, "-m", "pip", "install", "-U", "peewee"],
|
|
|
|
stdout=subprocess.PIPE, stderr=subprocess.PIPE)
|
|
|
|
print(p.communicate())
|
|
|
|
|
|
|
|
try:
|
|
|
|
import requests
|
|
|
|
except ImportError:
|
|
|
|
print("Installing requests")
|
|
|
|
p = subprocess.Popen([sys.executable, "-m", "pip", "install", "-U", "requests"],
|
|
|
|
stdout=subprocess.PIPE, stderr=subprocess.PIPE)
|
|
|
|
print(p.communicate())
|
|
|
|
import requests
|
|
|
|
|
|
|
|
try:
|
|
|
|
import browser_cookie3
|
|
|
|
except ImportError:
|
|
|
|
print("Installing browser_cookie3")
|
|
|
|
p = subprocess.Popen([sys.executable, "-m", "pip", "install", "-U", "browser_cookie3"],
|
|
|
|
stdout=subprocess.PIPE, stderr=subprocess.PIPE)
|
|
|
|
print(p.communicate())
|
|
|
|
|
2020-07-29 09:56:37 +02:00
|
|
|
try:
|
|
|
|
import pandas
|
|
|
|
except ImportError:
|
|
|
|
print("Installing pandas")
|
|
|
|
p = subprocess.Popen([sys.executable, "-m", "pip", "install", "-U", "pandas"],
|
|
|
|
stdout=subprocess.PIPE, stderr=subprocess.PIPE)
|
|
|
|
print(p.communicate())
|
|
|
|
|
|
|
|
try:
|
|
|
|
import xlrd
|
|
|
|
except ImportError:
|
|
|
|
print("Installing xlrd")
|
|
|
|
p = subprocess.Popen([sys.executable, "-m", "pip", "install", "-U", "xlrd"],
|
|
|
|
stdout=subprocess.PIPE, stderr=subprocess.PIPE)
|
|
|
|
print(p.communicate())
|
|
|
|
|
|
|
|
try:
|
|
|
|
import numpy
|
|
|
|
except ImportError:
|
|
|
|
print("Installing numpy")
|
|
|
|
p = subprocess.Popen([sys.executable, "-m", "pip", "install", "-U", "numpy"],
|
|
|
|
stdout=subprocess.PIPE, stderr=subprocess.PIPE)
|
|
|
|
print(p.communicate())
|
|
|
|
|