From 437559cd037a97103b5d898ddfe40d0145cbfc59 Mon Sep 17 00:00:00 2001 From: Nick Brassel Date: Wed, 15 Sep 2021 08:45:14 +1000 Subject: [PATCH] Swap to fnvhash due to deps. --- lib/python/qmk/xap/gen_firmware/header_generator.py | 4 ++-- requirements.txt | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/lib/python/qmk/xap/gen_firmware/header_generator.py b/lib/python/qmk/xap/gen_firmware/header_generator.py index 9b295ed8f3..66f01d1855 100755 --- a/lib/python/qmk/xap/gen_firmware/header_generator.py +++ b/lib/python/qmk/xap/gen_firmware/header_generator.py @@ -1,7 +1,7 @@ """This script generates the XAP protocol generated header to be compiled into QMK. """ import re -import pyhash +from fnvhash import fnv1a_32 from qmk.commands import get_git_version from qmk.constants import GPL2_HEADER_C_LIKE, GENERATED_HEADER_C_LIKE @@ -107,7 +107,7 @@ def generate_header(output_file, keyboard): lines.append(f'#define XAP_BCD_VERSION 0x{int(b.group(1)):02d}{int(b.group(2)):02d}{int(b.group(3)):04d}ul') b = prog.match(get_git_version()) lines.append(f'#define QMK_BCD_VERSION 0x{int(b.group(1)):02d}{int(b.group(2)):02d}{int(b.group(3)):04d}ul') - keyboard_id = pyhash.murmur3_32()(keyboard) + keyboard_id = fnv1a_32(keyboard) lines.append(f'#define XAP_KEYBOARD_IDENTIFIER 0x{keyboard_id:08X}ul') lines.append('') diff --git a/requirements.txt b/requirements.txt index 079dcdb8ac..6357b4e2eb 100644 --- a/requirements.txt +++ b/requirements.txt @@ -2,11 +2,11 @@ appdirs argcomplete colorama +fnvhash hid hjson jsonschema>=3 milc>=1.4.2 pygments -pyhash pyusb qmk-dotty-dict