You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We have deprecated all other functions that use the identifier
'schnorrsig' but we missed `generate_schnorrsig_keypair`.
This function is purely a helper function and serves no real purpose
other than to reduce two lines of code to a single line. Downstream
users can write this function themselves if they need it.
Also, we recently added a new public method to `KeyPair` to get the
public key in a slightly more ergonomic fashion. Use `kp.public_key()`
when replacing usage of now deprecated `generate_schnorrsig_keypair`
function.
// In fuzzing mode secret->public key derivation is different, so
451
454
// hard-code the epected result.
452
455
#[cfg(not(fuzzing))]
453
-
let pk = XOnlyPublicKey::from_keypair(&sk);
456
+
let pk = kp.public_key();
454
457
#[cfg(fuzzing)]
455
458
let pk = XOnlyPublicKey::from_slice(&[0x18,0x84,0x57,0x81,0xf6,0x31,0xc4,0x8f,0x1c,0x97,0x09,0xe2,0x30,0x92,0x06,0x7d,0x06,0x83,0x7f,0x30,0xaa,0x0c,0xd0,0x54,0x4a,0xc8,0x87,0xfe,0x91,0xdd,0xd1,0x66]).expect("pk");
0 commit comments