Skip to content

Commit 25cba01

Browse files
authored
prepare (#183)
* prepare * Update benchmarks.md
1 parent 23f931a commit 25cba01

File tree

7 files changed

+12
-11
lines changed

7 files changed

+12
-11
lines changed

README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
| CI/CD | [![CI - Test](https://github.com/ofek/coincurve/actions/workflows/build.yml/badge.svg)](https://github.com/ofek/coincurve/actions/workflows/build.yml) [![CI - Coverage](https://img.shields.io/codecov/c/github/ofek/coincurve/master.svg?logo=codecov&logoColor=red)](https://codecov.io/github/ofek/coincurve) |
66
| Docs | [![CI - Docs](https://github.com/ofek/coincurve/actions/workflows/docs.yml/badge.svg)](https://github.com/ofek/coincurve/actions/workflows/docs.yml) |
77
| Package | [![PyPI - Version](https://img.shields.io/pypi/v/coincurve.svg?logo=pypi&label=PyPI&logoColor=gold)](https://pypi.org/project/coincurve/) [![PyPI - Downloads](https://img.shields.io/pypi/dm/coincurve.svg?color=blue&label=Downloads&logo=pypi&logoColor=gold)](https://pypi.org/project/coincurve/) [![PyPI - Python Version](https://img.shields.io/pypi/pyversions/coincurve.svg?logo=python&label=Python&logoColor=gold)](https://pypi.org/project/coincurve/) |
8-
| Meta | [![Hatch project](https://img.shields.io/badge/%F0%9F%A5%9A-Hatch-4051b5.svg){ loading=lazy }](https://github.com/ofek/dep-sync) [![linting - Ruff](https://img.shields.io/endpoint?url=https://raw.githubusercontent.com/astral-sh/ruff/main/assets/badge/v2.json){ loading=lazy }](https://github.com/astral-sh/ruff) [![types - Mypy](https://img.shields.io/badge/types-Mypy-blue.svg){ loading=lazy }](https://github.com/python/mypy) [![License - MIT OR Apache-2.0](https://img.shields.io/badge/license-MIT%20OR%20Apache--2.0-9400d3.svg)](https://spdx.org/licenses/) [![GitHub Sponsors](https://img.shields.io/github/sponsors/ofek?logo=GitHub%20Sponsors&style=social)](https://github.com/sponsors/ofek) |
8+
| Meta | [![Hatch project](https://img.shields.io/badge/%F0%9F%A5%9A-Hatch-4051b5.svg)](https://github.com/ofek/dep-sync) [![linting - Ruff](https://img.shields.io/endpoint?url=https://raw.githubusercontent.com/astral-sh/ruff/main/assets/badge/v2.json)](https://github.com/astral-sh/ruff) [![types - Mypy](https://img.shields.io/badge/types-Mypy-blue.svg)](https://github.com/python/mypy) [![License - MIT OR Apache-2.0](https://img.shields.io/badge/license-MIT%20OR%20Apache--2.0-9400d3.svg)](https://spdx.org/licenses/) [![GitHub Sponsors](https://img.shields.io/github/sponsors/ofek?logo=GitHub%20Sponsors&style=social)](https://github.com/sponsors/ofek) |
99

1010
-----
1111

docs/benchmarks.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ Download [Hatch](https://hatch.pypa.io/latest/install/) or [UV](https://docs.ast
1414

1515
| Library | Key generation | Signing | Verification | Key export | Key import |
1616
| --- | --- | --- | --- | --- | --- |
17-
| coincurve v20.0.0 | 33.4 | 52.8 | 58.4 | 12.6 | 39.4 |
17+
| coincurve v21.0.0 | 33.4 | 52.8 | 59.0 | 12.6 | 39.4 |
1818
| [fastecdsa](https://github.com/AntonKueltz/fastecdsa) v3.0.1 | 1319.6 | 1449.5 | 1160.4 | 1402.9 | 15.5 |
1919

2020
!!! note

docs/index.md

+4-4
Original file line numberDiff line numberDiff line change
@@ -2,10 +2,10 @@
22

33
| | |
44
| --- | --- |
5-
| CI/CD | [![CI - Test](https://github.com/ofek/coincurve/actions/workflows/build.yml/badge.svg)](https://github.com/ofek/coincurve/actions/workflows/build.yml) [![CI - Coverage](https://img.shields.io/codecov/c/github/ofek/coincurve/master.svg?logo=codecov&logoColor=red)](https://codecov.io/github/ofek/coincurve) |
6-
| Docs | [![CI - Docs](https://github.com/ofek/coincurve/actions/workflows/docs.yml/badge.svg)](https://github.com/ofek/coincurve/actions/workflows/docs.yml) |
7-
| Package | [![PyPI - Version](https://img.shields.io/pypi/v/coincurve.svg?logo=pypi&label=PyPI&logoColor=gold)](https://pypi.org/project/coincurve/) [![PyPI - Downloads](https://img.shields.io/pypi/dm/coincurve.svg?color=blue&label=Downloads&logo=pypi&logoColor=gold)](https://pypi.org/project/coincurve/) [![PyPI - Python Version](https://img.shields.io/pypi/pyversions/coincurve.svg?logo=python&label=Python&logoColor=gold)](https://pypi.org/project/coincurve/) |
8-
| Meta | [![code style - black](https://img.shields.io/badge/code%20style-black-000000.svg)](https://github.com/psf/black) [![types - Mypy](https://img.shields.io/badge/types-Mypy-blue.svg)](https://github.com/ambv/black) [![imports - isort](https://img.shields.io/badge/imports-isort-ef8336.svg)](https://github.com/pycqa/isort) [![License - MIT OR Apache-2.0](https://img.shields.io/badge/license-MIT%20OR%20Apache--2.0-9400d3.svg)](https://spdx.org/licenses/) [![GitHub Sponsors](https://img.shields.io/github/sponsors/ofek?logo=GitHub%20Sponsors&style=social)](https://github.com/sponsors/ofek) |
5+
| CI/CD | [![CI - Test](https://github.com/ofek/coincurve/actions/workflows/build.yml/badge.svg){ loading=lazy }](https://github.com/ofek/coincurve/actions/workflows/build.yml) [![CI - Coverage](https://img.shields.io/codecov/c/github/ofek/coincurve/master.svg?logo=codecov&logoColor=red){ loading=lazy }](https://codecov.io/github/ofek/coincurve) |
6+
| Docs | [![CI - Docs](https://github.com/ofek/coincurve/actions/workflows/docs.yml/badge.svg){ loading=lazy }](https://github.com/ofek/coincurve/actions/workflows/docs.yml) |
7+
| Package | [![PyPI - Version](https://img.shields.io/pypi/v/coincurve.svg?logo=pypi&label=PyPI&logoColor=gold){ loading=lazy }](https://pypi.org/project/coincurve/) [![PyPI - Downloads](https://img.shields.io/pypi/dm/coincurve.svg?color=blue&label=Downloads&logo=pypi&logoColor=gold){ loading=lazy }](https://pypi.org/project/coincurve/) [![PyPI - Python Version](https://img.shields.io/pypi/pyversions/coincurve.svg?logo=python&label=Python&logoColor=gold){ loading=lazy }](https://pypi.org/project/coincurve/) |
8+
| Meta | [![Hatch project](https://img.shields.io/badge/%F0%9F%A5%9A-Hatch-4051b5.svg){ loading=lazy }](https://github.com/ofek/dep-sync) [![linting - Ruff](https://img.shields.io/endpoint?url=https://raw.githubusercontent.com/astral-sh/ruff/main/assets/badge/v2.json){ loading=lazy }](https://github.com/astral-sh/ruff) [![types - Mypy](https://img.shields.io/badge/types-Mypy-blue.svg){ loading=lazy }](https://github.com/python/mypy) [![License - MIT OR Apache-2.0](https://img.shields.io/badge/license-MIT%20OR%20Apache--2.0-9400d3.svg){ loading=lazy }](https://spdx.org/licenses/) [![GitHub Sponsors](https://img.shields.io/github/sponsors/ofek?logo=GitHub%20Sponsors&style=social){ loading=lazy }](https://github.com/sponsors/ofek) |
99

1010
-----
1111

pyproject.toml

+2-2
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ Source = "https://github.com/ofek/coincurve"
5858

5959
# --- hatch ---
6060
[tool.hatch.version]
61-
path = "src/coincurve/__about__.py"
61+
path = "src/coincurve/__init__.py"
6262

6363
[tool.hatch.build.targets.wheel.hooks.custom]
6464

@@ -108,7 +108,7 @@ source_pkgs = ["coincurve", "tests"]
108108
branch = true
109109
parallel = true
110110
omit = [
111-
"src/coincurve/__about__.py",
111+
"src/coincurve/__init__.py",
112112
"tests/test_bench.py",
113113
]
114114

scripts/bench.py

+3-2
Original file line numberDiff line numberDiff line change
@@ -94,13 +94,14 @@ def sign() -> BenchmarkSpec:
9494
def verify() -> BenchmarkSpec:
9595
return BenchmarkSpec(
9696
f"""
97-
from coincurve import PrivateKey
97+
from coincurve import PrivateKey, verify_signature
9898
message = {MESSAGE!r}.encode()
9999
private_key = PrivateKey()
100100
signature = private_key.sign(message)
101+
public_key = private_key.public_key.format(compressed=False)
101102
""",
102103
"""
103-
assert private_key.public_key.verify(signature, message)
104+
assert verify_signature(signature, message, public_key)
104105
""",
105106
)
106107

src/coincurve/__about__.py

-1
This file was deleted.

src/coincurve/__init__.py

+1
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
from coincurve.keys import PrivateKey, PublicKey, PublicKeyXOnly
33
from coincurve.utils import verify_signature
44

5+
__version__ = "20.0.0"
56
__all__ = [
67
"GLOBAL_CONTEXT",
78
"Context",

0 commit comments

Comments
 (0)