renamed run.bat. changed logging back to info
This commit is contained in:
14
main.py
14
main.py
@@ -36,7 +36,7 @@ class Receive(Base):
|
|||||||
Distance = Column(Integer)
|
Distance = Column(Integer)
|
||||||
Azimuth = Column(Integer)
|
Azimuth = Column(Integer)
|
||||||
Band = Column(Integer)
|
Band = Column(Integer)
|
||||||
Version = Column(Float)
|
Version = Column(String)
|
||||||
Code = Column(Integer)
|
Code = Column(Integer)
|
||||||
|
|
||||||
|
|
||||||
@@ -79,13 +79,17 @@ links = soup.find_all("a")
|
|||||||
for link in links:
|
for link in links:
|
||||||
linkArray.append(link.get('href'))
|
linkArray.append(link.get('href'))
|
||||||
ReportDownload = linkArray[-6:-5]
|
ReportDownload = linkArray[-6:-5]
|
||||||
|
print(ReportDownload[0])
|
||||||
|
|
||||||
#Download the latest zip and save it to the working folder.
|
#Download the latest zip and save it to the working folder.
|
||||||
download = requests.get(ReportDownload[0], stream=True)
|
download = requests.get(ReportDownload[0], stream=True)
|
||||||
with open('./download.zip', 'wb') as fd:
|
try:
|
||||||
for chunk in download.iter_content(chunk_size=128):
|
with open('./download.zip', 'wb') as fd:
|
||||||
fd.write(chunk)
|
for chunk in download.iter_content(chunk_size=128):
|
||||||
# print(ReportDownload[0])
|
fd.write(chunk)
|
||||||
|
except:
|
||||||
|
pass
|
||||||
|
print(ReportDownload[0])
|
||||||
|
|
||||||
#unzip the file and grab the CSV filename
|
#unzip the file and grab the CSV filename
|
||||||
with zipfile.ZipFile('./download.zip', 'r') as zip:
|
with zipfile.ZipFile('./download.zip', 'r') as zip:
|
||||||
|
|||||||
2
run.bat
2
run.bat
@@ -1,2 +0,0 @@
|
|||||||
@echo off
|
|
||||||
cmd /k "cd /d C:\Users\ICYN3\Documents\dev\wspr\venv\Scripts & activate & cd /d C:\Users\ICYN3\Documents\dev\wspr & python main.py & exit"
|
|
||||||
2
wsprRun.bat
Normal file
2
wsprRun.bat
Normal file
@@ -0,0 +1,2 @@
|
|||||||
|
@echo off
|
||||||
|
cmd /k "cd /d C:\Users\ICYN3\Documents\wsprLogging\venv\Scripts & activate & cd /d C:\Users\ICYN3\Documents\wsprLogging & python main.py & exit"
|
||||||
Reference in New Issue
Block a user