cpython/Lib/test/test_importlib
Greg Price 9ece4a5057 Unmark files as executable that can't actually be executed. (GH-15353)
There are plenty of legitimate scripts in the tree that begin with a
`#!`, but also a few that seem to be marked executable by mistake.

Found them with this command -- it gets executable files known to Git,
filters to the ones that don't start with a `#!`, and then unmarks
them as executable:

    $ git ls-files --stage \
      | perl -lane 'print $F[3] if (!/^100644/)' \
      | while read f; do
          head -c2 "$f" | grep -qxF '#!' \
          || chmod a-x "$f"; \
        done

Looking at the list by hand confirms that we didn't sweep up any
files that should have the executable bit after all.  In particular

 * The `.psd` files are images from Photoshop.

 * The `.bat` files sure look like things that can be run.
   But we have lots of other `.bat` files, and they don't have
   this bit set, so it must not be needed for them.



Automerge-Triggered-By: @benjaminp
2019-08-20 21:53:59 -07:00
..
builtin
data cross port importlib-metadata PR #76 (#13903) 2019-06-07 14:23:38 -07:00
data01
data02
data03
extension bpo-32374: Ignore Python-level exceptions in test_bad_traverse (GH-7145) 2018-05-28 14:11:20 +02:00
frozen
import_ bpo-37444: Update differing exception between builtins and importlib (GH-14869) 2019-08-02 22:46:02 -07:00
namespace_pkgs
source bpo-34022: Stop forcing of hash-based invalidation with SOURCE_DATE_EPOCH (GH-9607) 2018-10-10 18:43:14 +02:00
zipdata01
zipdata02
__init__.py
__main__.py
abc.py
fixtures.py bpo-37697: Sync with importlib_metadata 0.19 (#14993) 2019-07-28 14:59:24 -04:00
test_abc.py Unmark files as executable that can't actually be executed. (GH-15353) 2019-08-20 21:53:59 -07:00
test_api.py bpo-33169: Remove values of `None` from sys.path_importer_cache when invalidating caches (GH-6402) 2018-04-06 16:10:18 -07:00
test_lazy.py bpo-36766: Typos in docs and code comments (GH-13116) 2019-05-06 14:57:17 -04:00
test_locks.py bpo-35202: Remove unused imports in tests. (GH-10561) 2018-11-16 17:32:58 +02:00
test_main.py bpo-37697: Sync with importlib_metadata 0.19 (#14993) 2019-07-28 14:59:24 -04:00
test_metadata_api.py bpo-34632: Add importlib.metadata (GH-12547) 2019-05-24 16:59:01 -07:00
test_namespace_pkgs.py bpo-35843: Implement __getitem__ for _NamespacePath (GH-11690) 2019-03-08 10:58:00 -08:00
test_open.py bpo-32248: Fix test_importlib.test_open() (#5213) 2018-01-17 15:21:50 +01:00
test_path.py
test_pkg_import.py bpo-19696: Replace deprecated method in "test_import_pkg.py" (GH-14466) 2019-07-03 11:22:40 -07:00
test_read.py bpo-33151: Handle submodule resources (GH-6268) 2018-03-27 09:59:38 -07:00
test_resource.py bpo-33755: Fix importlib.resources isolation tests (#7412) 2018-06-05 09:40:45 -07:00
test_spec.py
test_threaded_import.py bpo-19696: Move threaded_import_hangers (GH-14655) 2019-07-12 14:22:05 -07:00
test_util.py bpo-37444: Update differing exception between builtins and importlib (GH-14869) 2019-08-02 22:46:02 -07:00
test_windows.py
test_zip.py bpo-37697: Sync with importlib_metadata 0.19 (#14993) 2019-07-28 14:59:24 -04:00
threaded_import_hangers.py bpo-19696: Move threaded_import_hangers (GH-14655) 2019-07-12 14:22:05 -07:00
util.py Fix typos in comments, docs and test names (#15018) 2019-07-30 18:16:13 -04:00