def system_module(mod):
    """A simple way to determine if a module is a system module"""
    try:
        return "lib/python" in mod.__file__
    except AttributeError:
        return True
    except TypeError:
        return False