Skip to content

Commit 9c9e572

Browse files
committed
Use lowercase in bytes literals
1 parent f18bc7a commit 9c9e572

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

auto_editor/wavfile.py

+3-3
Original file line numberDiff line numberDiff line change
@@ -45,9 +45,9 @@ def _read_fmt_chunk(
4545
raw_guid = extensible_chunk_data[6:22]
4646

4747
if bytes_order == "big":
48-
tail = b"\x00\x00\x00\x10\x80\x00\x00\xAA\x00\x38\x9B\x71"
48+
tail = b"\x00\x00\x00\x10\x80\x00\x00\xaa\x00\x38\x9b\x71"
4949
else:
50-
tail = b"\x00\x00\x10\x00\x80\x00\x00\xAA\x00\x38\x9B\x71"
50+
tail = b"\x00\x00\x10\x00\x80\x00\x00\xaa\x00\x38\x9b\x71"
5151
if raw_guid.endswith(tail):
5252
format_tag = int.from_bytes(raw_guid[:4], bytes_order)
5353
else:
@@ -249,7 +249,7 @@ def write(fid: io.BufferedWriter, sr: int, arr: np.ndarray) -> None:
249249
total_size = 44 + data_size # Basic WAV header size + data size
250250

251251
if is_rf64 := total_size > 0xFFFFFFFF:
252-
fid.write(b"RF64\xFF\xFF\xFF\xFFWAVE")
252+
fid.write(b"RF64\xff\xff\xff\xffWAVE")
253253
ds64_size = 28
254254
ds64_chunk_data = (0).to_bytes(ds64_size, "little") # placeholder values
255255
fid.write(b"ds64" + struct.pack("<I", ds64_size) + ds64_chunk_data)

0 commit comments

Comments
 (0)