[compatability] exceptions using a metaclass that defines __instancecheck__ and __subclasscheck__ doesn't work in pypy2
Created originally on Bitbucket by Tom Grainger (Thomas Grainger)
repro here: https://github.com/giampaolo/psutil/issues/1659
import errno
from psutil._compat import ChildProcessError
class MyPretendChildProcessError(EnvironmentError):
errno = errno.ECHILD
try:
raise MyPretendChildProcessError
except ChildProcessError:
pass