Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Wrong doc for creating Keypair #758

Closed
jonasnick opened this issue Oct 28, 2024 · 0 comments · Fixed by #779
Closed

Wrong doc for creating Keypair #758

jonasnick opened this issue Oct 28, 2024 · 0 comments · Fixed by #779

Comments

@jonasnick
Copy link
Collaborator

The docs for from_seckey_slice, from_seckey_str and from_seckey_str_global state that the functions fail if the "the corresponding public key is not even". I don't see why that would be true. The underlying C-function secp256k1_keypair_create does not fail in that case.

Discovered by @uncomputable

apoelstra added a commit that referenced this issue Feb 15, 2025
aaf5fee fix: Invalid secret key (Christian Lewe)
d1d4ff9 doc: Keypair constructors accept odd keys (Christian Lewe)

Pull request description:

  Clarify the conditions when `Keypair` construction fails and correct the error variant that is returned in one of the constructors. Fixes #758

ACKs for top commit:
  Kixunil:
    ACK aaf5fee
  apoelstra:
    ACK aaf5fee; successfully ran local tests

Tree-SHA512: 9b27c4ee1424619f9041183801e7c1214838f0b8d529e9c10a3e1f55264624b6b42b881e369bd9521bfa117d3dd5ce072caed4b8ee51c40e1016fc5be59a2894
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant