Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 589686

Summary: app-portage/gentoolkit-0.3.2: TypeError on 'equery changes'
Product: Portage Development Reporter: Thomas Schneider <qsx>
Component: ToolsAssignee: Portage Tools Team <tools-portage>
Status: RESOLVED FIXED    
Severity: major CC: esigra
Priority: Normal Keywords: InVCS
Version: unspecified   
Hardware: All   
OS: Linux   
Whiteboard:
Package list:
Runtime testing required: ---
Bug Depends on:    
Bug Blocks: 346443    
Attachments: emerge --info

Description Thomas Schneider 2016-07-25 16:34:56 UTC
'equery c any-existing/package' fails with TypeError: 'encoding' is an invalid keyword argument for this function

Reproducible: Always

Steps to Reproduce:
'equery c any-existing/package'
Actual Results:  
% equery c app-editors/emacs
Traceback (most recent call last):
  File "/usr/lib/python-exec/python2.7/equery", line 38, in <module>
    equery.main(sys.argv)
  File "/usr/lib64/python2.7/site-packages/gentoolkit/equery/__init__.py", line 357, in main
    loaded_module.main(module_args)
  File "/usr/lib64/python2.7/site-packages/gentoolkit/equery/changes.py", line 155, in main
    changelog = ChangeLog(changelog_path)
  File "/usr/lib64/python2.7/site-packages/gentoolkit/helpers.py", line 77, in __init__
    self.entries = self._split_changelog()
  File "/usr/lib64/python2.7/site-packages/gentoolkit/helpers.py", line 199, in _split_changelog
    encoding=_encodings['content']) as log:
TypeError: 'encoding' is an invalid keyword argument for this function
$? = 1

Expected Results:  
Show the ChangeLog for the requested package or a sensible error.

For a nonexisting package, it silently fails with $? = 1.
Comment 1 Thomas Schneider 2016-07-25 16:36:34 UTC
Created attachment 441528 [details]
emerge --info
Comment 2 Paul Varner (RETIRED) gentoo-dev 2016-07-25 17:25:15 UTC
It works in Python3, so I'll figure out what I missed with compatibility and get it fixed.
Comment 3 Paul Varner (RETIRED) gentoo-dev 2016-07-25 18:07:23 UTC
This has been fixed in git: https://gitweb.gentoo.org/proj/gentoolkit.git/commit/?id=bc92540f8ce498e8305103619c7085b670ba19b1 

You can test with gentoolkit-9999 or you can grab the patch from here: https://gitweb.gentoo.org/proj/gentoolkit.git/patch/?id=bc92540f8ce498e8305103619c7085b670ba19b1
Comment 4 Paul Varner (RETIRED) gentoo-dev 2016-07-26 19:39:06 UTC
This is released in gentoolkit-0.3.2-r1