To reproduce, create a Python file with the following contents:
Place the cursor on the middle line and press Cmd Enter.
Only the middle line is sent to the Console. However, because this is one statement spread over 3 lines, the whole statement should be sent to the Console, not just the current line.