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

Replace log with tracing and record extrinsic info #535

Merged
merged 10 commits into from
May 12, 2022
Merged

Conversation

ascjones
Copy link
Member

Migrate to tracing crate in line with jsonrpsee and substrate.

Also add some extra logs for inspecting extrinsic construction.

Copy link
Member

@niklasad1 niklasad1 left a comment

Choose a reason for hiding this comment

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

LGTM, but you need to fix log! in a couple of more places :P

@@ -31,7 +32,7 @@ pub use sp_runtime::generic::Era;
/// "additional" parameters that are signed and used in transactions.
/// see [`BaseExtrinsicParams`] for an implementation that is compatible with
/// a Polkadot node.
pub trait ExtrinsicParams<T: Config> {
pub trait ExtrinsicParams<T: Config>: Debug {
Copy link
Collaborator

@jsdw jsdw May 12, 2022

Choose a reason for hiding this comment

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

Just wondering why this is wanted (and some of the other Debugs scattered about)?

Copy link
Member Author

Choose a reason for hiding this comment

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

See comment below 👇

Chose to do on the trait itself rather than the method for a better error message.

tracing::debug!(
"additional_and_extra_params: {:?}",
additional_and_extra_params
);
Copy link
Member Author

Choose a reason for hiding this comment

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

@jsdw because of this

Copy link
Collaborator

Choose a reason for hiding this comment

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

Aha!

@ascjones ascjones merged commit 31f8c37 into master May 12, 2022
@ascjones ascjones deleted the aj/tracing branch May 12, 2022 13:54
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 this pull request may close these issues.

None yet

4 participants