Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Installing editable dependency in empty dir gives unhelpful message #3206

Closed
frostming opened this issue Nov 10, 2018 · 1 comment
Closed

Comments

@frostming
Copy link
Contributor

frostming commented Nov 10, 2018

Issue description

On master branch, pipenv install -e ${package} in empty directory gives error.
2018.10.13 is fine.
Incomplete implementation of #2846

Expected result

Pipfile and virtualenv are created automatically and editable package is installed successfully.

Actual result

$ pipenv install -e click
Traceback (most recent call last):
  File "/Users/fming/.local/share/virtualenvs/pipenv-46tK8lkP/bin/pipenv", line 11, in <module>
    load_entry_point('pipenv', 'console_scripts', 'pipenv')()
  File "/Users/fming/wkspace/github/pipenv/pipenv/vendor/click/core.py", line 764, in __call__
    return self.main(*args, **kwargs)
  File "/Users/fming/wkspace/github/pipenv/pipenv/vendor/click/core.py", line 717, in main
    rv = self.invoke(ctx)
  File "/Users/fming/wkspace/github/pipenv/pipenv/vendor/click/core.py", line 1137, in invoke
    return _process_result(sub_ctx.command.invoke(sub_ctx))
  File "/Users/fming/wkspace/github/pipenv/pipenv/vendor/click/core.py", line 956, in invoke
    return ctx.invoke(self.callback, **ctx.params)
  File "/Users/fming/wkspace/github/pipenv/pipenv/vendor/click/core.py", line 555, in invoke
    return callback(*args, **kwargs)
  File "/Users/fming/wkspace/github/pipenv/pipenv/vendor/click/decorators.py", line 64, in new_func
    return ctx.invoke(f, obj, *args, **kwargs)
  File "/Users/fming/wkspace/github/pipenv/pipenv/vendor/click/core.py", line 555, in invoke
    return callback(*args, **kwargs)
  File "/Users/fming/wkspace/github/pipenv/pipenv/vendor/click/decorators.py", line 17, in new_func
    return f(get_current_context(), *args, **kwargs)
  File "/Users/fming/wkspace/github/pipenv/pipenv/cli/command.py", line 249, in install
    editable_packages=state.installstate.editables,
  File "/Users/fming/wkspace/github/pipenv/pipenv/core.py", line 1698, in do_install
    raise exceptions.PipfileNotFound(project.pipfile_location)
  File "/Users/fming/wkspace/github/pipenv/pipenv/exceptions.py", line 149, in __init__
    super(PipfileNotFound, self).__init__(filename, message=fix_utf8(message), extra=extra, **kwargs)
  File "/Users/fming/wkspace/github/pipenv/pipenv/exceptions.py", line 126, in __init__
    FileError.__init__(self, filename=filename, hint=fix_utf8(message), **kwargs)
  File "/Users/fming/wkspace/github/pipenv/pipenv/vendor/click/exceptions.py", line 213, in __init__
    ui_filename = filename_to_ui(filename)
  File "/Users/fming/wkspace/github/pipenv/pipenv/vendor/click/_compat.py", line 453, in filename_to_ui
    value = value.encode('utf-8', 'surrogateescape') \
AttributeError: 'NoneType' object has no attribute 'encode'

Steps to replicate

Provide the steps to replicate (which usually at least includes the commands and the Pipfile).

$ mkdir empty_dir && cd empty_dir
$ pipenv install -e click

Please run $ pipenv --support, and paste the results here. Don't put backticks (`) around it! The output already contains Markdown formatting.

If you're on macOS, run the following:

$ pipenv --support | pbcopy

If you're on Windows, run the following:

> pipenv --support | clip

If you're on Linux, run the following:

$ pipenv --support | xclip
$ pipenv --support

Pipenv version: '2018.10.14.dev0'

Pipenv location: '/Users/fming/wkspace/github/pipenv/pipenv'

