If you enable the "Punch on the Fly" feature in Logic Pro and then punch in to record while playing, you may hear a glitch in the monitored audio.
This happens when you use the Record key command to start recording. To avoid this issue, use the Record Toggle key command instead. You can check the Key Commands window in Logic to see which key combination is assigned to Record Toggle.