question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Fish completions raise errors but still works

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).
  • macOS 10.15.7:
  • 1.2.0b2:
  • fish 3.5:

Issue

I installed the completions as explained in the doc, and completions are working. But there is an error when triggering autocomplete with <kbd>TAB</kbd> key :

~/.config/fish/completions/poetry.fish (line 57):
complete -c poetry -f -n '__fish_poetry_e3d63c4129b80bf7_complete_no_subcommand' -a source show -d 'Show information about sources configured for the project.'
^
from sourcing file ~/.config/fish/completions/poetry.fish

I put the last error only, but the console print this error for almost every line of this file.

Screencast if needed

https://user-images.githubusercontent.com/68596777/176383266-927a6d92-c8e9-4674-af02-4cda3fb64486.mp4

Issue Analytics

  • State:closed
  • Created a year ago
  • Reactions:1
  • Comments:13 (6 by maintainers)

github_iconTop GitHub Comments

11reactions
nbyscommented, Dec 11, 2022

I still get an error using autocomplete in fish.

Poetry (version 1.3.0) fish, version 3.5.1

log
poetry addcomplete: too many arguments

~/.config/fish/completions/poetry.fish (line 83):
complete -c poetry -A -n '__fish_seen_subcommand_from 'cache clear'' -l all -d 'Clear all entries in the cache.'
^
from sourcing file ~/.config/fish/completions/poetry.fish

(Type 'help complete' for related documentation)
complete: too many arguments

~/.config/fish/completions/poetry.fish (line 97):
complete -c poetry -A -n '__fish_seen_subcommand_from 'debug resolve'' -l extras -d 'Extras to activate for the dependency.'
^
from sourcing file ~/.config/fish/completions/poetry.fish

(Type 'help complete' for related documentation)
complete: too many arguments

~/.config/fish/completions/poetry.fish (line 98):
complete -c poetry -A -n '__fish_seen_subcommand_from 'debug resolve'' -l install -d 'Show what would be installed for the current system.'
^
from sourcing file ~/.config/fish/completions/poetry.fish

(Type 'help complete' for related documentation)
complete: too many arguments

~/.config/fish/completions/poetry.fish (line 99):
complete -c poetry -A -n '__fish_seen_subcommand_from 'debug resolve'' -l python -d 'Python version(s) to use for resolution.'
^
from sourcing file ~/.config/fish/completions/poetry.fish

(Type 'help complete' for related documentation)
complete: too many arguments

~/.config/fish/completions/poetry.fish (line 100):
complete -c poetry -A -n '__fish_seen_subcommand_from 'debug resolve'' -l tree -d 'Display the dependency tree.'
^
from sourcing file ~/.config/fish/completions/poetry.fish

(Type 'help complete' for related documentation)
complete: too many arguments

~/.config/fish/completions/poetry.fish (line 103):
complete -c poetry -A -n '__fish_seen_subcommand_from 'env info'' -l path -d 'Only display the environment\'s path.'
^
from sourcing file ~/.config/fish/completions/poetry.fish

(Type 'help complete' for related documentation)
complete: too many arguments

~/.config/fish/completions/poetry.fish (line 106):
complete -c poetry -A -n '__fish_seen_subcommand_from 'env list'' -l full-path -d 'Output the full paths of the virtualenvs.'
^
from sourcing file ~/.config/fish/completions/poetry.fish

(Type 'help complete' for related documentation)
complete: too many arguments

~/.config/fish/completions/poetry.fish (line 109):
complete -c poetry -A -n '__fish_seen_subcommand_from 'env remove'' -l all -d 'Remove all managed virtual environments associated with the project.'
^
from sourcing file ~/.config/fish/completions/poetry.fish

(Type 'help complete' for related documentation)
complete: too many arguments

~/.config/fish/completions/poetry.fish (line 180):
complete -c poetry -A -n '__fish_seen_subcommand_from 'self add'' -l allow-prereleases -d 'Accept prereleases.'
^
from sourcing file ~/.config/fish/completions/poetry.fish

(Type 'help complete' for related documentation)
complete: too many arguments

~/.config/fish/completions/poetry.fish (line 181):
complete -c poetry -A -n '__fish_seen_subcommand_from 'self add'' -l dry-run -d 'Output the operations but do not execute anything (implicitly enables --verbose).'
^
from sourcing file ~/.config/fish/completions/poetry.fish

(Type 'help complete' for related documentation)
complete: too many arguments

~/.config/fish/completions/poetry.fish (line 182):
complete -c poetry -A -n '__fish_seen_subcommand_from 'self add'' -l editable -d 'Add vcs/path dependencies as editable.'
^
from sourcing file ~/.config/fish/completions/poetry.fish

(Type 'help complete' for related documentation)
complete: too many arguments

~/.config/fish/completions/poetry.fish (line 183):
complete -c poetry -A -n '__fish_seen_subcommand_from 'self add'' -l extras -d 'Extras to activate for the dependency.'
^
from sourcing file ~/.config/fish/completions/poetry.fish

(Type 'help complete' for related documentation)
complete: too many arguments

~/.config/fish/completions/poetry.fish (line 184):
complete -c poetry -A -n '__fish_seen_subcommand_from 'self add'' -l source -d 'Name of the source to use to install the package.'
^
from sourcing file ~/.config/fish/completions/poetry.fish

(Type 'help complete' for related documentation)
complete: too many arguments