Python location: '/Users/fming/.local/share/virtualenvs/pipenv-46tK8lkP/bin/python'

Python installations found:

  • 3.7.0: /Users/fming/.local/share/virtualenvs/pipenv-46tK8lkP/bin/python3
  • 3.7.0: /Users/fming/Library/PythonUp/bin/python3
  • 3.7.0: /Users/fming/Library/PythonUp/bin/python3.7m
  • 3.7.0: /usr/local/bin/python3
  • 3.7.0: /usr/local/bin/python3.7m
  • 2.7.15: /Users/fming/Library/PythonUp/cmd/python2.7
  • 2.7.10: /usr/bin/python
  • 2.7.10: /usr/bin/pythonw
  • 2.7.10: /usr/bin/python2.7

PEP 508 Information:

{'implementation_name': 'cpython',
 'implementation_version': '3.7.0',
 'os_name': 'posix',
 'platform_machine': 'x86_64',
 'platform_python_implementation': 'CPython',
 'platform_release': '18.0.0',
 'platform_system': 'Darwin',
 'platform_version': 'Darwin Kernel Version 18.0.0: Wed Aug 22 20:13:40 PDT '
                     '2018; root:xnu-4903.201.2~1/RELEASE_X86_64',
 'python_full_version': '3.7.0',
 'python_version': '3.7',
 'sys_platform': 'darwin'}

System environment variables:

  • TERM_SESSION_ID
  • SSH_AUTH_SOCK
  • Apple_PubSub_Socket_Render
  • COLORFGBG
  • ITERM_PROFILE
  • SQLITE_EXEMPT_PATH_FROM_VNODE_GUARDS
  • XPC_FLAGS
  • PWD
  • SHELL
  • SECURITYSESSIONID
  • TERM_PROGRAM_VERSION
  • TERM_PROGRAM
  • PATH
  • DISPLAY
  • COLORTERM
  • COMMAND_MODE
  • TERM
  • HOME
  • TMPDIR
  • USER
  • XPC_SERVICE_NAME
  • LOGNAME
  • __CF_USER_TEXT_ENCODING
  • ITERM_SESSION_ID
  • SHLVL
  • OLDPWD
  • ZSH
  • PAGER
  • LESS
  • LSCOLORS
  • PROMPT_EOL_MARK
  • GOPATH
  • GPG_TTY
  • PYTHONDONTWRITEBYTECODE
  • PIP_SHIMS_BASE_MODULE
  • PIP_PYTHON_PATH
  • HELLO
  • PIPENV_ACTIVE
  • VIRTUAL_ENV
  • PS1
  • LANG
  • LC_ALL
  • _
  • PIP_DISABLE_PIP_VERSION_CHECK
  • PYTHONFINDER_IGNORE_UNSUPPORTED

Pipenv–specific environment variables:

  • PIPENV_ACTIVE: 1

Debug–specific environment variables:

  • PATH: /Users/fming/.local/share/virtualenvs/pipenv-46tK8lkP/bin:/Users/fming/wkspace/go/bin:/Users/fming/Library/PythonUp/bin:/Users/fming/Library/PythonUp/cmd:/Users/fming/.local/bin:/Users/fming/wkspace/go/bin:/Users/fming/Library/PythonUp/bin:/Users/fming/Library/PythonUp/cmd:/Users/fming/.local/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/aria2/bin:/usr/local/MacGPG2/bin:/opt/X11/bin
  • SHELL: /bin/zsh
  • LANG: zh_CN.UTF-8
  • PWD: /Users/fming/wkspace/github/tempnew
  • VIRTUAL_ENV: /Users/fming/.local/share/virtualenvs/pipenv-46tK8lkP

@frostming frostming changed the title Installing editable dependency in empty dir gives error Installing editable dependency in empty dir gives unhelpful message Nov 10, 2018
@frostming
Copy link
Contributor Author

Closed via #3207

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant