get_exit_code in the shell adaptor now returns None if no exit code is available (instead of raising an exception)

This closes #350