Be a little bit more fail save in wrapper.py for unexpected types