Bug 203984 - app-portage/etc-proposals-1.4: Initializing DB fails
Bug#: 203984 Product:  Gentoo Linux Version: unspecified Platform: All
OS/Version: Linux Status: RESOLVED Severity: major Priority: P2
Resolution: FIXED Assigned To: dertobi123@gentoo.org Reported By: r.schedel@yahoo.de
Component: Ebuilds
URL: 
Summary: app-portage/etc-proposals-1.4: Initializing DB fails
Keywords:  
Status Whiteboard: 
Opened: 2008-01-01 18:41 0000
Description:   Opened: 2008-01-01 18:41 0000
The emerge succeeds and prints out that one should call "etc-proposals
--init-db".

However, initializing the DB fails:

# etc-proposals --init-db
init_state_db() takes no arguments (4 given)

Reproducible: Always

Steps to Reproduce:
1. emerge etc-proposals
2. etc-proposals --init-db

Actual Results:  
# etc-proposals --init-db
init_state_db() takes no arguments (4 given)

Expected Results:  
Call should build the initial DB.

In fact in v1.4 of etc-proposals the function init_state_db does not have any
args. Issue can be fixed by appending "(option, opt_str, value, parser)" in
/usr/sbin/etc-proposals, similar to the other callback function in this file.
v1.3 of etc-proposals did not yet use the OptionParser.

Looks like an upstream bug.

However, wondering how this could slip through at all and get into unstable
(maybe older python version used in ebuild test?). Tested python version was:

# python -V
Python 2.4.4

------- Comment #1 From Björn Michaelsen 2008-01-01 21:39:01 0000 -------
This is an upstream bug. Sorry for that. Its fixed in svn, I will release
etc-proposals 1.4.1 tonight, so it can get version bumped to that version ASAP.

Again sorry for the inconvenience. As for this slipping through: There is no
unittest for the starter script, and initializing the DB is done only once on
most installations.

------- Comment #2 From Björn Michaelsen 2008-01-01 22:44:06 0000 -------
Created an attachment (id=139830) [details]
etcproposals-1.4.1.ebuild

I fixed the issue in the 1.4.1 version. The ebuild for it is attached.

------- Comment #3 From Tobias Scherbaum 2008-01-02 16:00:56 0000 -------
1.4.1 in CVS. Thanks for the fast response :)

------- Comment #4 From Markus Ullmann 2008-01-03 00:56:57 0000 -------
*** Bug 204146 has been marked as a duplicate of this bug. ***