cleaned up for pivot debugging