add debug flag and use it to block some logging
move onPanelOpen over main editor UI