Bug 2322963

Summary: completion script not compatible with bash-completion 2.13+
Product: [Fedora] Fedora Reporter: Stephen Finucane <stephenfin>
Component: the_silver_searcherAssignee: Shlomi Fish <shlomif>
Status: CLOSED ERRATA QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: medium Docs Contact:
Priority: unspecified    
Version: 41CC: carl, shlomif
Target Milestone: ---Keywords: Regression
Target Release: ---   
Hardware: Unspecified   
OS: Linux   
Whiteboard:
Fixed In Version: the_silver_searcher-2.2.0^2020704.5a1c8d8-11.fc42 the_silver_searcher-2.2.0^2020704.5a1c8d8-11.fc41 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2024-10-31 18:42:29 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Stephen Finucane 2024-10-31 16:12:30 UTC
As noted on the ag issue tracker [1], the completion script provided with ag is not compatible with the most recent version of bash-completion including that in Fedora 41. This results in the following error output when attempting to tab complete:

  ❯ ag readbash: _split_longopt: command not found                                                                                                                                                                                                                                                                                                                                                                                            
  README.rst

I suspect the solution here is to either (a) temporarily include the proposed bug fix [2] pending its merge or (b) take the fact that no patches have merged to ag in over 4 years as a sign that it's time to kick-off the deprecation and removal of the package from Fedora :(

Personally, I have patched the completion script at `/usr/share/bash-completion/completions/ag` and will resolve the conflict if/when dnf prompts me to.

[1] https://github.com/ggreer/the_silver_searcher/issues/1537
[2] https://github.com/ggreer/the_silver_searcher/pull/1540

Reproducible: Always

Steps to Reproduce:
1. Install `ag`
2. Attempt to tab-complete a filename

Actual Results:  
ag readbash: _split_longopt: command not found                                                                                                                                                                                                                                                                                                                                                                                            
README.rst

Expected Results:  
ag README.rst

Comment 1 Fedora Update System 2024-10-31 18:38:39 UTC
FEDORA-2024-b0c8618410 (the_silver_searcher-2.2.0^2020704.5a1c8d8-11.fc42) has been submitted as an update to Fedora 42.
https://bodhi.fedoraproject.org/updates/FEDORA-2024-b0c8618410

Comment 2 Fedora Update System 2024-10-31 18:42:29 UTC
FEDORA-2024-b0c8618410 (the_silver_searcher-2.2.0^2020704.5a1c8d8-11.fc42) has been pushed to the Fedora 42 stable repository.
If problem still persists, please make note of it in this bug report.

Comment 3 Fedora Update System 2024-10-31 19:30:57 UTC
FEDORA-2024-aa887d0633 (the_silver_searcher-2.2.0^2020704.5a1c8d8-11.fc41) has been submitted as an update to Fedora 41.
https://bodhi.fedoraproject.org/updates/FEDORA-2024-aa887d0633

Comment 4 Fedora Update System 2024-11-01 01:36:25 UTC
FEDORA-2024-aa887d0633 has been pushed to the Fedora 41 testing repository.
Soon you'll be able to install the update with the following command:
`sudo dnf upgrade --enablerepo=updates-testing --refresh --advisory=FEDORA-2024-aa887d0633`
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2024-aa887d0633

See also https://fedoraproject.org/wiki/QA:Updates_Testing for more information on how to test updates.

Comment 5 Fedora Update System 2024-11-09 01:45:30 UTC
FEDORA-2024-aa887d0633 (the_silver_searcher-2.2.0^2020704.5a1c8d8-11.fc41) has been pushed to the Fedora 41 stable repository.
If problem still persists, please make note of it in this bug report.