hook.py: Fixes lua type conversion on exit status callback.