-
Notifications
You must be signed in to change notification settings - Fork 47
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
feat: readable linking challenge #483
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm :) Will look nice in the display of metamask. The only thing even better would be probably something like giving MM a typed struct with the info so it could render it even nicer. https://docs.metamask.io/guide/signing-data.html#signtypeddata-v4
Yeah that would be nice, but it's only for ethereum. So we would have a special challenge for ethereum which is also possible. But i think this just makes it more complicated for little gain. It will also not get easier to process on chain. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
So while before we were attempting to have a future-compatible SDK, now we will force all people to upgrade to the new version, otherwise stuff will break. Correct?
@@ -34,10 +34,10 @@ mod connection_record; | |||
mod migration_state; | |||
mod signature; | |||
|
|||
#[cfg(test)] | |||
#[cfg(all(test, feature = "std"))] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I have never seen it used anywhere else. Are you sure there's no other way to do this? Perhaps feature-gating the specific tests or the mock itself?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We always run tests with at least the std
feature. I also want to test get_challenge
in a no_std
environment since debug might be implemented differently there (e.g. for accounts it simply prints nothing).
To be able to test this without std
I need to disable all tests that require std
.
Co-authored-by: Antonio <antonio@kilt.io>
Things break because the SDK doesn't include these surprise changes yes. |
@weichweich do you think it would make sense to expose the new stuff as a new extrinsic? So the old SDK would still work without breaking, and the new SDK would use the new feature. I mean both extrinsics would support Ethereum accounts, but the type of signature would be different. We can then deprecate the old way later on. I guess my main concern is that people can't just decide not to upgrade, since the old linking stuff would break as well. |
Replace the scale encoded challenge with a human readable challenge. Co-authored-by: Antonio <antonio@kilt.io>
fixes /~https://github.com/KILTprotocol/ticket/issues/2499
Replace the scale encoded challenge with a human readable challenge.
Checklist:
array[3]
useget(3)
, ...)