[ci] auto-format

This commit is contained in:
imayushsaini 2023-07-02 07:50:25 +00:00 committed by github-actions[bot]
parent 018c962743
commit da0e63d677

View file

@ -193,12 +193,9 @@ if not isinstance(SystemEncode, str):
SystemEncode = "utf-8"
PingThread().start()
class chatloggThread():
"""Thread for sending out game pings."""
@ -1410,7 +1407,8 @@ class ModifiedPartyWindow(bascenev1lib_party.PartyWindow):
"""Called when a choice is selected in the popup."""
global unmuted_names
if self._popup_type == "banTimePress":
result = _babase.disconnect_client(self._popup_party_member_client_id, ban_time=int(choice))
result = _babase.disconnect_client(
self._popup_party_member_client_id, ban_time=int(choice))
if not result:
bui.getsound('error').play()
bs.broadcastmessage(
@ -1653,7 +1651,8 @@ class ModifiedPartyWindow(bascenev1lib_party.PartyWindow):
self.popup_menu_selected_choice(popup_window, choice.replace(
r"{$PlayerID}", str(playerID).replace("'", r"'").replace('"', r'\\"')))
else:
bs.broadcastmessage(_getTransText("No_valid_player_id_found"), (1, 0, 0))
bs.broadcastmessage(_getTransText(
"No_valid_player_id_found"), (1, 0, 0))
bui.getsound("error").play()
elif curKeyWord in (r"{$AccountInfo}",) != 0:
self.popup_menu_selected_choice(popup_window, choice.replace(
@ -1695,7 +1694,8 @@ def fetchAccountInfo(account, loading_widget):
if account in fdata:
servers = fdata[account]
url = f'https://{BCSSERVER}/player?key={base64.b64encode(account.encode("utf-8")).decode("utf-8")}&base64=true'
req = urllib.request.Request(url, headers={"User-Agent": f'BS{_babase.env().get("build_number", 0)}',"Accept-Language": "en-US,en;q=0.9",})
req = urllib.request.Request(url, headers={
"User-Agent": f'BS{_babase.env().get("build_number", 0)}', "Accept-Language": "en-US,en;q=0.9", })
data = urllib.request.urlopen(req)
account_data = json.loads(data.read().decode('utf-8'))[0]
pbid = account_data["pbid"]
@ -2147,6 +2147,8 @@ class CustomAccountViewerWindow(viewer.AccountViewerWindow):
babase.print_exception('Error displaying account info.')
# ba_meta export plugin
class bySmoothy(babase.Plugin):
def __init__(self):
bs.connect_to_party = newconnect_to_party