Add more XCM tracing (#4211)

* add more logging to currency adapter

* add more logging to barriers

* reformat currency adapter trace logs

* add tracing logs for filter asset location

* add tracing logs to fungibles adapter

* add tracing to origin conversion

* add tracing logs for xcm weight trading

* fix compile errors

* add more tracing logs to xcm executor

* formatting and compile fixes

* add some tracing logs to pallet-xcm

* adjust log target in executor to debug

* fix closure args
This commit is contained in:
Alexander Popiak
2021-11-11 09:42:35 +01:00
committed by GitHub
parent fc19a6798c
commit 8156dbe73d
8 changed files with 168 additions and 11 deletions
+13 -1
View File
@@ -1192,6 +1192,11 @@ pub mod pallet {
/// Note that a particular destination to whom we would like to send a message is unknown
/// and queue it for version discovery.
fn note_unknown_version(dest: &MultiLocation) {
log::trace!(
target: "xcm::pallet_xcm::note_unknown_version",
"XCM version is unknown for destination: {:?}",
dest,
);
let versioned_dest = VersionedMultiLocation::from(dest.clone());
VersionDiscoveryQueue::<T>::mutate(|q| {
if let Some(index) = q.iter().position(|i| &i.0 == &versioned_dest) {
@@ -1214,7 +1219,14 @@ pub mod pallet {
Self::note_unknown_version(dest);
SafeXcmVersion::<T>::get()
})
.ok_or(())
.ok_or_else(|| {
log::trace!(
target: "xcm::pallet_xcm::wrap_version",
"Could not determine a version to wrap XCM for destination: {:?}",
dest,
);
()
})
.and_then(|v| xcm.into().into_version(v.min(XCM_VERSION)))
}
}