Issue2251

classification
Title: Support ensurepip
Type: Severity: normal
Components: Versions: Jython 2.7
Milestone:
process
Status: closed Resolution: fixed
Dependencies: Superseder:
Assigned To: zyasoft Nosy List: pekka.klarck, zyasoft
Priority: high Keywords:

Created on 2015-01-14.17:50:40 by zyasoft, last changed 2015-03-02.01:14:48 by zyasoft.

Messages
msg9393 (view) Author: Jim Baker (zyasoft) Date: 2015-01-14.17:50:40
We need to support jython -m ensurepip as follows:

1) Change the installer so this invocation is performed, by default (but can be checked off if desired)

2) Windows is currently running into this problem, no doubt because it assumes that the system is posix instead of nt, based on os.name/os._name issues:

Traceback (most recent call last):
  File "<string>", line 1, in <module>
  File "C:\jythondev\jython27\dist\Lib\runpy.py", line 175, in run_module
    return _run_module_code(code, init_globals, run_name,
  File "C:\jythondev\jython27\dist\Lib\runpy.py", line 81, in _run_module_code
    _run_code(code, mod_globals, init_globals,
  File "C:\jythondev\jython27\dist\Lib\runpy.py", line 72, in _run_code
    exec code in run_globals
  File "C:\jythondev\jython27\dist\Lib\ensurepip\__main__.py", line 4, in <module>
    ensurepip._main()
  File "C:\jythondev\jython27\dist\Lib\ensurepip\__init__.py", line 220, in _main
    bootstrap(
  File "C:\jythondev\jython27\dist\Lib\ensurepip\__init__.py", line 123, in bootstrap
    _run_pip(args + [p[0] for p in _PROJECTS], additional_paths)
  File "C:\jythondev\jython27\dist\Lib\ensurepip\__init__.py", line 45, in _run_pip
    import pip
  File "c:\users\jim\appdata\local\temp\tmpzhzoqk\pip-1.6-py2.py3-none-any.whl\pip\__init__.py", line 10, in <module>
  File "c:\users\jim\appdata\local\temp\tmpzhzoqk\pip-1.6-py2.py3-none-any.whl\pip\util.py", line 17, in <module>
  File "c:\users\jim\appdata\local\temp\tmpzhzoqk\pip-1.6-py2.py3-none-any.whl\pip\locations.py", line 109, in <module>
  File "c:\users\jim\appdata\local\temp\tmpzhzoqk\pip-1.6-py2.py3-none-any.whl\pip\locations.py", line 71, in _get_build
_prefix
  File "c:\users\jim\appdata\local\temp\tmpzhzoqk\pip-1.6-py2.py3-none-any.whl\pip\locations.py", line 65, in __get_user
name
  File "C:\jythondev\jython27\dist\Lib\pwd.py", line 18, in <module>
    raise ImportError, 'pwd module not supported on Windows'
ImportError: pwd module not supported on Windows

Triaged to urgent since this should be a full part of RC1
msg9516 (view) Author: Jim Baker (zyasoft) Date: 2015-02-12.00:27:55
Depends on #1491 (windows native launcher, aka jython.exe)
msg9536 (view) Author: Jim Baker (zyasoft) Date: 2015-02-22.06:20:24
Fixed as of https://hg.python.org/jython/rev/5d62f637a8d1
History
Date User Action Args
2015-03-02 01:14:48zyasoftsetstatus: pending -> closed
2015-02-22 06:20:25zyasoftsetstatus: open -> pending
resolution: fixed
messages: + msg9536
2015-02-12 00:27:55zyasoftsetmessages: + msg9516
2015-02-07 01:37:07zyasoftsetpriority: urgent -> high
2015-01-14 17:51:36zyasoftsetnosy: + pekka.klarck
2015-01-14 17:50:41zyasoftcreate