Expand description
Enhanced logging system for light-program-test
This module provides Solana Explorer-like transaction logging with:
- Hierarchical instruction display with inner instructions
- Account changes tracking
- Light Protocol specific parsing and formatting
- Configurable verbosity levels
- Color-coded output
Logging behavior:
- File logging: Always enabled when
enhanced_logging.enabled = true(default) - Log file: Written to
target/light_program_test.log - Console output: Only when
RUST_BACKTRACEis set ANDlog_events = true - Log file is overwritten at session start, then appended for each transaction
Re-exports§
pub use config::EnhancedLoggingConfig;pub use config::LogVerbosity;pub use formatter::TransactionFormatter;pub use types::AccountChange;pub use types::EnhancedInstructionLog;pub use types::EnhancedTransactionLog;pub use types::ParsedInstructionData;pub use types::TransactionStatus;
Modules§
- config
- Configuration types for enhanced logging
- decoder
- Instruction decoder for Light Protocol and common Solana programs
- formatter
- Transaction formatting utilities for explorer-style output
- types
- Type definitions for enhanced logging
Functions§
- log_
transaction_ enhanced - Main entry point for enhanced transaction logging
- log_
transaction_ enhanced_ with_ console - Enhanced transaction logging with console output control
- should_
use_ enhanced_ logging - Check if enhanced logging should be used instead of basic logging