Fixed tracing to include all switch events