Skip to content

Commit 06f13b8

Browse files
authored
Code formatting (#1989)
* don't ignore F811 * Fix duplicate imports * pep8 stuff
1 parent c2fe1bf commit 06f13b8

35 files changed

+62
-57
lines changed

arcade/__init__.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,7 @@ def configure_logging(level: Optional[int] = None):
3333
ch.setFormatter(logging.Formatter('%(relativeCreated)s %(name)s %(levelname)s - %(message)s'))
3434
LOG.addHandler(ch)
3535

36+
3637
# The following is used to load ffmpeg libraries.
3738
# Currently Arcade is only shipping binaries for Mac OS
3839
# as ffmpeg is not needed for support on Windows and Linux.

arcade/cache/texture.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -93,13 +93,13 @@ def put(
9393
name = texture.cache_name
9494
if strong:
9595
self._strong_entries.put(name, texture)
96-
if self._strong_file_entries.get(file_path): # type: ignore # pending https://github.com/pythonarcade/arcade/issues/1752
96+
if self._strong_file_entries.get(file_path): # type: ignore # pending https://github.com/pythonarcade/arcade/issues/1752
9797
raise ValueError(f"File path {file_path} already in cache")
9898
if file_path:
9999
self._strong_file_entries.put(str(file_path), texture)
100100
else:
101101
self._weak_entires.put(name, texture)
102-
if self._weak_file_entries.get(file_path): # type: ignore # pending https://github.com/pythonarcade/arcade/issues/1752
102+
if self._weak_file_entries.get(file_path): # type: ignore # pending https://github.com/pythonarcade/arcade/issues/1752
103103
raise ValueError(f"File path {file_path} already in cache")
104104
if file_path:
105105
self._weak_file_entries.put(str(file_path), texture)

arcade/context.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@
2525

2626
__all__ = ["ArcadeContext"]
2727

28+
2829
class ArcadeContext(Context):
2930
"""
3031
An OpenGL context implementation for Arcade with added custom features.

arcade/examples/gl/bindless_texture.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -149,7 +149,7 @@ def __init__(self):
149149
resource_cycle = cycle(resources)
150150

151151
# Load enough textures to cover for each point/sprite
152-
for i in range(16 * 9):
152+
for i in range(16 * 9):
153153
texture = self.ctx.load_texture(next(resource_cycle))
154154
texture.wrap_x = self.ctx.CLAMP_TO_EDGE
155155
texture.wrap_y = self.ctx.CLAMP_TO_EDGE

arcade/examples/net_process_animal_facts.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -217,8 +217,10 @@ def start(self) -> int:
217217

218218
class Facts:
219219
"""Base class for fact providers"""
220+
220221
def get_fact(self) -> str:
221222
raise NotImplementedError()
223+
222224
def get_image(self) -> arcade.Texture:
223225
raise NotImplementedError()
224226

arcade/examples/shape_list_demo_skylines.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,6 @@
1010
ShapeElementList,
1111
create_rectangle_filled,
1212
create_polygon,
13-
create_rectangle_filled,
1413
create_rectangles_filled_with_colors,
1514
)
1615

arcade/experimental/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,4 +46,4 @@
4646
])
4747

4848
except ImportError:
49-
pass
49+
pass

arcade/experimental/query_demo.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ def __init__(self, width, height, title):
3838
self.sprites.draw() # Force the list to build
3939

4040
self.sprites.program = self.ctx.sprite_list_program_no_cull
41-
print(f"Initialization time: {time.time() -start}")
41+
print(f"Initialization time: {time.time() - start}")
4242

4343
self.query = self.ctx.query()
4444
self.frames = 0

arcade/experimental/video_cv2.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -122,7 +122,6 @@ def update(self, delta_time: float) -> None:
122122
self.video.set(cv2.CAP_PROP_POS_FRAMES, 0)
123123

124124

125-
126125
class CV2PlayerView(arcade.View):
127126
"""
128127
A simple view to hold a video player using cv2.

arcade/experimental/video_player.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -76,6 +76,7 @@ def get_video_size(self) -> Tuple[int, int]:
7676
height /= video_format.sample_aspect
7777
return width, height
7878

79+
7980
class VideoPlayerView(arcade.View):
8081
def __init__(self, path: Union[str, Path]) -> None:
8182
super().__init__()

0 commit comments

Comments
 (0)