Hmmm, how about this, remove ```try ...except``` with ```ignore_status=True```,
```
result = virsh.maxvcpus(option, uri=connect_uri, ignore_status=False,
                                   debug=True)
maxvcpus_test = result.stdout.strip()
status  = result.exit_status
err_msg = result.stderr.strip()
```
Then, you can use ```maxvcpus_test```,```status ```,```err_msg``` to check your point.