diff options
author | Giampaolo Rodola <g.rodola@gmail.com> | 2020-10-31 15:37:31 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-10-31 15:37:31 +0100 |
commit | 9aba2efe6cee0a343002d0453674aca68a7b7aec (patch) | |
tree | 2b0b95c7711bcba4f3911ea44b9d9846a18380d4 /scripts | |
parent | 40abe5c0aa3e258161284b58cedcee1e11a66e75 (diff) | |
download | psutil-9aba2efe6cee0a343002d0453674aca68a7b7aec.tar.gz |
Fix py 3.9 [WinError 998] Invalid access to memory location (#1866)
Diffstat (limited to 'scripts')
-rwxr-xr-x | scripts/internal/download_wheels_appveyor.py | 2 | ||||
-rwxr-xr-x | scripts/internal/winmake.py | 29 | ||||
-rwxr-xr-x | scripts/netstat.py | 3 |
3 files changed, 29 insertions, 5 deletions
diff --git a/scripts/internal/download_wheels_appveyor.py b/scripts/internal/download_wheels_appveyor.py index bbae2e94..a6773f34 100755 --- a/scripts/internal/download_wheels_appveyor.py +++ b/scripts/internal/download_wheels_appveyor.py @@ -25,7 +25,7 @@ from psutil._common import print_color BASE_URL = 'https://ci.appveyor.com/api' -PY_VERSIONS = ['2.7', '3.5', '3.6', '3.7', '3.8'] +PY_VERSIONS = ['2.7', '3.6', '3.7', '3.8', '3.9'] TIMEOUT = 30 diff --git a/scripts/internal/winmake.py b/scripts/internal/winmake.py index 3d9d0a8d..faa2aea8 100755 --- a/scripts/internal/winmake.py +++ b/scripts/internal/winmake.py @@ -525,6 +525,12 @@ def print_api_speed(): sh("%s -Wa scripts\\internal\\print_api_speed.py" % PYTHON) +def download_appveyor_wheels(): + """Download appveyor wheels.""" + sh("%s -Wa scripts\\internal\\download_wheels_appveyor.py " + "--user giampaolo --project psutil" % PYTHON) + + def get_python(path): if not path: return sys.executable @@ -532,9 +538,25 @@ def get_python(path): return path # try to look for a python installation given a shortcut name path = path.replace('.', '') - vers = ('26', '27', '36', '37', '38', - '26-64', '27-64', '36-64', '37-64', '38-64' - '26-32', '27-32', '36-32', '37-32', '38-32') + vers = ( + '26', + '26-32', + '26-64', + '27', + '27-32', + '27-64', + '36', + '36-32', + '36-64', + '37', + '37-32', + '37-64', + '38', + '38-32', + '38-64', + '39-32', + '39-64', + ) for v in vers: pypath = r'C:\\python%s\python.exe' % v if path in pypath and os.path.isfile(pypath): @@ -554,6 +576,7 @@ def main(): sp.add_parser('build', help="build") sp.add_parser('clean', help="deletes dev files") sp.add_parser('coverage', help="run coverage tests.") + sp.add_parser('download-appveyor-wheels', help="download wheels.") sp.add_parser('help', help="print this help") sp.add_parser('install', help="build + install in develop/edit mode") sp.add_parser('install-git-hooks', help="install GIT pre-commit hook") diff --git a/scripts/netstat.py b/scripts/netstat.py index 5a21358e..1832a096 100755 --- a/scripts/netstat.py +++ b/scripts/netstat.py @@ -48,13 +48,14 @@ def main(): raddr = "" if c.raddr: raddr = "%s:%s" % (c.raddr) + name = proc_names.get(c.pid, '?') or '' print(templ % ( proto_map[(c.family, c.type)], laddr, raddr or AD, c.status, c.pid or AD, - proc_names.get(c.pid, '?')[:15], + name[:15], )) |