Config.init_libpath only looks at sysconfig.get_python_lib() (usually /usr/lib/), and doesnt include sysconfig.get_python_lib(plat_specific=True) , which is usually /usr/lib64. The later is where re.match will come from for most distro users. Both directories need to be used to determine if a module is part of the stdlib.
Config.init_libpath
only looks atsysconfig.get_python_lib()
(usually/usr/lib/
), and doesnt includesysconfig.get_python_lib(plat_specific=True)
, which is usually/usr/lib64
. The later is wherere.match
will come from for most distro users. Both directories need to be used to determine if a module is part of the stdlib.