set up cgminer get hostname, and fixed the bug with asyncio trying to close non socket objects

This commit is contained in:
UpstreamData
2021-11-09 09:54:31 -07:00
parent 201ba6829a
commit b714dfe4a4
4 changed files with 37 additions and 18 deletions

View File

@@ -3,6 +3,11 @@ from cfg_util.layout import window
from cfg_util.ui import ui
import asyncio
import sys
# Fix bug with some whatsminers and asyncio because of a socket not being shut down:
if sys.version_info[0] == 3 and sys.version_info[1] >= 8 and sys.platform.startswith('win'):
asyncio.set_event_loop_policy(asyncio.WindowsSelectorEventLoopPolicy())
def main():