My guess it you might be registering or looking at the wrong module in your initial code, as the small code snippet seems to work.
Try to add a name to the hook so that the print statement will show you which layer was called with which inputs and outputs.