Skip to content

Commit 3111bd1

Browse files
authored
update API to output int, str, and bytes types (breaking) (#13)
* udpate API (breaking) * use strings for python version matrix
1 parent 3515961 commit 3111bd1

7 files changed

Lines changed: 3367 additions & 868 deletions

File tree

.github/workflows/build-test.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,8 @@ jobs:
1616
build:
1717
strategy:
1818
matrix:
19-
os: [macos-10.15, windows-2019, ubuntu-latest]
20-
python-version: [3.6, 3.7, 3.8, 3.9]
19+
os: [windows-latest, macos-latest, ubuntu-latest]
20+
python-version: ["3.7", "3.8", "3.9", "3.10"]
2121

2222
runs-on: ${{ matrix.os }}
2323
steps:

README.rst

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -51,9 +51,9 @@ MetroHash algorithm. For stateless hashing, it exports ``metrohash64`` and
5151
5252
>>> import metrohash
5353
...
54-
>>> metrohash.metrohash64("abc", seed=0)
54+
>>> metrohash.hash64_int("abc", seed=0)
5555
17099979927131455419
56-
>>> metrohash.metrohash128("abc")
56+
>>> metrohash.hash128_int("abc")
5757
182995299641628952910564950850867298725
5858
5959
@@ -94,7 +94,7 @@ hashing of a 4D NumPy array:
9494
9595
>>> import numpy as np
9696
>>> arr = np.zeros((256, 256, 4))
97-
>>> metrohash.metrohash64(arr)
97+
>>> metrohash.hash64_int(arr)
9898
12125832280816116063
9999
100100
Note that arrays need to be contiguous for this to work. To convert a

pip-freeze.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ ipdb==0.13.9
1010
ipython==7.30.1
1111
jedi==0.18.1
1212
matplotlib-inline==0.1.3
13-
-e git+https://github.com/escherba/python-metrohash@2e8b2c0ea0712339c65cda0c47649f9f1321243a#egg=metrohash
13+
-e git+https://github.com/escherba/python-metrohash@35159617ba4106c99b82701267441c73aca4b951#egg=metrohash
1414
numpy==1.21.5
1515
packaging==21.3
1616
parso==0.8.3

setup.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,7 @@ def is_pure(self):
8686
)
8787

8888

89-
VERSION = '0.1.1'
89+
VERSION = '0.1.1.post0'
9090
URL = "https://github.com/escherba/python-metrohash"
9191

9292

0 commit comments

Comments
 (0)