In every aspect of development, trade-offs are inevitable. As previously mentioned, logging is not feasible when dealing with predicates, since predicates are required to be pure. This raises an important question: how do we debug predicates?
Sway, a programming language, categorizes programs into four types, with scripts being one of them. Unlike predicates, scripts allow for shared logic.
Let's move outside our MultiSig project
cd ../..
and create a separate project called predicate-script-logging.
forc new --predicate predicate-script-logging
Copy and paste this new predicate in your src/main.sw. Attempting to build this predicate will result in an error, indicating that logging is an invalid operation.