Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

已知BUG修复 #79

Merged
merged 3 commits into from
Sep 24, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion app/components/search_line_edit.py
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,6 @@ def __init__(self, parent=None):
completer = QCompleter([], self)
completer.setCaseSensitivity(Qt.CaseInsensitive)
completer.setMaxVisibleItems(10)
completer.setFilterMode(Qt.MatchFlag.MatchFixedString)
completer.setCompletionRole(Qt.DisplayRole)
completer.setCompletionMode(QCompleter.UnfilteredPopupCompletion)
self.setCompleter(completer)
Expand Down
8 changes: 5 additions & 3 deletions app/lol/connector.py
Original file line number Diff line number Diff line change
Expand Up @@ -38,18 +38,20 @@ def wrapper(*args, **kwargs):
def retry(count=5, retry_sep=0.5):
def decorator(func):
def wrapper(*args, **kwargs):
exce = None
for _ in range(count):
try:
res = func(*args, **kwargs)
except Exception as e:
except BaseException as e:
time.sleep(retry_sep)
exce = e
continue
else:
break
else:
# FIXME 任何异常都将以 timeout 抛出
connector.timeoutApi = func.__name__
raise Exception("Exceeded maximum retry attempts.")
raise exce
# raise Exception("Exceeded maximum retry attempts.")

return res

Expand Down
1 change: 1 addition & 0 deletions app/resource/icons/Update_black.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions app/resource/icons/Update_white.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion app/view/main_window.py
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ def __init__(self):

self.splashScreen.finish()
threading.Thread(target=self.checkUpdate).start()
threading.Thread(target=self.pollingConnectTimeout).start()
threading.Thread(target=self.pollingConnectTimeout, daemon=True).start()

def __initInterface(self):
self.__lockInterface()
Expand Down
4 changes: 3 additions & 1 deletion app/view/search_interface.py
Original file line number Diff line number Diff line change
Expand Up @@ -1101,7 +1101,9 @@ def loadGames(self, puuid):
return

if not games["games"]: # 所有对局都在一年内, 查完了
self.gamesNotFound.emit()
if not self.games: # 未能查到任何一盘对局, 提示一下
self.gamesNotFound.emit()

return

for game in games["games"]:
Expand Down