Files
pezkuwi-subxt/substrate/frame
Liam Aharon d715caa63a Improve try-state developer experience & fix bug (#2019)
Making some devex improvements as I audit our chains adherence to
try-state invariants, in preparation for automated try-state checks and
alerting.

Note to reviewer: while you're here, if you have time would be great to
get your eyes on https://github.com/paritytech/polkadot-sdk/pull/1297
also since it touches a similar file and I'd like to avoid merge
conflicts :P

## Devex Improvements

- Changes the log level of logs informing the user that try-state checks
are being run for a pallet from debug to info
- Improves how errors are communicated
- Errors are logged when they are encountered, rather than after
everything has been executed
- Exact pallet the error originated from is included with the error log
  - Clearly see all errors and how many there are, rather than only one
  - Closes #136 

### Example of new logs

<img width="1185" alt="Screenshot 2023-10-25 at 15 44 44"
src="https://github.com/paritytech/polkadot-sdk/assets/16665596/b75588a2-1c64-45df-bbc8-bcb8bf8b0fe0">

### Same but with old logs (run with RUST_LOG=debug)

Notice only informed of one of the errors, and it's unclear which pallet
it originated

<img width="1185" alt="Screenshot 2023-10-25 at 15 39 01"
src="https://github.com/paritytech/polkadot-sdk/assets/16665596/e3429cb1-489e-430a-9716-77c052e5dae6">
 

## Bug fix

When dry-running migrations and `checks.try_state()` is `true`, only run
`try_state` checks after migrations have been executed. Otherwise,
`try_state` checks that expect state to be in at a HIGHER storage
version than is on-chain could incorrectly fail.

---------

Co-authored-by: command-bot <>
2023-10-30 09:43:32 +01:00
..
2023-10-26 21:55:49 +02:00
2023-10-27 21:43:51 +02:00
2023-10-24 17:59:38 +02:00
2023-10-24 17:59:38 +02:00
2023-10-24 17:59:38 +02:00
2023-10-24 17:59:38 +02:00
2023-10-24 17:59:38 +02:00
2023-10-27 21:43:51 +02:00
2023-10-24 17:59:38 +02:00
2023-10-27 11:38:16 +02:00
2023-10-24 17:59:38 +02:00
2023-10-27 21:43:51 +02:00
2023-10-27 21:43:51 +02:00
2023-08-29 13:39:41 +02:00
2023-10-27 11:38:16 +02:00
2023-09-04 12:02:32 +03:00

FRAME

The FRAME development environment provides modules (called "pallets") and support libraries that you can use, modify, and extend to build the runtime logic to suit the needs of your blockchain.

Documentation

https://docs.substrate.io/reference/frame-pallets/

Issues

https://github.com/orgs/paritytech/projects/40