Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 502980 - sys-apps/portage-2.2.7 - repoman --mode help: TypeError: print_help() got an unexpected keyword argument 'short'
Summary: sys-apps/portage-2.2.7 - repoman --mode help: TypeError: print_help() got an ...
Status: RESOLVED WONTFIX
Alias: None
Product: Portage Development
Classification: Unclassified
Component: Core - Interface (emerge) (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Portage team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-02-27 18:31 UTC by Ivan Labáth
Modified: 2022-07-12 03:18 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Ivan Labáth 2014-02-27 18:31:50 UTC
I was trying out repoman, checking whether the default help text is the full one and tried specifying "help" as a "--mode" parameter. Repoman errors out on it.

system $ repoman --mode help
Traceback (most recent call last):
  File "/usr/bin/repoman", line 502, in <module>
    options, arguments = ParseArgs(sys.argv, qahelp)
  File "/usr/bin/repoman", line 243, in ParseArgs
    parser.print_help(short=False)
TypeError: print_help() got an unexpected keyword argument 'short'


Reproducible: Always

Steps to Reproduce:
1. repoman --mode help
Comment 1 Brian Dolbec (RETIRED) gentoo-dev 2014-02-28 18:17:18 UTC
What python version is this occurring with?

Can you reproduce this error with other python versions you have installed, if any?
Comment 2 Ivan Labáth 2014-02-28 22:11:48 UTC
(In reply to Brian Dolbec from comment #1)
> What python version is this occurring with?
> 
> Can you reproduce this error with other python versions you have installed,
> if any?

It is set up to use python-3.3. I have tested it with python-2.7 and python-3.3.

$ python3.3 /usr/bin/repoman --mode help
Traceback (most recent call last):
  File "/usr/bin/repoman", line 502, in <module>
    options, arguments = ParseArgs(sys.argv, qahelp)
  File "/usr/bin/repoman", line 243, in ParseArgs
    parser.print_help(short=False)
TypeError: print_help() got an unexpected keyword argument 'short'

$ python2.7 /usr/bin/repoman --mode help
Traceback (most recent call last):
  File "/usr/bin/repoman", line 502, in <module>
    options, arguments = ParseArgs(sys.argv, qahelp)
  File "/usr/bin/repoman", line 243, in ParseArgs
    parser.print_help(short=False)
TypeError: print_help() got an unexpected keyword argument 'short'

According to documentation [1][2][3], there is no verbosity/shortness argument
to the ArgumentParser.print_help function. I don't have older versions of python installed to check optparse.

[1] http://docs.python.org/dev/library/argparse.html#argparse.ArgumentParser.print_help

[2] $ python3.3 <<< "import argparse; help(argparse.ArgumentParser.print_help)"
Help on function print_help in module argparse:

print_help(self, file=None)

[3] $ python2.7 <<< "import argparse; help(argparse.ArgumentParser.print_help)"
Help on method print_help in module argparse:

print_help(self, file=None) unbound argparse.ArgumentParser method



Version of portage used:

$ eix portage
[I] sys-apps/portage
     Available versions:  [M]2.1.6.7_p1 2.1.11.62 2.1.12.2 2.2.1 ~2.2.6 2.2.7 ~2.2.8 ~2.2.8-r1 **9999 {build doc epydoc +ipc less pypy2_0 python2 python3 selinux xattr LINGUAS="pl ru" PYTHON_TARGETS="pypy2_0 python2_6 python2_7 python3_2 python3_3 python3_4"}
     Installed versions:  2.2.7(15:54:34 01/07/14)(ipc python3 xattr -build -doc -epydoc -pypy2_0 -python2 -selinux LINGUAS="-ru" PYTHON_TARGETS="python2_7 python3_3 -pypy2_0 -python2_6 -python3_2 -python3_4")
     Homepage:            http://www.gentoo.org/proj/en/portage/index.xml
     Description:         Portage is the package management and distribution system for Gentoo
Comment 3 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2022-07-12 03:18:28 UTC
repoman support has been removed per bug 835013.

Please file a new bug (or, I suppose, reopen this one) if you feel this check is still applicable to pkgcheck and doesn't already exist.