cosmopolitan/third_party/python/Python
Gautham 2fe8571010
Add zipimport hook at the end just in case (#280)
In Python, the zipimport path hook is usually the first entry in
sys.path_hooks, so that any zip files in sys.path can be handled
correctly. In the APE, the zipimport hook was removed because it was
relatively slow compared to Cosmopolitan when it came to handling
imports from the APE's internal zip store.

However, some python scripts (for example when pip installs some
packages) modify sys.path to consider a local zip file, and then attempt
to import from it. This change prevents potential "unable to import"
errors in such cases, so that Actually Portable Python can be more of a
drop-in improved replacement.
2021-09-29 01:50:34 -07:00
..
clinic Make whitespace changes 2021-08-13 03:20:45 -07:00
_warnings.c Begin incorporating Python unit tests into build 2021-09-12 21:04:44 -07:00
asdl.c Make whitespace changes 2021-08-13 03:20:45 -07:00
ast.c Make numerous improvements 2021-09-28 01:52:34 -07:00
atexit.c Begin incorporating Python unit tests into build 2021-09-12 21:04:44 -07:00
bltinmodule.c Begin incorporating Python unit tests into build 2021-09-12 21:04:44 -07:00
ceval.c Make numerous improvements 2021-09-28 01:52:34 -07:00
ceval_gil.inc Make whitespace changes 2021-08-13 03:20:45 -07:00
codecs.c Make numerous improvements 2021-09-28 01:52:34 -07:00
compile.c Make whitespace changes 2021-08-13 03:20:45 -07:00
condvar.h Undiamond Python headers 2021-08-12 14:07:40 -07:00
cosmomodule.c Make numerous improvements 2021-09-28 01:52:34 -07:00
dtoa.c Make numerous improvements 2021-09-28 01:52:34 -07:00
dynamic_annotations.c Make whitespace changes 2021-08-13 03:20:45 -07:00
dynload_dl.c Make numerous improvements 2021-09-28 01:52:34 -07:00
dynload_shlib.c Make numerous improvements 2021-09-28 01:52:34 -07:00
dynload_stub.c Make whitespace changes 2021-08-13 03:20:45 -07:00
dynload_win.c Make numerous improvements 2021-09-28 01:52:34 -07:00
errors.c Make numerous improvements 2021-09-28 01:52:34 -07:00
fatality.c Begin incorporating Python unit tests into build 2021-09-12 21:04:44 -07:00
fdisinteractive.c Begin incorporating Python unit tests into build 2021-09-12 21:04:44 -07:00
fileutils.c Make whitespace changes 2021-08-13 03:20:45 -07:00
finalize.c Begin incorporating Python unit tests into build 2021-09-12 21:04:44 -07:00
flags.c Begin incorporating Python unit tests into build 2021-09-12 21:04:44 -07:00
flushstdfiles.c Begin incorporating Python unit tests into build 2021-09-12 21:04:44 -07:00
formatter_unicode.c Make whitespace changes 2021-08-13 03:20:45 -07:00
frozen.c Make numerous improvements 2021-09-28 01:52:34 -07:00
frozenmain.c Make whitespace changes 2021-08-13 03:20:45 -07:00
frozenmodules.c Improve Libc by making Python work even better 2021-08-18 22:16:23 -07:00
future.c Make numerous improvements 2021-09-28 01:52:34 -07:00
getargs.c Make numerous improvements 2021-09-28 01:52:34 -07:00
getcompiler.c Make numerous improvements 2021-09-28 01:52:34 -07:00
getcopyright.c Improve Libc by making Python work even better 2021-08-18 22:16:23 -07:00
getopt.c Make numerous improvements 2021-09-28 01:52:34 -07:00
getplatform.c Make numerous improvements 2021-09-28 01:52:34 -07:00
getsig.c Begin incorporating Python unit tests into build 2021-09-12 21:04:44 -07:00
getversion.c Make whitespace changes 2021-08-13 03:20:45 -07:00
graminit.c Begin incorporating Python unit tests into build 2021-09-12 21:04:44 -07:00
import.c Add zipimport hook at the end just in case (#280) 2021-09-29 01:50:34 -07:00
importdl.c Make whitespace changes 2021-08-13 03:20:45 -07:00
importdl.h Undiamond Python headers 2021-08-12 14:07:40 -07:00
initfsencoding.c Begin incorporating Python unit tests into build 2021-09-12 21:04:44 -07:00
initialized.c Begin incorporating Python unit tests into build 2021-09-12 21:04:44 -07:00
initimport.c Make numerous improvements 2021-09-28 01:52:34 -07:00
initmain.c Begin incorporating Python unit tests into build 2021-09-12 21:04:44 -07:00
initsigs.c Begin incorporating Python unit tests into build 2021-09-12 21:04:44 -07:00
initsite.c Begin incorporating Python unit tests into build 2021-09-12 21:04:44 -07:00
initstdio.c Make numerous improvements 2021-09-28 01:52:34 -07:00
inittab.c Improve Libc by making Python work even better 2021-08-18 22:16:23 -07:00
makeopcodetargets.py Perform build and magnum tuning 2021-08-10 10:26:13 -07:00
marshal.c Implement tree-shaking for Python sources 2021-09-05 01:20:03 -07:00
modsupport.c Make whitespace changes 2021-08-13 03:20:45 -07:00
mysnprintf.c Make numerous improvements 2021-09-28 01:52:34 -07:00
mystrtoul.c Make whitespace changes 2021-08-13 03:20:45 -07:00
opcode_targets.inc Improve Libc by making Python work even better 2021-08-18 22:16:23 -07:00
peephole.c Make numerous improvements 2021-09-28 01:52:34 -07:00
progname.c Begin incorporating Python unit tests into build 2021-09-12 21:04:44 -07:00
pyarena.c Make whitespace changes 2021-08-13 03:20:45 -07:00
pyfpe.c Make whitespace changes 2021-08-13 03:20:45 -07:00
pyhash.c Begin incorporating Python unit tests into build 2021-09-12 21:04:44 -07:00
pylifecycle.c Add zipimport hook at the end just in case (#280) 2021-09-29 01:50:34 -07:00
pymath.c Make whitespace changes 2021-08-13 03:20:45 -07:00
pystate.c Make numerous improvements 2021-09-28 01:52:34 -07:00
pystrcmp.c Make whitespace changes 2021-08-13 03:20:45 -07:00
pystrhex.c Make whitespace changes 2021-08-13 03:20:45 -07:00
pystrtod.c Make whitespace changes 2021-08-13 03:20:45 -07:00
Python-ast.c Implement tree-shaking for Python sources 2021-09-05 01:20:03 -07:00
pythonhome.c Begin incorporating Python unit tests into build 2021-09-12 21:04:44 -07:00
pythonrun.c Make numerous improvements 2021-09-28 01:52:34 -07:00
pytime.c Make whitespace changes 2021-08-13 03:20:45 -07:00
random.c Make numerous improvements 2021-09-28 01:52:34 -07:00
restoresigs.c Begin incorporating Python unit tests into build 2021-09-12 21:04:44 -07:00
sigcheck.c Make whitespace changes 2021-08-13 03:20:45 -07:00
structmember.c Make whitespace changes 2021-08-13 03:20:45 -07:00
symtable.c Make whitespace changes 2021-08-13 03:20:45 -07:00
sysmodule.c Make numerous improvements 2021-09-28 01:52:34 -07:00
thread.c Make numerous improvements 2021-09-28 01:52:34 -07:00
thread_foobar.h Undiamond Python headers 2021-08-12 14:07:40 -07:00
thread_nt.inc Undiamond Python headers 2021-08-12 14:07:40 -07:00
thread_pthread.inc Make numerous improvements 2021-09-28 01:52:34 -07:00
traceback.c Make whitespace changes 2021-08-13 03:20:45 -07:00
wordcode_helpers.inc Make whitespace changes 2021-08-13 03:20:45 -07:00