'IO' object has no attribute 'ask'
See original GitHub issue- 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: Ubuntu 20.04
- Poetry version: 1.2.0a2
- Link of a Gist with the contents of your pyproject.toml file:
Issue
After adding a repository but no credentials, I cannot publish:
> poetry config repositories.xyz.url "http://python.repo/an/index/"
Fix https://github.com/python-poetry/poetry/issues/3104#issuecomment-972160123, then
> poetry publish -r xyz -vvv
Loading configuration file /home/user/.config/pypoetry/config.toml
Loading configuration file /home/user/.config/pypoetry/auth.toml
Loading configuration file /home/user/project/poetry.toml
Adding repository xyz (http://python.repo/an/index/)
Stack trace:
8 ~/.local/share/pypoetry/venv/lib/python3.8/site-packages/cleo/application.py:330 in run
328β
329β try:
β 330β exit_code = self._run(io)
331β except Exception as e:
332β if not self._catch_exceptions:
7 ~/.local/share/pypoetry/venv/lib/python3.8/site-packages/poetry/console/application.py:180 in _run
178β self._load_plugins(io)
179β
β 180β return super()._run(io)
181β
182β def _configure_io(self, io: IO) -> None:
6 ~/.local/share/pypoetry/venv/lib/python3.8/site-packages/cleo/application.py:425 in _run
423β io.set_input(ArgvInput(argv))
424β
β 425β exit_code = self._run_command(command, io)
426β self._running_command = None
427β
5 ~/.local/share/pypoetry/venv/lib/python3.8/site-packages/cleo/application.py:467 in _run_command
465β
466β if error is not None:
β 467β raise error
468β
469β return event.exit_code
4 ~/.local/share/pypoetry/venv/lib/python3.8/site-packages/cleo/application.py:451 in _run_command
449β
450β if event.command_should_run():
β 451β exit_code = command.run(io)
452β else:
453β exit_code = ConsoleCommandEvent.RETURN_CODE_DISABLED
3 ~/.local/share/pypoetry/venv/lib/python3.8/site-packages/cleo/commands/base_command.py:118 in run
116β io.input.validate()
117β
β 118β status_code = self.execute(io)
119β
120β if status_code is None:
2 ~/.local/share/pypoetry/venv/lib/python3.8/site-packages/cleo/commands/command.py:85 in execute
83β
84β try:
β 85β return self.handle()
86β except KeyboardInterrupt:
87β return 1
1 ~/.local/share/pypoetry/venv/lib/python3.8/site-packages/poetry/console/commands/publish.py:78 in handle
76β )
77β
β 78β publisher.publish(
79β self.option("repository"),
80β self.option("username"),
AttributeError
'IO' object has no attribute 'ask'
at ~/.local/share/pypoetry/venv/lib/python3.8/site-packages/poetry/publishing/publisher.py:82 in publish
78β )
79β # Requesting missing credentials but only if there is not a client cert defined.
80β if not resolved_client_cert:
81β if username is None:
β 82β username = self._io.ask("Username:")
83β
84β # skip password input if no username is provided, assume unauthenticated
85β if username and password is None:
86β password = self._io.ask_hidden("Password:")
Issue Analytics
- State:
- Created 2 years ago
- Reactions:7
- Comments:7 (2 by maintainers)
Top Results From Across the Web
'GPIBInstrument' object has no attribute 'ask'
I am now using python to get data from lock in amplifer with GPIB and met a error report to get data. The...
Read more >IO tools (text, CSV, HDF5, β¦) β pandas 1.5.2 documentation
If a column or index contains an unparsable date, the entire column or index will be returned unaltered as an object data type....
Read more >Frequently Asked Questions
AttributeError: 'module' object has no attribute 'every'. when I try to use schedule. This happens if your code imports the wrong schedule module....
Read more >221 fedpkg without arguments: AttributeError: 'Namespace' ...
#221 fedpkg without arguments: AttributeError: 'Namespace' object has no attribute 'command' (PY3). Closed: Fixed 4 years ago Opened 4 years ago by churchyard....
Read more >AttributeError: 'EntryPoint' object has no attribute '_key', ...
Hi, I am testing computations on the Google Cloud Deployment (Server-options: 16 CPUs), and want to ask for help with interpreting the errorΒ ......
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Same issue to me on Poetry (version 1.2.0a2) (on mac)
Closing, since this should be fixed by 1.2.0b2.