Window handle allocation while hidden

I am using wxpython 4.1.1 with Python 3.6.8 on Linux CentOS 8.3

I am working on a camera streaming application using gstreamer. I need to know the window handle of a widget (using GetHandle) prior to showing the widget. Is there a way to force the allocation of the handle without performing a Show() followed by a Hide() (which does not seem a very elegant solution)?

on Windows the handle is given straight after init of superclass (as it should be, I think)