Skip to content

Commit 1c55cf5

Browse files
committed
"Update ruff pre-commit hook
"
1 parent cc008ca commit 1c55cf5

2 files changed

Lines changed: 2 additions & 3 deletions

File tree

.pre-commit-config.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ repos:
1010
- id: end-of-file-fixer
1111
- id: trailing-whitespace
1212
- repo: https://github.com/astral-sh/ruff-pre-commit
13-
rev: v0.3.4
13+
rev: v0.15.8
1414
hooks:
1515
- id: ruff-format
1616
- id: ruff

examples/yotoplayer_mp3_player_demo.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -77,8 +77,7 @@
7777
if last_right_knob != current_right_knob:
7878
print("right", last_right_knob, current_right_knob)
7979
track += current_right_knob - last_right_knob - 1
80-
if track < 0:
81-
track = 0
80+
track = max(track, 0)
8281
last_right_knob = current_right_knob
8382
print("next", track)
8483
audio.stop()

0 commit comments

Comments
 (0)