Fix warning
Trap: Fix missing import
Trap: Flush log after write