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

Can't use poetry install after upgrading to 1.2.0 #6488

Closed
3 tasks done
assuiedmilan opened this issue Sep 12, 2022 · 4 comments
Closed
3 tasks done

Can't use poetry install after upgrading to 1.2.0 #6488

assuiedmilan opened this issue Sep 12, 2022 · 4 comments
Labels
area/windows For Windows-specific issues kind/bug Something isn't working as expected status/duplicate Duplicate issues

Comments

@assuiedmilan
Copy link

assuiedmilan commented Sep 12, 2022

  • I am on the latest Poetry version.
  • I have searched the issues of this repo and believe that this is not a duplicate.
  • If an exception occurs when executing a command, I executed it again in debug mode (-vvv option).
  • OS version and name: WIn10
  • Poetry version: 1.2.0
  • Link of a Gist with the contents of your pyproject.toml file: Internal file that cannot be linked

Issue

I am installing a python project using poetry on a docker image.

Until recently it was working pretty well until we started to get the following error:

(1312, 'CredRead', 'A specified logon session does not exist. It may already have been terminated.')

The python code itself did not change much, the base image for the image that I am trying to generate did not change.
When I noticed poetry was upgraded, I downgraded it to version 1.1.15 and it started to work again.

Upgrading from 1.1.15 to 1.2.0 cause the reported error to show up.

What could cause it ?

Here is the full log:

    ******: Updating dependencies
    ******: Resolving dependencies...
    ******:    1: fact: ++++++-python-tools is 1.2.0
    ******:    1: derived: ++++++-python-tools
    ******:    1: fact: ++++++-python-tools depends on pywin32 (^303)
    ******:    1: fact: ++++++-python-tools depends on pyyaml (*)
    ******:    1: fact: ++++++-python-tools depends on command-runner (^1.3.1)
    ******:    1: fact: ++++++-python-tools depends on jstyleson (^0.0.2)
    ******:    1: fact: ++++++-python-tools depends on coloredlogs (^15.0.1)
    ******:
    ******:   Stack trace:
    ******:
    ******:   2  c:\users\******\appdata\local\programs\python\python39\lib\site-packages\win32ctypes\pywin32\pywintypes.py:35 in pywin32error
    ******:        33| def pywin32error():
    ******:        34|     try:
    ******:     >  35|         yield
    ******:        36|     except WindowsError as exception:
    ******:        37|         raise error(exception.winerror, exception.function, exception.strerror)
    ******:
    ******:   1  c:\users\******\appdata\local\programs\python\python39\lib\site-packages\win32ctypes\pywin32\win32cred.py:70 in CredRead
    ******:        68|         else:
    ******:        69|             pcreds = _authentication.PCREDENTIAL()
    ******:     >  70|             _authentication._CredRead(
    ******:        71|                 TargetName, Type, flag, _common.byreference(pcreds))
    ******:        72|     try:
    ******:
    ******:   OSError
    ******:
    ******:   [WinError 1312] A specified logon session does not exist. It may already have been terminated.
    ******:
    ******:   at c:\users\******\appdata\local\programs\python\python39\lib\site-packages\win32ctypes\core\ctypes\_util.py:53 in check_zero
    ******:        49|
    ******:        50| def check_zero_factory(function_name=None):
    ******:        51|     def check_zero(result, function, arguments, *args):
    ******:        52|         if result == 0:
    ******:     >  53|             raise make_error(function, function_name)
    ******:        54|         return result
    ******:        55|     return check_zero
    ******:        56|
    ******:        57|
    ******:
    ******: The following error occurred when trying to handle this error:
    ******:
    ******:
    ******:   Stack trace:
    ******:
    ******:   35  c:\users\******\appdata\local\programs\python\python39\lib\site-packages\cleo\application.py:329 in run
    ******:        327|
    ******:        328|             try:
    ******:      > 329|                 exit_code = self._run(io)
    ******:        330|             except Exception as e:
    ******:        331|                 if not self._catch_exceptions:
    ******:
    ******:   34  c:\users\******\appdata\local\programs\python\python39\lib\site-packages\poetry\console\application.py:185 in _run
    ******:        183|         self._load_plugins(io)
    ******:        184|
    ******:      > 185|         exit_code: int = super()._run(io)
    ******:        186|         return exit_code
    ******:        187|
    ******:
    ******:   33  c:\users\******\appdata\local\programs\python\python39\lib\site-packages\cleo\application.py:423 in _run
    ******:        421|             io.input.set_stream(stream)
    ******:        422|
    ******:      > 423|         exit_code = self._run_command(command, io)
    ******:    1: fact: ++++++-python-tools depends on pylint (3.0.0a4)
    ******:    1: fact: ++++++-python-tools depends on pytest (*)
    ******:    1: fact: ++++++-python-tools depends on pytest-cov (*)
    ******:    1: fact: ++++++-python-tools depends on pytest-lazy-fixture (*)
    ******:    1: fact: ++++++-python-tools depends on pytest-mock (*)
    ******:    1: fact: ++++++-python-tools depends on callee (^0.3.1)
    ******:    1: fact: ++++++-python-tools depends on sphinx (*)
    ******:    1: fact: ++++++-python-tools depends on sphinx_rtd_theme (*)
    ******:    1: selecting ++++++-python-tools (1.2.0)
    ******:    1: derived: sphinx_rtd_theme
    ******:    1: derived: sphinx
    ******:        424|         self._running_command = None
    ******:    1: derived: callee (>=0.3.1,<0.4.0)
    ******:    1: derived: pytest-mock
    ******:        425|
    ******:    1: derived: pytest-lazy-fixture
    ******:    1: derived: pytest-cov
    ******:    1: derived: pytest
    ******:    1: derived: pylint (==3.0.0a4)
    ******:    1: derived: coloredlogs (>=15.0.1,<16.0.0)
    ******:    1: derived: jstyleson (>=0.0.2,<0.0.3)
    ******:    1: derived: command-runner (>=1.3.1,<2.0.0)
    ******:    1: derived: pyyaml
    ******:    1: derived: pywin32 (>=303,<304)
    ******:    1: Version solving took 0.109 seconds.
    ******:    1: Tried 1 solutions.
    ******:
@assuiedmilan assuiedmilan added kind/bug Something isn't working as expected status/triage This issue needs to be triaged labels Sep 12, 2022
@neersighted
Copy link
Member

Looks like a novel (Windows) version of #1917, where attempting to detect a keyring leads to unhandled errors.

@neersighted neersighted closed this as not planned Won't fix, can't repro, duplicate, stale Sep 12, 2022
@neersighted neersighted added status/duplicate Duplicate issues area/windows For Windows-specific issues and removed status/triage This issue needs to be triaged labels Sep 12, 2022
@assuiedmilan
Copy link
Author

I had tons of issues with keyring on ubuntu too ... but managed to solve them by disabling keyring

@joneuhauser
Copy link

This regression also affects running Poetry on Gitlab's shared Windows runners. See e.g. good run with Poetry 1.1.14, bad run with Poetry 1.2.0.

Copy link

github-actions bot commented Mar 1, 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 1, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
area/windows For Windows-specific issues kind/bug Something isn't working as expected status/duplicate Duplicate issues
Projects
None yet
Development

No branches or pull requests

3 participants