fixed some bugs with latest version of toolbox

This commit is contained in:
UpstreamData
2022-05-03 12:53:14 -06:00
parent 0107fdacde
commit ffce15f653
2 changed files with 5 additions and 5 deletions

View File

@@ -127,7 +127,7 @@ class TestbenchMiner:
await self.add_to_output("Running install...")
error = None
proc = await asyncio.create_subprocess_shell(
f'{os.path.join(os.path.dirname(__file__), "files", "bos-toolbox", "bos-toolbox.bat")} install {str(self.host)} --no-keep-pools --psu-power-limit 900 --no-nand-backup --feeds-url file:./feeds/ -p root',
f'{os.path.join(os.path.dirname(__file__), "files", "bos-toolbox", "bos-toolbox.bat")} install {str(self.host)} --no-keep-pools --psu-power-limit 900 --no-nand-backup --feeds-url file:./feeds/',
stdout=asyncio.subprocess.PIPE,
stderr=asyncio.subprocess.PIPE,
stdin=asyncio.subprocess.PIPE
@@ -137,7 +137,7 @@ class TestbenchMiner:
await self.add_to_output("Getting output...")
while True:
try:
stdout = await asyncio.wait_for(proc.stderr.readuntil(b"\r"), 10)
stdout = await asyncio.wait_for(proc.stderr.readuntil(b"\r"), 20)
except asyncio.exceptions.IncompleteReadError:
break
except asyncio.exceptions.TimeoutError:

View File

@@ -89,10 +89,10 @@ async def get_latest_update_file(session, update_file):
async def get_latest_install_file(session, version, feeds_path, install_file):
install_file_loc = f"http://feeds.braiins-os.com/{version}/{install_file}"
feeds_file_path = os.path.join(feeds_path, "toolbox_bos_am1-s9")
feeds_file_path = os.path.join(feeds_path, "toolbox_bos_install_am1-s9")
with open(feeds_file_path, "a+") as feeds_file:
feeds_file.write(version + "\t" + install_file)
feeds_file.write(version + "\t" + install_file.strip() + "\n")
install_file_folder = os.path.join(feeds_path, version)
if os.path.exists(install_file_folder):
@@ -133,7 +133,7 @@ async def get_local_versions():
if not os.path.exists(feeds_path):
os.mkdir(feeds_path)
feeds_file_path = os.path.join(feeds_path, "toolbox_bos_am1-s9")
feeds_file_path = os.path.join(feeds_path, "toolbox_bos_install_am1-s9")
if not os.path.exists(feeds_file_path):
feeds_file = open(feeds_file_path, "w+")