From ffb84de5b7b43b1d09cd527096650588ada08e1e Mon Sep 17 00:00:00 2001 From: Alexandru Ardelean Date: Thu, 16 Apr 2026 12:25:58 +0000 Subject: [PATCH] python-fnv-hash-fast: update to 2.0.2 - bump 0.5.0 -> 2.0.2 - add test.sh Signed-off-by: Alexandru Ardelean --- lang/python/python-fnv-hash-fast/Makefile | 4 ++-- lang/python/python-fnv-hash-fast/test.sh | 15 +++++++++++++++ 2 files changed, 17 insertions(+), 2 deletions(-) create mode 100644 lang/python/python-fnv-hash-fast/test.sh diff --git a/lang/python/python-fnv-hash-fast/Makefile b/lang/python/python-fnv-hash-fast/Makefile index b4758598ec..8bee79bc25 100644 --- a/lang/python/python-fnv-hash-fast/Makefile +++ b/lang/python/python-fnv-hash-fast/Makefile @@ -1,12 +1,12 @@ include $(TOPDIR)/rules.mk PKG_NAME:=python-fnv-hash-fast -PKG_VERSION:=0.5.0 +PKG_VERSION:=2.0.2 PKG_RELEASE:=1 PYPI_NAME:=fnv-hash-fast PYPI_SOURCE_NAME:=fnv_hash_fast -PKG_HASH:=a84d658952776a186418f4158fc8e55ff3c576ac32cc9ef7f8077efdf2d0b89f +PKG_HASH:=8d5f6ac760a7ca091ef9d085b22b12c76caa8fa2897de81cee58f50269c0eb65 PKG_MAINTAINER:=Timothy Ace PKG_LICENSE:=MIT diff --git a/lang/python/python-fnv-hash-fast/test.sh b/lang/python/python-fnv-hash-fast/test.sh new file mode 100644 index 0000000000..3c76d98ad9 --- /dev/null +++ b/lang/python/python-fnv-hash-fast/test.sh @@ -0,0 +1,15 @@ +[ "$1" = python3-fnv-hash-fast ] || exit 0 + +python3 - << 'EOF' +from fnv_hash_fast import fnv1a_32 + +# FNV-1a 32-bit hash of empty string is 0x811c9dc5 +result = fnv1a_32(b"") +assert result == 0x811c9dc5, f"Expected 0x811c9dc5, got {hex(result)}" + +# FNV-1a 32-bit hash of "hello" +result2 = fnv1a_32(b"hello") +assert result2 != result + +print("python3-fnv-hash-fast OK") +EOF