forked from realpython/materials
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Upgrade linters and switch to Ruff (realpython#530)
* Update Python, Black, and Flake8 versions * Black 24 updates * Switch from Flake8 to Ruff for linting * Ruff fixes * Add information about Ruff in README * Black --------- Co-authored-by: Dan Bader <[email protected]>
- Loading branch information
Showing
543 changed files
with
822 additions
and
801 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,7 @@ | ||
""" | ||
Linter to ensure standard folder structure | ||
""" | ||
|
||
import pathlib | ||
import re | ||
import sys | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1 change: 0 additions & 1 deletion
1
asterioids-pygame-project/source_code_final/space_rocks/__main__.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,5 @@ | ||
from game import SpaceRocks | ||
|
||
|
||
if __name__ == "__main__": | ||
space_rocks = SpaceRocks() | ||
space_rocks.main_loop() |
1 change: 0 additions & 1 deletion
1
asterioids-pygame-project/source_code_final/space_rocks/game.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1 change: 0 additions & 1 deletion
1
asterioids-pygame-project/source_code_final/space_rocks/models.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1 change: 0 additions & 1 deletion
1
asterioids-pygame-project/source_code_step_1/space_rocks/__main__.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,5 @@ | ||
from game import SpaceRocks | ||
|
||
|
||
if __name__ == "__main__": | ||
space_rocks = SpaceRocks() | ||
space_rocks.main_loop() |
1 change: 0 additions & 1 deletion
1
asterioids-pygame-project/source_code_step_10/space_rocks/__main__.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,5 @@ | ||
from game import SpaceRocks | ||
|
||
|
||
if __name__ == "__main__": | ||
space_rocks = SpaceRocks() | ||
space_rocks.main_loop() |
1 change: 0 additions & 1 deletion
1
asterioids-pygame-project/source_code_step_10/space_rocks/game.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1 change: 0 additions & 1 deletion
1
asterioids-pygame-project/source_code_step_10/space_rocks/models.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1 change: 0 additions & 1 deletion
1
asterioids-pygame-project/source_code_step_2/space_rocks/__main__.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,5 @@ | ||
from game import SpaceRocks | ||
|
||
|
||
if __name__ == "__main__": | ||
space_rocks = SpaceRocks() | ||
space_rocks.main_loop() |
1 change: 0 additions & 1 deletion
1
asterioids-pygame-project/source_code_step_3/space_rocks/__main__.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,5 @@ | ||
from game import SpaceRocks | ||
|
||
|
||
if __name__ == "__main__": | ||
space_rocks = SpaceRocks() | ||
space_rocks.main_loop() |
1 change: 0 additions & 1 deletion
1
asterioids-pygame-project/source_code_step_3/space_rocks/game.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,4 @@ | ||
import pygame | ||
|
||
from utils import load_sprite | ||
|
||
|
||
|
1 change: 0 additions & 1 deletion
1
asterioids-pygame-project/source_code_step_4/space_rocks/__main__.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,5 @@ | ||
from game import SpaceRocks | ||
|
||
|
||
if __name__ == "__main__": | ||
space_rocks = SpaceRocks() | ||
space_rocks.main_loop() |
1 change: 0 additions & 1 deletion
1
asterioids-pygame-project/source_code_step_4/space_rocks/game.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,4 @@ | ||
import pygame | ||
|
||
from models import GameObject | ||
from utils import load_sprite | ||
|
||
|
1 change: 0 additions & 1 deletion
1
asterioids-pygame-project/source_code_step_5/space_rocks/__main__.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,5 @@ | ||
from game import SpaceRocks | ||
|
||
|
||
if __name__ == "__main__": | ||
space_rocks = SpaceRocks() | ||
space_rocks.main_loop() |
1 change: 0 additions & 1 deletion
1
asterioids-pygame-project/source_code_step_5/space_rocks/game.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,4 @@ | ||
import pygame | ||
|
||
from models import Spaceship | ||
from utils import load_sprite | ||
|
||
|
1 change: 0 additions & 1 deletion
1
asterioids-pygame-project/source_code_step_5/space_rocks/models.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1 change: 0 additions & 1 deletion
1
asterioids-pygame-project/source_code_step_6/space_rocks/__main__.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,5 @@ | ||
from game import SpaceRocks | ||
|
||
|
||
if __name__ == "__main__": | ||
space_rocks = SpaceRocks() | ||
space_rocks.main_loop() |
1 change: 0 additions & 1 deletion
1
asterioids-pygame-project/source_code_step_6/space_rocks/game.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,4 @@ | ||
import pygame | ||
|
||
from models import Asteroid, Spaceship | ||
from utils import get_random_position, load_sprite | ||
|
||
|
1 change: 0 additions & 1 deletion
1
asterioids-pygame-project/source_code_step_6/space_rocks/models.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1 change: 0 additions & 1 deletion
1
asterioids-pygame-project/source_code_step_7/space_rocks/__main__.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,5 @@ | ||
from game import SpaceRocks | ||
|
||
|
||
if __name__ == "__main__": | ||
space_rocks = SpaceRocks() | ||
space_rocks.main_loop() |
1 change: 0 additions & 1 deletion
1
asterioids-pygame-project/source_code_step_7/space_rocks/game.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,4 @@ | ||
import pygame | ||
|
||
from models import Asteroid, Spaceship | ||
from utils import get_random_position, load_sprite | ||
|
||
|
1 change: 0 additions & 1 deletion
1
asterioids-pygame-project/source_code_step_7/space_rocks/models.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1 change: 0 additions & 1 deletion
1
asterioids-pygame-project/source_code_step_8/space_rocks/__main__.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,5 @@ | ||
from game import SpaceRocks | ||
|
||
|
||
if __name__ == "__main__": | ||
space_rocks = SpaceRocks() | ||
space_rocks.main_loop() |
1 change: 0 additions & 1 deletion
1
asterioids-pygame-project/source_code_step_8/space_rocks/game.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,4 @@ | ||
import pygame | ||
|
||
from models import Asteroid, Spaceship | ||
from utils import get_random_position, load_sprite | ||
|
||
|
1 change: 0 additions & 1 deletion
1
asterioids-pygame-project/source_code_step_8/space_rocks/models.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1 change: 0 additions & 1 deletion
1
asterioids-pygame-project/source_code_step_9/space_rocks/__main__.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,5 @@ | ||
from game import SpaceRocks | ||
|
||
|
||
if __name__ == "__main__": | ||
space_rocks = SpaceRocks() | ||
space_rocks.main_loop() |
Oops, something went wrong.