How about adding a check to compare pool_info["UUID"] with result.stdout.strip(), this can confirm the result is what we want.