Skip to content
This repository has been archived by the owner on Nov 15, 2023. It is now read-only.

Add arithmetic dispatch errors. #8726

Merged
merged 7 commits into from May 10, 2021

Conversation

shaunxw
Copy link
Contributor

@shaunxw shaunxw commented May 4, 2021

  • Introduce Arithmetic(ArithmeticError) variant.
  • Replace custom arithmetic errors in FRAME.
  • Replace overflow/underflow in TokenError.
  • Add token and arithmetic errors in DispatchError equality test.

Closes #8544

@cla-bot-2021
Copy link

cla-bot-2021 bot commented May 7, 2021

User @shaunxw, please sign the CLA here.

@shaunxw shaunxw changed the title WIP - Add arithmetic dispatch errors. Add arithmetic dispatch errors. May 9, 2021
@shaunxw shaunxw marked this pull request as ready for review May 9, 2021 08:12
@shawntabrizi
Copy link
Contributor

great :)

@shawntabrizi shawntabrizi added B7-runtimenoteworthy C1-low PR touches the given topic and has a low impact on builders. D3-trivial 🧸 PR contains trivial changes in a runtime directory that do not require an audit labels May 9, 2021
@shawntabrizi shawntabrizi added this to In progress in Runtime via automation May 9, 2021
@shawntabrizi shawntabrizi moved this from In progress to Please Review in Runtime May 9, 2021
@shawntabrizi
Copy link
Contributor

@jacogr I think this is a breaking change for you?

Copy link
Contributor

@shawntabrizi shawntabrizi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this makes sense to me

@jacogr
Copy link
Contributor

jacogr commented May 10, 2021

Not a breaking change, but does require an backwards-compatible adjustment.

Runtime automation moved this from Please Review to Needs Audit May 10, 2021
@bkchr bkchr merged commit efd262f into paritytech:master May 10, 2021
Runtime automation moved this from Needs Audit to Done May 10, 2021
@shaunxw shaunxw deleted the sw/dispatch-error-arithmetic branch May 10, 2021 23:14
@shawntabrizi shawntabrizi moved this from Done to Archive in Runtime May 27, 2021
nazar-pc pushed a commit to subspace/substrate that referenced this pull request Aug 8, 2021
* Add arithmetic dispatch errors.

* Replace custom overflow errors.

* Replace custom underflow and division by zero errors.

* Replace overflow/underflow in token error.

* Add token and arithmetic errors in dispatch error equality test.

* Trigger CI.
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
C1-low PR touches the given topic and has a low impact on builders. D3-trivial 🧸 PR contains trivial changes in a runtime directory that do not require an audit
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add Overflow to DispatchError
4 participants