<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def modpath_pkg_resources(module, entry_point):
 """ Goes through pkg_resources for compliance with various PEPs. This one accepts a module as argument. """


    result = []
    try:
        path = resource_filename_mod_entry_point(module.__name__, entry_point)
    except ImportError:
        logger.warning("module '%s' could not be imported", module.__name__)
    except Exception:
        logger.warning("%r does not appear to be a valid module", module)
    else:
        if path:
            result.append(path)
    return result