Bug ID 980393
Summary command-not-found (cnf) doesn't find packages anymore
Classification openSUSE
Product openSUSE Tumbleweed
Version Current
Hardware Other
OS Other
Status NEW
Severity Normal
Priority P5 - None
Component Other
Assignee bnc-team-screening@forge.provo.novell.com
Reporter antoine.belvire@laposte.net
QA Contact qa-bugs@suse.de
Found By ---
Blocker ---

cnf (command-not-found) seems broken, it doesn't find the packages which
provide the given command.

It looks like bug #951977.

I'm running openSUSE Tumbleweed (20160512) but I can't say which snapshot
introduced the problem.

It seems that there is something wrong when calling libsolv's Dataiterator in
scout's bin.py:

>    def search(self, term, inversesearch = False):
>        pkgmatch = []
>        if not inversesearch:
>            pathreprg = re.compile(self.pathre + re.escape(term) + '$')
>            # SEARCH_STRING without SEARCH_FILES matches basenames
>            for d in self.pool.Dataiterator(solv.SOLVABLE_FILELIST, term, solv.Dataiterator.SEARCH_STRING):
>                path = str(d)
>                # do matching for path
>                if not pathreprg.match(path): continue
>                row = ( 'zypp (%s)' % d.solvable.repo.name.decode('utf-8'), d.solvable.name.decode('utf-8'), path[:-len(term)-1], term )
>                if not row in pkgmatch:
>                    pkgmatch.append( row )
>        else:



Steps to reproduce:
1. Run 'cnf bash'

Expected result:
>
> Program 'bash' is present in package 'bash', which is installed on your system.
> 
> Absolute path to 'bash' is '/bin/bash'. Please check your $PATH variable to see whether it contains the mentioned path.
>

Actual result:
> bash: command not found.


You are receiving this mail because: