Local GP ports vs. physical ports

Take a look at the widget property for MIDI.
You can enable the Thru option.
This way a learned MIDI message is not blocked by the widget.

For sure you know this post?