def mine(self):
d=self.path.text()
name=self.exeline.text()
if d!='Path to the file used to start miner' and d!='':
if os.path.isfile(d)==True:
d='/'.join(d.split('/')[:-1])
try:
os.chdir(d)
process.start(name)
self.tnow=time.time()
except PermissionError:
QMessageBox.critical(self,"Error","Problems when accessing directory",QMessageBox.Ok)
except FileNotFoundError:
QMessageBox.critical(self,"Error","Bad directory path",QMessageBox.Ok)
评论列表
文章目录