From 957533b87f69959a83e3801f9acb49e36d6f0583 Mon Sep 17 00:00:00 2001 From: lighting9999 Date: Sun, 19 Oct 2025 17:33:29 +0800 Subject: [PATCH 1/4] change game --- .gitignore | 6 +- BoardGame-CLI/python.py | 3 +- BoardGame-CLI/snakeLadder.py | 5 +- BoardGame-CLI/uno.py | 244 ++++++++++++++++++++--------------- 4 files changed, 147 insertions(+), 111 deletions(-) diff --git a/.gitignore b/.gitignore index 0f3717818e6..5d5134469d2 100644 --- a/.gitignore +++ b/.gitignore @@ -16,12 +16,10 @@ for i in string: odd+=i print(lower+upper+odd+even) +.vscode +__pycache__/ .venv -# operating system-related files -# file properties cache/storage on macOS *.DS_Store - -# thumbnail cache on Windows Thumbs.db bankmanaging.db \ No newline at end of file diff --git a/BoardGame-CLI/python.py b/BoardGame-CLI/python.py index 49929a775ce..5a28f5adf6f 100644 --- a/BoardGame-CLI/python.py +++ b/BoardGame-CLI/python.py @@ -87,4 +87,5 @@ def play_snakes_and_ladders(): # Start the game -play_snakes_and_ladders() +if __name__ == "__main__": + play_snakes_and_ladders() diff --git a/BoardGame-CLI/snakeLadder.py b/BoardGame-CLI/snakeLadder.py index ea605cab340..fd06dd64527 100644 --- a/BoardGame-CLI/snakeLadder.py +++ b/BoardGame-CLI/snakeLadder.py @@ -90,7 +90,7 @@ def play(): elif n == 2: players = {} # stores player ans their locations isReady = {} - current_loc = 0 # vaiable for iterating location + current_loc = 1 # reset starting location to 1 player_input() elif n == 3: @@ -170,4 +170,5 @@ def ladder(a, i): print("/" * 40) -player_input() +if __name__ == "__main__": + player_input() diff --git a/BoardGame-CLI/uno.py b/BoardGame-CLI/uno.py index f10f46c4ff8..cda943c8084 100644 --- a/BoardGame-CLI/uno.py +++ b/BoardGame-CLI/uno.py @@ -1,16 +1,25 @@ # uno game # import random +from typing import List """ Generate the UNO deck of 108 cards. -Parameters: None -Return values: deck=>list + +Doctest examples: + +>>> deck = buildDeck() +>>> len(deck) +108 +>>> sum(1 for c in deck if 'Wild' in c) +8 + +Return: list of card strings (e.g. 'Red 7', 'Wild Draw Four') """ -def buildDeck(): - deck = [] +def buildDeck() -> List[str]: + deck: List[str] = [] # example card:Red 7,Green 8, Blue skip colours = ["Red", "Green", "Yellow", "Blue"] values = [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, "Draw Two", "Skip", "Reverse"] @@ -24,7 +33,6 @@ def buildDeck(): for i in range(4): deck.append(wilds[0]) deck.append(wilds[1]) - print(deck) return deck @@ -35,10 +43,9 @@ def buildDeck(): """ -def shuffleDeck(deck): - for cardPos in range(len(deck)): - randPos = random.randint(0, 107) - deck[cardPos], deck[randPos] = deck[randPos], deck[cardPos] +def shuffleDeck(deck: List[str]) -> List[str]: + # use Python's built-in shuffle which is efficient and correct + random.shuffle(deck) return deck @@ -48,10 +55,18 @@ def shuffleDeck(deck): """ -def drawCards(numCards): - cardsDrawn = [] +def drawCards(numCards: int) -> List[str]: + """ + Draw a number of cards from the top of the global `unoDeck`. + + Raises ValueError if the deck runs out of cards. + """ + cardsDrawn: List[str] = [] for x in range(numCards): - cardsDrawn.append(unoDeck.pop(0)) + try: + cardsDrawn.append(unoDeck.pop(0)) + except IndexError: + raise ValueError("The deck is empty; cannot draw more cards") return cardsDrawn @@ -62,7 +77,7 @@ def drawCards(numCards): """ -def showHand(player, playerHand): +def showHand(player: int, playerHand: List[str]) -> None: print("Player {}'s Turn".format(players_name[player])) print("Your Hand") print("------------------") @@ -80,7 +95,15 @@ def showHand(player, playerHand): """ -def canPlay(colour, value, playerHand): +def canPlay(colour: str, value: str, playerHand: List[str]) -> bool: + """ + Return True if any card in playerHand is playable on a discard with given colour and value. + + >>> canPlay('Red','5',['Red 3','Green 5']) + True + >>> canPlay('Blue','7',['Green 1']) + False + """ for card in playerHand: if "Wild" in card: return True @@ -89,101 +112,114 @@ def canPlay(colour, value, playerHand): return False +# --- Global deck and initial setup --- unoDeck = buildDeck() unoDeck = shuffleDeck(unoDeck) unoDeck = shuffleDeck(unoDeck) -discards = [] +discards: List[str] = [] -players_name = [] -players = [] +players_name: List[str] = [] +players: List[List[str]] = [] colours = ["Red", "Green", "Yellow", "Blue"] -numPlayers = int(input("How many players?")) -while numPlayers < 2 or numPlayers > 4: - numPlayers = int( - input("Invalid. Please enter a number between 2-4.\nHow many players?") - ) -for player in range(numPlayers): - players_name.append(input("Enter player {} name: ".format(player + 1))) - players.append(drawCards(5)) - - -playerTurn = 0 -playDirection = 1 -playing = True -discards.append(unoDeck.pop(0)) -splitCard = discards[0].split(" ", 1) -currentColour = splitCard[0] -if currentColour != "Wild": - cardVal = splitCard[1] -else: - cardVal = "Any" - -while playing: - showHand(playerTurn, players[playerTurn]) - print("Card on top of discard pile: {}".format(discards[-1])) - if canPlay(currentColour, cardVal, players[playerTurn]): - cardChosen = int(input("Which card do you want to play?")) - while not canPlay( - currentColour, cardVal, [players[playerTurn][cardChosen - 1]] - ): - cardChosen = int(input("Not a valid card. Which card do you want to play?")) - print("You played {}".format(players[playerTurn][cardChosen - 1])) - discards.append(players[playerTurn].pop(cardChosen - 1)) - - # cheak if player won - if len(players[playerTurn]) == 0: - playing = False - # winner = "Player {}".format(playerTurn+1) - winner = players_name[playerTurn] - else: - # cheak for special cards - splitCard = discards[-1].split(" ", 1) - currentColour = splitCard[0] - if len(splitCard) == 1: - cardVal = "Any" - else: - cardVal = splitCard[1] - if currentColour == "Wild": - for x in range(len(colours)): - print("{}) {}".format(x + 1, colours[x])) - newColour = int(input("What colour would you like to choose? ")) - while newColour < 1 or newColour > 4: - newColour = int( - input("Invalid option. What colour would you like to choose") - ) - currentColour = colours[newColour - 1] - if cardVal == "Reverse": - playDirection = playDirection * -1 - elif cardVal == "Skip": - playerTurn += playDirection - if playerTurn >= numPlayers: - playerTurn = 0 - elif playerTurn < 0: - playerTurn = numPlayers - 1 - elif cardVal == "Draw Two": - playerDraw = playerTurn + playDirection - if playerDraw == numPlayers: - playerDraw = 0 - elif playerDraw < 0: - playerDraw = numPlayers - 1 - players[playerDraw].extend(drawCards(2)) - elif cardVal == "Draw Four": - playerDraw = playerTurn + playDirection - if playerDraw == numPlayers: - playerDraw = 0 - elif playerDraw < 0: - playerDraw = numPlayers - 1 - players[playerDraw].extend(drawCards(4)) - print("") + + +def main() -> None: + """Run interactive UNO game (keeps original behavior). + + Note: main() is interactive and not exercised by doctest. + """ + global players_name, players, discards + + numPlayers = int(input("How many players?")) + while numPlayers < 2 or numPlayers > 4: + numPlayers = int( + input("Invalid. Please enter a number between 2-4.\nHow many players?") + ) + for player in range(numPlayers): + players_name.append(input("Enter player {} name: ".format(player + 1))) + players.append(drawCards(5)) + + playerTurn = 0 + playDirection = 1 + playing = True + discards.append(unoDeck.pop(0)) + splitCard = discards[0].split(" ", 1) + currentColour = splitCard[0] + if currentColour != "Wild": + cardVal = splitCard[1] else: - print("You can't play. You have to draw a card.") - players[playerTurn].extend(drawCards(1)) + cardVal = "Any" + + while playing: + showHand(playerTurn, players[playerTurn]) + print("Card on top of discard pile: {}".format(discards[-1])) + if canPlay(currentColour, cardVal, players[playerTurn]): + cardChosen = int(input("Which card do you want to play?")) + while not canPlay( + currentColour, cardVal, [players[playerTurn][cardChosen - 1]] + ): + cardChosen = int(input("Not a valid card. Which card do you want to play?")) + print("You played {}".format(players[playerTurn][cardChosen - 1])) + discards.append(players[playerTurn].pop(cardChosen - 1)) + + # cheak if player won + if len(players[playerTurn]) == 0: + playing = False + # winner = "Player {}".format(playerTurn+1) + winner = players_name[playerTurn] + else: + # cheak for special cards + splitCard = discards[-1].split(" ", 1) + currentColour = splitCard[0] + if len(splitCard) == 1: + cardVal = "Any" + else: + cardVal = splitCard[1] + if currentColour == "Wild": + for x in range(len(colours)): + print("{}) {}".format(x + 1, colours[x])) + newColour = int(input("What colour would you like to choose? ")) + while newColour < 1 or newColour > 4: + newColour = int( + input("Invalid option. What colour would you like to choose") + ) + currentColour = colours[newColour - 1] + if cardVal == "Reverse": + playDirection = playDirection * -1 + elif cardVal == "Skip": + playerTurn += playDirection + if playerTurn >= numPlayers: + playerTurn = 0 + elif playerTurn < 0: + playerTurn = numPlayers - 1 + elif cardVal == "Draw Two": + playerDraw = playerTurn + playDirection + if playerDraw == numPlayers: + playerDraw = 0 + elif playerDraw < 0: + playerDraw = numPlayers - 1 + players[playerDraw].extend(drawCards(2)) + elif cardVal == "Draw Four": + playerDraw = playerTurn + playDirection + if playerDraw == numPlayers: + playerDraw = 0 + elif playerDraw < 0: + playerDraw = numPlayers - 1 + players[playerDraw].extend(drawCards(4)) + print("") + else: + print("You can't play. You have to draw a card.") + players[playerTurn].extend(drawCards(1)) + + playerTurn += playDirection + if playerTurn >= numPlayers: + playerTurn = 0 + elif playerTurn < 0: + playerTurn = numPlayers - 1 + + print("Game Over") + print("{} is the Winner!".format(winner)) - playerTurn += playDirection - if playerTurn >= numPlayers: - playerTurn = 0 - elif playerTurn < 0: - playerTurn = numPlayers - 1 -print("Game Over") -print("{} is the Winner!".format(winner)) +if __name__ == "__main__": + main() From 4929a7f1cec9999256ebbad55906f3efcae7bb72 Mon Sep 17 00:00:00 2001 From: lighting9999 Date: Sun, 19 Oct 2025 17:38:58 +0800 Subject: [PATCH 2/4] fix error --- BoardGame-CLI/uno.py | 8 +++++-- .../tests/test_hangman/test_main.py | 3 --- Tic-Tac-Toe Games/tic-tac-toe1.py | 11 +++++---- Tic-Tac-Toe Games/tic-tac-toe3.py | 22 +++++++++++------- Tic-Tac-Toe Games/tic-tac-toe6.py | 11 ++++++--- Timetable_Operations.py | 1 + simple_calculator.py | 12 ++++++---- smart_file_organizer.py | 20 ++++++++-------- time_delta.py | 23 +++++++++---------- to check leap year.py | 2 ++ 10 files changed, 67 insertions(+), 46 deletions(-) diff --git a/BoardGame-CLI/uno.py b/BoardGame-CLI/uno.py index cda943c8084..dca5f1e10c1 100644 --- a/BoardGame-CLI/uno.py +++ b/BoardGame-CLI/uno.py @@ -158,7 +158,9 @@ def main() -> None: while not canPlay( currentColour, cardVal, [players[playerTurn][cardChosen - 1]] ): - cardChosen = int(input("Not a valid card. Which card do you want to play?")) + cardChosen = int( + input("Not a valid card. Which card do you want to play?") + ) print("You played {}".format(players[playerTurn][cardChosen - 1])) discards.append(players[playerTurn].pop(cardChosen - 1)) @@ -181,7 +183,9 @@ def main() -> None: newColour = int(input("What colour would you like to choose? ")) while newColour < 1 or newColour > 4: newColour = int( - input("Invalid option. What colour would you like to choose") + input( + "Invalid option. What colour would you like to choose" + ) ) currentColour = colours[newColour - 1] if cardVal == "Reverse": diff --git a/Industrial_developed_hangman/tests/test_hangman/test_main.py b/Industrial_developed_hangman/tests/test_hangman/test_main.py index 9d377c7f9e9..6567e56b765 100644 --- a/Industrial_developed_hangman/tests/test_hangman/test_main.py +++ b/Industrial_developed_hangman/tests/test_hangman/test_main.py @@ -1,5 +1,3 @@ -import os -from pathlib import Path from typing import Callable, List import pytest @@ -8,7 +6,6 @@ from src.hangman.main import ( MainProcess, Source, - parse_word_from_local, parse_word_from_site, ) diff --git a/Tic-Tac-Toe Games/tic-tac-toe1.py b/Tic-Tac-Toe Games/tic-tac-toe1.py index f9825207079..4f87c72b7c6 100644 --- a/Tic-Tac-Toe Games/tic-tac-toe1.py +++ b/Tic-Tac-Toe Games/tic-tac-toe1.py @@ -28,11 +28,13 @@ def print_board(board: Board) -> None: def check_winner(board: Board, player: str) -> bool: """Return True if `player` has won.""" for i in range(3): - if all(board[i][j] == player for j in range(3)) or \ - all(board[j][i] == player for j in range(3)): + if all(board[i][j] == player for j in range(3)) or all( + board[j][i] == player for j in range(3) + ): return True - if all(board[i][i] == player for i in range(3)) or \ - all(board[i][2 - i] == player for i in range(3)): + if all(board[i][i] == player for i in range(3)) or all( + board[i][2 - i] == player for i in range(3) + ): return True return False @@ -86,5 +88,6 @@ def main() -> None: if __name__ == "__main__": import doctest + doctest.testmod() main() diff --git a/Tic-Tac-Toe Games/tic-tac-toe3.py b/Tic-Tac-Toe Games/tic-tac-toe3.py index f7a4fe3d5b7..92c60d494e6 100644 --- a/Tic-Tac-Toe Games/tic-tac-toe3.py +++ b/Tic-Tac-Toe Games/tic-tac-toe3.py @@ -21,11 +21,13 @@ def check_winner(board: Board, player: str) -> bool: """Check if `player` has a winning line on `board`.""" for i in range(3): - if all(board[i][j] == player for j in range(3)) or \ - all(board[j][i] == player for j in range(3)): + if all(board[i][j] == player for j in range(3)) or all( + board[j][i] == player for j in range(3) + ): return True - if all(board[i][i] == player for i in range(3)) or \ - all(board[i][2 - i] == player for i in range(3)): + if all(board[i][i] == player for i in range(3)) or all( + board[i][2 - i] == player for i in range(3) + ): return True return False @@ -116,16 +118,19 @@ def ai_move() -> None: # --- Initialize GUI --- root = ctk.CTk() root.title("Tic-Tac-Toe") -board: Board = [[" "]*3 for _ in range(3)] +board: Board = [[" "] * 3 for _ in range(3)] buttons: List[List[ctk.CTkButton]] = [] for i in range(3): row_buttons: List[ctk.CTkButton] = [] for j in range(3): btn = ctk.CTkButton( - root, text=" ", font=("normal", 30), - width=100, height=100, - command=lambda r=i, c=j: make_move(r, c) + root, + text=" ", + font=("normal", 30), + width=100, + height=100, + command=lambda r=i, c=j: make_move(r, c), ) btn.grid(row=i, column=j, padx=2, pady=2) row_buttons.append(btn) @@ -133,5 +138,6 @@ def ai_move() -> None: if __name__ == "__main__": import doctest + doctest.testmod() root.mainloop() diff --git a/Tic-Tac-Toe Games/tic-tac-toe6.py b/Tic-Tac-Toe Games/tic-tac-toe6.py index 329675be2c9..294f6fa0a17 100644 --- a/Tic-Tac-Toe Games/tic-tac-toe6.py +++ b/Tic-Tac-Toe Games/tic-tac-toe6.py @@ -62,9 +62,14 @@ def check_win(player_pos: Dict[str, List[int]], cur_player: str) -> bool: False """ soln = [ - [1, 2, 3], [4, 5, 6], [7, 8, 9], # Rows - [1, 4, 7], [2, 5, 8], [3, 6, 9], # Columns - [1, 5, 9], [3, 5, 7] # Diagonals + [1, 2, 3], + [4, 5, 6], + [7, 8, 9], # Rows + [1, 4, 7], + [2, 5, 8], + [3, 6, 9], # Columns + [1, 5, 9], + [3, 5, 7], # Diagonals ] return any(all(pos in player_pos[cur_player] for pos in combo) for combo in soln) diff --git a/Timetable_Operations.py b/Timetable_Operations.py index 18b9218f561..630ef597417 100644 --- a/Timetable_Operations.py +++ b/Timetable_Operations.py @@ -67,5 +67,6 @@ def calculate() -> None: if __name__ == "__main__": import doctest + doctest.testmod() root.mainloop() diff --git a/simple_calculator.py b/simple_calculator.py index 3464389ca3e..8864d9b2f60 100644 --- a/simple_calculator.py +++ b/simple_calculator.py @@ -14,6 +14,7 @@ 4.0 """ + def add(x: float, y: float) -> float: """Return the sum of x and y.""" return x + y @@ -41,17 +42,17 @@ def calculator() -> None: while True: choice: str = input("Enter choice (1/2/3/4): ").strip() - if choice in ('1', '2', '3', '4'): + if choice in ("1", "2", "3", "4"): num1: float = float(input("Enter first number: ")) num2: float = float(input("Enter second number: ")) - if choice == '1': + if choice == "1": print(f"{num1} + {num2} = {add(num1, num2)}") - elif choice == '2': + elif choice == "2": print(f"{num1} - {num2} = {subtract(num1, num2)}") - elif choice == '3': + elif choice == "3": print(f"{num1} * {num2} = {multiply(num1, num2)}") - elif choice == '4': + elif choice == "4": print(f"{num1} / {num2} = {divide(num1, num2)}") break else: @@ -60,5 +61,6 @@ def calculator() -> None: if __name__ == "__main__": import doctest + doctest.testmod() calculator() diff --git a/smart_file_organizer.py b/smart_file_organizer.py index 3150251678e..d9062c9fc93 100644 --- a/smart_file_organizer.py +++ b/smart_file_organizer.py @@ -68,7 +68,9 @@ def organize_files(base_path: str) -> None: Args: base_path: Path of the directory to organize. """ - files = [f for f in os.listdir(base_path) if os.path.isfile(os.path.join(base_path, f))] + files = [ + f for f in os.listdir(base_path) if os.path.isfile(os.path.join(base_path, f)) + ] if not files: print(f"[{datetime.now().strftime('%H:%M:%S')}] No files found in {base_path}") return @@ -82,9 +84,13 @@ def organize_files(base_path: str) -> None: try: shutil.move(source, os.path.join(target_folder, file_name)) - print(f"[{datetime.now().strftime('%H:%M:%S')}] Moved: {file_name} -> {category}/") + print( + f"[{datetime.now().strftime('%H:%M:%S')}] Moved: {file_name} -> {category}/" + ) except Exception as e: - print(f"[{datetime.now().strftime('%H:%M:%S')}] Error moving {file_name}: {e}") + print( + f"[{datetime.now().strftime('%H:%M:%S')}] Error moving {file_name}: {e}" + ) def main() -> None: @@ -92,16 +98,12 @@ def main() -> None: parser = argparse.ArgumentParser( description="Organize files in a directory into categorized subfolders." ) - parser.add_argument( - "--path", - required=True, - help="Directory path to organize." - ) + parser.add_argument("--path", required=True, help="Directory path to organize.") parser.add_argument( "--interval", type=int, default=0, - help="Interval (in minutes) to repeat automatically (0 = run once)." + help="Interval (in minutes) to repeat automatically (0 = run once).", ) args = parser.parse_args() diff --git a/time_delta.py b/time_delta.py index 9b46d34f79f..dc9d479303d 100644 --- a/time_delta.py +++ b/time_delta.py @@ -1,7 +1,7 @@ """ Time Delta Calculator -This module provides functionality to calculate the absolute difference +This module provides functionality to calculate the absolute difference in seconds between two timestamps in the format: Day dd Mon yyyy hh:mm:ss +xxxx """ # ----------------------------------------------------------------------------- @@ -31,7 +31,6 @@ # 88200 # ------------------------------------------------------------------------------ - import datetime from typing import List, Tuple @@ -39,10 +38,10 @@ def parse_timestamp(timestamp: str) -> datetime.datetime: """ Parse a timestamp string into a datetime object. - + Args: timestamp: String in the format "Day dd Mon yyyy hh:mm:ss +xxxx" - + Returns: A datetime object with timezone information """ @@ -54,18 +53,18 @@ def parse_timestamp(timestamp: str) -> datetime.datetime: def calculate_time_delta(t1: str, t2: str) -> int: """ Calculate the absolute time difference between two timestamps in seconds. - + Args: t1: First timestamp string t2: Second timestamp string - + Returns: Absolute time difference in seconds as an integer """ # Parse both timestamps dt1 = parse_timestamp(t1) dt2 = parse_timestamp(t2) - + # Calculate absolute difference and convert to seconds time_difference = abs(dt1 - dt2) return int(time_difference.total_seconds()) @@ -74,7 +73,7 @@ def calculate_time_delta(t1: str, t2: str) -> int: def read_test_cases() -> Tuple[int, List[Tuple[str, str]]]: """ Read test cases from standard input. - + Returns: A tuple containing: - Number of test cases @@ -83,12 +82,12 @@ def read_test_cases() -> Tuple[int, List[Tuple[str, str]]]: try: num_test_cases = int(input().strip()) test_cases = [] - + for _ in range(num_test_cases): timestamp1 = input().strip() timestamp2 = input().strip() test_cases.append((timestamp1, timestamp2)) - + return num_test_cases, test_cases except ValueError as e: raise ValueError("Invalid input format") from e @@ -100,11 +99,11 @@ def main() -> None: """ try: num_test_cases, test_cases = read_test_cases() - + for t1, t2 in test_cases: result = calculate_time_delta(t1, t2) print(result) - + except ValueError as e: print(f"Error: {e}") except Exception as e: diff --git a/to check leap year.py b/to check leap year.py index ece26a6ecca..c54b3719527 100644 --- a/to check leap year.py +++ b/to check leap year.py @@ -15,6 +15,7 @@ False """ + def is_leap_year(year: int) -> bool: """ Return True if year is a leap year, False otherwise. @@ -29,6 +30,7 @@ def is_leap_year(year: int) -> bool: if __name__ == "__main__": import doctest + doctest.testmod() year_input = input("Enter a year: ").strip() From 5f27d8e4d39f2064d77da286d6466281e3834768 Mon Sep 17 00:00:00 2001 From: lighting9999 Date: Sun, 19 Oct 2025 17:40:09 +0800 Subject: [PATCH 3/4] upgrade version --- .github/workflows/python.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/python.yml b/.github/workflows/python.yml index 11b97531109..e768d653419 100644 --- a/.github/workflows/python.yml +++ b/.github/workflows/python.yml @@ -21,7 +21,7 @@ jobs: - name: Set up Python uses: actions/setup-python@v5 with: - python-version: '3.13.7' + python-version: '3.14.0' - name: Install all dependencies and tools run: | From ef887455345e5c0e1c350aca04527b84384f8c2b Mon Sep 17 00:00:00 2001 From: lighting9999 Date: Sun, 19 Oct 2025 17:42:56 +0800 Subject: [PATCH 4/4] ingore F405 --- .github/workflows/python.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/python.yml b/.github/workflows/python.yml index e768d653419..20b0f50af6b 100644 --- a/.github/workflows/python.yml +++ b/.github/workflows/python.yml @@ -38,7 +38,7 @@ jobs: run: pytest || true - name: Run Ruff checks with ignored rules - run: ruff check . --ignore B904,B905,EM101,EXE001,G004,ISC001,PLC0415,PLC1901,PLW060,PLW1641,PLW2901,PT011,PT018,PT028,S101,S311,SIM905,SLF001 + run: ruff check . --ignore B904,B905,EM101,EXE001,G004,ISC001,PLC0415,PLC1901,PLW060,PLW1641,PLW2901,PT011,PT018,PT028,S101,S311,SIM905,SLF001,F405 - name: Run Mypy type checks run: mypy . --ignore-missing-imports || true \ No newline at end of file