Fix [ 771097 ] frozen programs fail due to implicit import of "warnings".

If the initial import of warnings fails, clear the error.  When the module
is actually needed, if the original import failed, see if it has managed
to find its way to sys.modules yet and if so, remember it.
2 files changed