Open something that needs input in a gnome-terminal. This can be vim or a page on text file like "more" or "less".
Type in a few keys, see how it all works fine.
resize and or move so that a small part of the window is outside the screen.
Type in a few keys, see how there are multi-second delays half the time on any typed input.
I can reproduce this problem on Ubuntu 19.04.
It's most likely an issue with one of GTK, GNOME Shell, Mutter, Wayland, or along these lines; not with the Terminal itself.
The problem only occurs to me on Wayland; not on X11.
The problem is reproducible with VTE test app, including a bit older version 0.52, so the recent changes to how updates are done are irrelevant.
With "less", and pressing the Up/Down keys to scroll, I can reproduce the issue if the window is partially offscreen to the bottom or to the right (but not when to the left). With "mc", and pressing the Up/Down keys to move the file cursor, I can reproduce the issue only if the window is partially offscreen to the bottom (but not when it's offscreen to the left or right). Really weird. As you said, it's buggy about half the time, but when it's buggy then further presses of the same key doesn't get it unstuck.
Often when I quit these apps, the prompt isn't immediately shown, it takes another while for it to appear. Other than that, I cannot reproduce the problem at the shell prompt.
A bit of debugging reveals that the input is immediately sent to the applications as desired; it's the output (i.e. actually painting what happened) that's delayed.
Most of the time the window is repainted correctly as soon as the mouse enters another window (no matter if it's another gnome-terminal window or some other app), but the latest when I click to give that other window the focus.
Most of the time the window is repainted correctly whenever there's activity in another window (no matter if it's another gnome-terminal window or some other app, e.g. xterm). E.g. execute "while sleep 5; do date; done" in another fully onscreen gnome-terminal or xterm window, and notice that the buggy gnome-terminal window gets repainted every five seconds. (This makes it hard to debug: if you want to see some info (e.g. VTE_DEBUG or strace) real time then you already modify the behavior and mostly eliminate the bug.)
this seems to have been fixed for me now, but I dont know by what or how ?