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

poetry self:update on python 2.7 doesn't work #53

Closed
radix opened this issue Apr 18, 2018 · 11 comments
Closed

poetry self:update on python 2.7 doesn't work #53

radix opened this issue Apr 18, 2018 · 11 comments

Comments

@radix
Copy link
Contributor

radix commented Apr 18, 2018

radix@pop-os:~$ poetry self:update -v
Updating to 0.8.4


  [RuntimeError]
  Unable to determine poetry's path


Exception trace:
 /home/radix/.local/lib/python2.7/site-packages/cleo/application.py in run() at line 94
   status_code = self.do_run(input_, output_)
 /home/radix/.local/lib/python2.7/site-packages/poetry/console/application.py in do_run() at line 74
   return super(Application, self).do_run(i, o)
 /home/radix/.local/lib/python2.7/site-packages/cleo/application.py in do_run() at line 197
   status_code = command.run(input_, output_)
 /home/radix/.local/lib/python2.7/site-packages/poetry/console/commands/command.py in run() at line 22
   return super(BaseCommand, self).run(i, o)
 /home/radix/.local/lib/python2.7/site-packages/cleo/commands/base_command.py in run() at line 146
   status_code = self.execute(input_, output_)
 /home/radix/.local/lib/python2.7/site-packages/cleo/commands/command.py in execute() at line 107
   return self.handle()
 /home/radix/.local/lib/python2.7/site-packages/poetry/console/commands/self/update.py in handle() at line 68
   self.update(release)
 /home/radix/.local/lib/python2.7/site-packages/poetry/console/commands/self/update.py in update() at line 102
   raise RuntimeError('Unable to determine poetry\'s path')

self:update [--preview] [--] [<version>]
@sdispater
Copy link
Member

That's weird. It should not happen.

Could you execute:

python -c "import sys; print(sys.prefix, getattr(sys, 'base_prefix', None), getattr(sys,'real_prefix', None))"

@radix
Copy link
Contributor Author

radix commented Apr 19, 2018

@sdispater sorry I didn't get back to you sooner!

radix@pop-os:~$ python -c "import sys; print(sys.prefix, getattr(sys, 'base_prefix', None), getattr(sys,'real_prefix', None))"
('/usr', None, None)

@radix
Copy link
Contributor Author

radix commented Apr 19, 2018

and it case it matters:

{}radix@pop-os:~$ python
Python 2.7.14 (default, Sep 23 2017, 22:06:14)
[GCC 7.2.0] on linux2

@sdispater
Copy link
Member

And where is the poetry executable?

which poetry

@radix
Copy link
Contributor Author

radix commented Apr 19, 2018

{}radix@pop-os:~$ which poetry
/home/radix/.local/bin/poetry

@sdispater
Copy link
Member

Ok, this is uncommon to me.

How did you install poetry? Since it is not under the prefix that your python knows about which leads to poetry not being able to find where it resides.

@radix
Copy link
Contributor Author

radix commented Apr 19, 2018

I used pip install --user, which puts executables into ~/.local/bin.

@radix
Copy link
Contributor Author

radix commented Apr 27, 2018

just to add a little more context to this: ~/.local is used as the python root for pip install --user on linux. On OSX I believe it's a version-specific directory in ~/Library/Python/2.7 or something.

@sdispater
Copy link
Member

Commit 5ac9794 on the develop branch will likely fix the issue. It will be available in the next 0.9.0 release.

@sdispater
Copy link
Member

Release 0.9.0 is out!

dimbleby pushed a commit to dimbleby/poetry that referenced this issue Apr 21, 2022
Copy link

github-actions bot commented Mar 3, 2024

This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Mar 3, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants