Bump esptool from 2.8 to 3.2 (#71)

This commit is contained in:
Otto Winter 2021-10-29 11:13:29 +02:00 committed by GitHub
parent c49ec75f06
commit 7b21f8ef45
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 14 additions and 5 deletions

View File

@ -23,6 +23,7 @@ class MockEsptoolArgs(object):
self.verify = False
self.erase_all = False
self.encrypt = False
self.encrypt_files = None
class ChipInfo(object):
@ -193,7 +194,11 @@ def detect_chip(port, force_esp8266=False, force_esp32=False):
try:
chip = esptool.ESPLoader.detect_chip(port)
except esptool.FatalError as err:
raise EsphomeflasherError("ESP Chip Auto-Detection failed: {}".format(err))
if "Wrong boot mode detected" in str(err):
msg = "ESP is not in flash boot mode. If your board has a flashing pin, try again while keeping it pressed."
else:
msg = "ESP Chip Auto-Detection failed: {}".format(err)
raise EsphomeflasherError(msg) from err
try:
chip.connect()

View File

@ -1,4 +1,5 @@
# This GUI is a fork of the brilliant https://github.com/marcelstoer/nodemcu-pyflasher
from io import TextIOBase
import re
import sys
import threading
@ -28,7 +29,7 @@ BACK_COLORS = {**COLORS, None: wx.BLACK}
# See discussion at http://stackoverflow.com/q/41101897/131929
class RedirectText:
class RedirectText(TextIOBase):
def __init__(self, text_ctrl):
self._out = text_ctrl
self._i = 0
@ -140,8 +141,11 @@ class RedirectText:
self._line = ''
continue
def flush(self):
pass
def writable(self):
return True
def isatty(self) -> bool:
return True
class FlashingThread(threading.Thread):

View File

@ -1,3 +1,3 @@
wxpython>=4.1.1,<5.0
esptool==2.8
esptool==3.2
requests>=2.24.0,<3