Closed streambinder closed 1 year ago
Cannot raise NoPermission instance as:
NoPermission
Expression e has type vim.fault.NoPermission but must extend BaseException.
e
vim.fault.NoPermission
Reference code:
def f() -> None: ... try: return partial(vim.ServiceInstance, ...)() except vim.fault.NoPermission as e: ... raise e
raise vim.fault.NoPermission()
mypy
pyre
I'd expect raise vim.fault.NoPermission() to not be linted as an error.
No response
Fixed in https://github.com/vmware/pyvmomi/commit/4e387cc3d2754eaa48716d59aa2f34a0027deec3
Describe the bug
Cannot raise
NoPermission
instance as:Reference code:
Reproduction steps
raise vim.fault.NoPermission()
mypy
/pyre
against itExpected behavior
I'd expect
raise vim.fault.NoPermission()
to not be linted as an error.Additional context
No response