~/.config/fish/completions/poetry.fish (line 187):
complete -c poetry -A -n '__fish_seen_subcommand_from 'self install'' -l dry-run -d 'Output the operations but do not execute anything (implicitly enables --verbose).'
^
from sourcing file ~/.config/fish/completions/poetry.fish

(Type 'help complete' for related documentation)
complete: too many arguments

~/.config/fish/completions/poetry.fish (line 188):
complete -c poetry -A -n '__fish_seen_subcommand_from 'self install'' -l sync -d 'Synchronize the environment with the locked packages and the specified groups.'
^
from sourcing file ~/.config/fish/completions/poetry.fish

(Type 'help complete' for related documentation)
complete: too many arguments

~/.config/fish/completions/poetry.fish (line 191):
complete -c poetry -A -n '__fish_seen_subcommand_from 'self lock'' -l check -d 'Check that the poetry.lock file corresponds to the current version of pyproject.toml.'
^
from sourcing file ~/.config/fish/completions/poetry.fish

(Type 'help complete' for related documentation)
complete: too many arguments

~/.config/fish/completions/poetry.fish (line 192):
complete -c poetry -A -n '__fish_seen_subcommand_from 'self lock'' -l no-update -d 'Do not update locked versions, only refresh lock file.'
^
from sourcing file ~/.config/fish/completions/poetry.fish

(Type 'help complete' for related documentation)
complete: too many arguments

~/.config/fish/completions/poetry.fish (line 195):
complete -c poetry -A -n '__fish_seen_subcommand_from 'self remove'' -l dry-run -d 'Output the operations but do not execute anything (implicitly enables --verbose).'
^
from sourcing file ~/.config/fish/completions/poetry.fish

(Type 'help complete' for related documentation)
complete: too many arguments

~/.config/fish/completions/poetry.fish (line 198):
complete -c poetry -A -n '__fish_seen_subcommand_from 'self show'' -l addons -d 'List only add-on packages installed.'
^
from sourcing file ~/.config/fish/completions/poetry.fish

(Type 'help complete' for related documentation)
complete: too many arguments

~/.config/fish/completions/poetry.fish (line 199):
complete -c poetry -A -n '__fish_seen_subcommand_from 'self show'' -l latest -d 'Show the latest version.'
^
from sourcing file ~/.config/fish/completions/poetry.fish

(Type 'help complete' for related documentation)
complete: too many arguments

~/.config/fish/completions/poetry.fish (line 200):
complete -c poetry -A -n '__fish_seen_subcommand_from 'self show'' -l outdated -d 'Show the latest version but only for packages that are outdated.'
^
from sourcing file ~/.config/fish/completions/poetry.fish

(Type 'help complete' for related documentation)
complete: too many arguments

~/.config/fish/completions/poetry.fish (line 201):
complete -c poetry -A -n '__fish_seen_subcommand_from 'self show'' -l tree -d 'List the dependencies as a tree.'
^
from sourcing file ~/.config/fish/completions/poetry.fish

(Type 'help complete' for related documentation)
complete: too many arguments

~/.config/fish/completions/poetry.fish (line 206):
complete -c poetry -A -n '__fish_seen_subcommand_from 'self update'' -l dry-run -d 'Output the operations but do not execute anything (implicitly enables --verbose).'
^
from sourcing file ~/.config/fish/completions/poetry.fish

(Type 'help complete' for related documentation)
complete: too many arguments

~/.config/fish/completions/poetry.fish (line 207):
complete -c poetry -A -n '__fish_seen_subcommand_from 'self update'' -l preview -d 'Allow the installation of pre-release versions.'
^
from sourcing file ~/.config/fish/completions/poetry.fish

(Type 'help complete' for related documentation)
complete: too many arguments

~/.config/fish/completions/poetry.fish (line 223):
complete -c poetry -A -n '__fish_seen_subcommand_from 'source add'' -l default -d 'Set this source as the default (disable PyPI). A default source will also be the fallback source if you add other sources.'
^
from sourcing file ~/.config/fish/completions/poetry.fish

(Type 'help complete' for related documentation)
complete: too many arguments

~/.config/fish/completions/poetry.fish (line 224):
complete -c poetry -A -n '__fish_seen_subcommand_from 'source add'' -l secondary -d 'Set this source as secondary.'
^
from sourcing file ~/.config/fish/completions/poetry.fish

(Type 'help complete' for related documentation)
7reactions
Secruscommented, Nov 22, 2022

Completion bugs are now fixed with the incoming release.

Read more comments on GitHub >

github_iconTop Results From Across the Web

git config completions messed up for fish shell on ubuntu 20.04
1. Tab completion shows errors whenever I use it with the git config command. The completion still works but it looks very ugly....
Read more >
Documentation - fish shell
These are the general purpose tab completions that fish provides: Completion of commands (builtins, functions and regular programs). Completion of shell ...
Read more >
Adding pass completion to fish shell - Unix StackExchange
It's possible that fish is looking somewhere else. Try echo $fish_complete_path and verify that it includes ~/.config/fish/completions/ .
Read more >
Fix zypper completion in fish (shell) - openSUSE Forums
So I've been playing around with some alternatives shells and I have just about settled on fish. My only issues are with completion...
Read more >
Fish shell doesn't return program error - Super User
Are these errors printed or redirected correctly or captured in any way? By default, are they set to be printed to your default...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found