fixed formatting issues

This commit is contained in:
UpstreamData
2022-05-26 13:23:32 -06:00
parent 942f2a1c8d
commit c35b30e949
78 changed files with 177 additions and 173 deletions

View File

@@ -8,7 +8,9 @@ from fastapi.staticfiles import StaticFiles
from tools.web_monitor.dashboard import router as dashboard_router
from tools.web_monitor.miner import router as miner_router
from tools.web_monitor.scan import router as scan_router
from tools.web_monitor._settings import router as settings_router
from tools.web_monitor._settings import ( # noqa - Ignore access to _module
router as settings_router,
)
app = FastAPI()

View File

@@ -1,7 +1,9 @@
import asyncio
from miners.miner_factory import MinerFactory
from tools.web_monitor._settings.func import get_current_settings
from tools.web_monitor._settings.func import ( # noqa - Ignore access to _module
get_current_settings,
)
async def get_miner_data_dashboard(miner_ip):

View File

@@ -5,7 +5,9 @@ import websockets.exceptions
from fastapi import WebSocket, WebSocketDisconnect, APIRouter
from tools.web_monitor.func import get_current_miner_list
from tools.web_monitor._settings.func import get_current_settings
from tools.web_monitor._settings.func import ( # noqa - Ignore access to _module
get_current_settings,
)
from tools.web_monitor.dashboard.func import get_miner_data_dashboard

View File

@@ -5,7 +5,9 @@ import websockets.exceptions
from fastapi import WebSocket, WebSocketDisconnect, APIRouter
from miners.miner_factory import MinerFactory
from tools.web_monitor._settings.func import get_current_settings
from tools.web_monitor._settings.func import ( # noqa - Ignore access to _module
get_current_settings,
)
router = APIRouter()
@@ -24,9 +26,7 @@ async def miner_websocket(websocket: WebSocket, miner_ip):
cur_miner = await asyncio.wait_for(
MinerFactory().get_miner(str(miner_ip)), miner_identify_timeout
)
data = await asyncio.wait_for(
cur_miner.get_data(), miner_identify_timeout
)
data = await asyncio.wait_for(cur_miner.get_data(), miner_data_timeout)
fan_speeds = [
fan if not fan == -1 else 0