Bug 526402
Summary: | "pydoc -k" searches fail when run as non-root when parted module is installed | ||||||
---|---|---|---|---|---|---|---|
Product: | [Fedora] Fedora | Reporter: | Matěj Cepl <mcepl> | ||||
Component: | pyparted | Assignee: | David Cantrell <dcantrell> | ||||
Status: | CLOSED RAWHIDE | QA Contact: | Fedora Extras Quality Assurance <extras-qa> | ||||
Severity: | medium | Docs Contact: | |||||
Priority: | low | ||||||
Version: | 12 | CC: | dcantrell, hdegoede, ivazqueznet, james.antill, jonathansteffan, mcepl | ||||
Target Milestone: | --- | Keywords: | Reopened | ||||
Target Release: | --- | ||||||
Hardware: | x86_64 | ||||||
OS: | Linux | ||||||
Whiteboard: | abrt_hash:6d4b909e | ||||||
Fixed In Version: | pyparted-2.3-1 | Doc Type: | Bug Fix | ||||
Doc Text: | Story Points: | --- | |||||
Clone Of: | |||||||
: | 649707 (view as bug list) | Environment: | |||||
Last Closed: | 2010-11-04 15:15:37 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: | |||||||
Bug Depends On: | |||||||
Bug Blocks: | 649707 | ||||||
Attachments: |
|
Description
Matěj Cepl
2009-09-30 05:44:03 UTC
Created attachment 363123 [details]
File: backtrace
"pydoc -k" is searching through all modules on your system. It's failing on "/home/matej/.python-lib/mechanize/_useragent.py", which looks like a locally-installed version of the mechanize package. What version of mechanize is that? Yes, that's it. Sorry for the noise. Well, that was hasty: bradford:~$ pydoc -k hmac hmac - HMAC (Keyed-Hashing for Message Authentication) Python module. Crypto.Hash.HMAC - HMAC (Keyed-Hashing for Message Authentication) Python module. (process:6115): Gdk-CRITICAL **: gdk_keymap_get_for_display: assertion `GDK_IS_DISPLAY (display)' failed (process:6115): Gdk-CRITICAL **: gdk_screen_get_root_window: assertion `GDK_IS_SCREEN (screen)' failed ** (process:6115): CRITICAL **: egg_keymap_resolve_virtual_modifiers: assertion `GDK_IS_KEYMAP (keymap)' failed ** (process:6115): CRITICAL **: egg_keymap_resolve_virtual_modifiers: assertion `GDK_IS_KEYMAP (keymap)' failed ** (process:6115): CRITICAL **: egg_keymap_resolve_virtual_modifiers: assertion `GDK_IS_KEYMAP (keymap)' failed Traceback (most recent call last): File "/usr/bin/pydoc", line 5, in <module> pydoc.cli() File "/usr/lib64/python2.6/pydoc.py", line 2264, in cli apropos(val) File "/usr/lib64/python2.6/pydoc.py", line 1962, in apropos ModuleScanner().run(callback, key) File "/usr/lib64/python2.6/pydoc.py", line 1927, in run for importer, modname, ispkg in pkgutil.walk_packages(onerror=onerror): File "/usr/lib64/python2.6/pkgutil.py", line 110, in walk_packages __import__(name) File "/usr/lib64/python2.6/site-packages/parted/__init__.py", line 28, in <module> from _ped import AlignmentException RuntimeError: pyparted requires root access bradford:~$ Even when I have no local python library, pydoc fails .... Why in the world it needs parted??? Well, it's iterating through all installed packages, importing them. One of the installed packages is "parted", and parted appears to have a hard requirement on being _imported_ as root. Looks to me like the parted code should be importable as non-root, but only runnable by root. Alternatively, perhaps "pydoc -k" could be made to handle this kind of case. Renaming and reasssiging to "parted". If it's not feasible to fix there, reassign back to python and I can look at a better onerror handler. This is not an issue with parted, but with pyparted. Re-assigning. David, this is an issue for running pylint on anaconda to (it needs to be done as root because of the root check in pyparted). Since parted itself can be used as normal user too (on disk images for example), can you please remove the unneeded root check from pyparted ? (In reply to comment #6) > This is not an issue with parted, but with pyparted. > > Re-assigning. > > David, this is an issue for running pylint on anaconda to (it needs to be done > as root because of the root check in pyparted). Since parted itself can be used > as normal user too (on disk images for example), can you please remove the > unneeded root check from pyparted ? Sure, done and done. Fixed in pyparted-2.3-1 in rawhide. This bug appears to have been reported against 'rawhide' during the Fedora 12 development cycle. Changing version to '12'. More information and reason for this action is here: http://fedoraproject.org/wiki/BugZappers/HouseKeeping This message is a reminder that Fedora 12 is nearing its end of life. Approximately 30 (thirty) days from now Fedora will stop maintaining and issuing updates for Fedora 12. It is Fedora's policy to close all bug reports from releases that are no longer maintained. At that time this bug will be closed as WONTFIX if it remains open with a Fedora 'version' of '12'. Package Maintainer: If you wish for this bug to remain open because you plan to fix it in a currently maintained version, simply change the 'version' to a later Fedora version prior to Fedora 12's end of life. Bug Reporter: Thank you for reporting this issue and we are sorry that we may not be able to fix it before Fedora 12 is end of life. If you would still like to see this bug fixed and are able to reproduce it against a later version of Fedora please change the 'version' of this bug to the applicable version. If you are unable to change the version, please add a comment here and someone will do it for you. Although we aim to fix as many bugs as possible during every release's lifetime, sometimes those efforts are overtaken by events. Often a more recent Fedora release includes newer upstream software that fixes bugs or makes them obsolete. The process we are following is described here: http://fedoraproject.org/wiki/BugZappers/HouseKeeping |