This commit is contained in:
Neythen
2021-05-05 22:14:04 +01:00
parent a778e1f48e
commit 3f13931f13

View File

@@ -13,6 +13,7 @@ import datetime
import threading import threading
import csv import csv
import pexpect import pexpect
import time
from multiprocessing import Process from multiprocessing import Process
from subprocess import Popen, PIPE from subprocess import Popen, PIPE
#stock_ticker = StockTicker() #stock_ticker = StockTicker()
@@ -32,8 +33,10 @@ ALLOWED_EXTENSIONS = {'csv', 'png'}
#ticker.stdin.write(b'from server') #ticker.stdin.write(b'from server')
#print(ticker.stdout.readlines()) #print(ticker.stdout.readlines())
#(output, errs) #(output, errs)
ticker = pexpect.spawn("sudo -E python3 stockTicker.py")
time.sleep(10) # let api calls finish
ticker = pexpect.spawn("sudo -E python3 stockTicker.py")
ticker.sendline('S') # run by default
#stock_ticker = StockTicker() #stock_ticker = StockTicker()
def allowed_file(filename): def allowed_file(filename):