* Fix test_import: import machinery and errors
- Emit IMPORT_FROM instead of LOAD_ATTR for `import a.b.c as m`
- Add "partially initialized module" error for circular imports
- Add "cannot access submodule" error for initializing submodules
- Implement script shadowing detection with "consider renaming" hint
- Detect user scripts shadowing stdlib/third-party modules
- Compute original sys.path[0] from sys.argv[0]
- Check sys.stdlib_module_names for stdlib detection
- Respect safe_path setting
- Implement _imp._fix_co_filename for code source_path rewriting
- Add data parameter to _imp.get_frozen_object with marshal deser
- Fix import_from: check __spec__.has_location before using origin
- Set ImportError.path attribute on import failures
- Fix import_star error messages for non-str __all__/__dict__ items
- Always call builtins.__import__ in import_inner
* Propagate __bool__ errors from fromlist in import
Previously, try_to_bool errors were silently swallowed via .ok(),
causing fromlist with broken __bool__ to default to false.
* Downgraded skips in tests
* Fixed failing tests
* Fixed test_ftplib + test_socket + test_ssl + test_threaded_import failures
* Removed comments about which tests are run in which environment
* Addressed PR comments
* Annotated skips on failing tests
* Removed unneeded tests
* Removed unneeded sys import from test_ftplib
* Added annotation to test_ftplib
* Readded skipIf to test_cleanup_with_symlink_modes with a more general ENV_POLLUTING_TESTS_WINDOWS
* Addressed PR comments
* Made changes to minimize diff in PR
* Apply suggestion from @youknowone
---------
Co-authored-by: Jeong, YunWon <69878+youknowone@users.noreply.github.com>
* Replace skips with expectedFailure markings for SimpleTest
* Uncomment Source-PEP451 tests and apply similar monkey-patches as before
* Uncomment Source-PEP302 tests and apply similar monkey-patches as before
* Uncomment Sourceless-PEP451 tests and apply similar monkey-patches as
before
* Uncomment Sourceless-PEP302 tests and apply similar monkey-patches as
before
* disable test_argparse on windows
* fix test_exceptions and mark it as platform dependent
* test importlib on windows
* explain why windows tests fail
* mark test_argparse as non platform-independent
Signed-off-by: Ashwin Naren <arihant2math@gmail.com>