Skip to content
This repository was archived by the owner on Nov 24, 2025. It is now read-only.

Commit bcb7e09

Browse files
committed
improve some failure message as recommended in review
1 parent a58565d commit bcb7e09

File tree

1 file changed

+2
-2
lines changed
  • src/Chainweb/PayloadProvider/EVM

1 file changed

+2
-2
lines changed

src/Chainweb/PayloadProvider/EVM/Utils.hs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -101,8 +101,8 @@ instance HasTextRepresentation (HexQuantity Natural) where
101101
toText (HexQuantity a) = T.pack $ printf @(Natural -> String) "0x%x" a
102102
fromText t = T.hexadecimal <$> strip0x t >>= \case
103103
Right (x, "") -> return $ HexQuantity x
104-
Right (x, _) -> throwM $ TextFormatException
105-
$ "pending characters after parsing " <> sshow x
104+
Right (x, p) -> throwM $ TextFormatException
105+
$ sshow (T.length p) <> " pending characters after parsing " <> sshow x
106106
Left e -> throwM $ TextFormatException (T.pack e)
107107
{-# INLINE toText #-}
108108
{-# INLINE fromText #-}

0 commit comments

Comments
 (0)