@@ -202,7 +202,7 @@ impl<T: Config<I>, I: Instance> MessageDispatch<T::MessageId> for Module<T, I> {
202202 let message = match message {
203203 Ok ( message) => message,
204204 Err ( _) => {
205- frame_support :: debug :: trace!( "Message {:?}/{:?}: rejected before actual dispatch" , bridge, id) ;
205+ log :: trace!( "Message {:?}/{:?}: rejected before actual dispatch" , bridge, id) ;
206206 Self :: deposit_event ( RawEvent :: MessageRejected ( bridge, id) ) ;
207207 return ;
208208 }
@@ -212,7 +212,7 @@ impl<T: Config<I>, I: Instance> MessageDispatch<T::MessageId> for Module<T, I> {
212212 // (we want it to be the same, because otherwise we may decode Call improperly)
213213 let expected_version = <T as frame_system:: Config >:: Version :: get ( ) . spec_version ;
214214 if message. spec_version != expected_version {
215- frame_support :: debug :: trace!(
215+ log :: trace!(
216216 "Message {:?}/{:?}: spec_version mismatch. Expected {:?}, got {:?}" ,
217217 bridge,
218218 id,
@@ -232,7 +232,7 @@ impl<T: Config<I>, I: Instance> MessageDispatch<T::MessageId> for Module<T, I> {
232232 let call = match message. call . into ( ) {
233233 Ok ( call) => call,
234234 Err ( _) => {
235- frame_support :: debug :: trace!( "Failed to decode Call from message {:?}/{:?}" , bridge, id, ) ;
235+ log :: trace!( "Failed to decode Call from message {:?}/{:?}" , bridge, id, ) ;
236236 Self :: deposit_event ( RawEvent :: MessageCallDecodeFailed ( bridge, id) ) ;
237237 return ;
238238 }
@@ -243,15 +243,15 @@ impl<T: Config<I>, I: Instance> MessageDispatch<T::MessageId> for Module<T, I> {
243243 CallOrigin :: SourceRoot => {
244244 let hex_id = derive_account_id :: < T :: SourceChainAccountId > ( bridge, SourceAccount :: Root ) ;
245245 let target_id = T :: AccountIdConverter :: convert ( hex_id) ;
246- frame_support :: debug :: trace!( "Root Account: {:?}" , & target_id) ;
246+ log :: trace!( "Root Account: {:?}" , & target_id) ;
247247 target_id
248248 }
249249 CallOrigin :: TargetAccount ( source_account_id, target_public, target_signature) => {
250250 let digest = account_ownership_digest ( & call, source_account_id, message. spec_version , bridge) ;
251251
252252 let target_account = target_public. into_account ( ) ;
253253 if !target_signature. verify ( & digest[ ..] , & target_account) {
254- frame_support :: debug :: trace!(
254+ log :: trace!(
255255 "Message {:?}/{:?}: origin proof is invalid. Expected account: {:?} from signature: {:?}" ,
256256 bridge,
257257 id,
@@ -262,20 +262,20 @@ impl<T: Config<I>, I: Instance> MessageDispatch<T::MessageId> for Module<T, I> {
262262 return ;
263263 }
264264
265- frame_support :: debug :: trace!( "Target Account: {:?}" , & target_account) ;
265+ log :: trace!( "Target Account: {:?}" , & target_account) ;
266266 target_account
267267 }
268268 CallOrigin :: SourceAccount ( source_account_id) => {
269269 let hex_id = derive_account_id ( bridge, SourceAccount :: Account ( source_account_id) ) ;
270270 let target_id = T :: AccountIdConverter :: convert ( hex_id) ;
271- frame_support :: debug :: trace!( "Source Account: {:?}" , & target_id) ;
271+ log :: trace!( "Source Account: {:?}" , & target_id) ;
272272 target_id
273273 }
274274 } ;
275275
276276 // filter the call
277277 if !T :: CallFilter :: filter ( & call) {
278- frame_support :: debug :: trace!(
278+ log :: trace!(
279279 "Message {:?}/{:?}: the call ({:?}) is rejected by filter" ,
280280 bridge,
281281 id,
@@ -291,7 +291,7 @@ impl<T: Config<I>, I: Instance> MessageDispatch<T::MessageId> for Module<T, I> {
291291 let dispatch_info = call. get_dispatch_info ( ) ;
292292 let expected_weight = dispatch_info. weight ;
293293 if message. weight < expected_weight {
294- frame_support :: debug :: trace!(
294+ log :: trace!(
295295 "Message {:?}/{:?}: passed weight is too low. Expected at least {:?}, got {:?}" ,
296296 bridge,
297297 id,
@@ -310,11 +310,11 @@ impl<T: Config<I>, I: Instance> MessageDispatch<T::MessageId> for Module<T, I> {
310310 // finally dispatch message
311311 let origin = RawOrigin :: Signed ( origin_account) . into ( ) ;
312312
313- frame_support :: debug :: trace!( "Message being dispatched is: {:?}" , & call) ;
313+ log :: trace!( "Message being dispatched is: {:?}" , & call) ;
314314 let dispatch_result = call. dispatch ( origin) ;
315315 let actual_call_weight = extract_actual_weight ( & dispatch_result, & dispatch_info) ;
316316
317- frame_support :: debug :: trace!(
317+ log :: trace!(
318318 "Message {:?}/{:?} has been dispatched. Weight: {} of {}. Result: {:?}" ,
319319 bridge,
320320 id,
@@ -606,7 +606,7 @@ mod tests {
606606 vec![ EventRecord {
607607 phase: Phase :: Initialization ,
608608 event: Event :: call_dispatch( call_dispatch:: Event :: <TestRuntime >:: MessageWeightMismatch (
609- bridge, id, 1279000 , 0 ,
609+ bridge, id, 1345000 , 0 ,
610610 ) ) ,
611611 topics: vec![ ] ,
612612 } ] ,
0 commit comments