Bug 617782 - PackageKit fails to build against python 2.7, giscanner/xmlwriter.py issue
PackageKit fails to build against python 2.7, giscanner/xmlwriter.py issue
Status: CLOSED WONTFIX
Product: Fedora
Classification: Fedora
Component: gobject-introspection (Show other bugs)
14
All Linux
low Severity medium
: ---
: ---
Assigned To: Colin Walters
Fedora Extras Quality Assurance
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2010-07-23 19:30 EDT by Dave Malcolm
Modified: 2012-08-16 18:36 EDT (History)
5 users (show)

See Also:
Fixed In Version: gobject-introspection-0.9.2-5.fc14
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2012-08-16 18:36:43 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Dave Malcolm 2010-07-23 19:30:23 EDT
Description of problem:
http://koji.fedoraproject.org/koji/getfile?taskID=2347398&name=build.log
contains:
  GISCAN PackageKitGlib-1.0.gir
Traceback (most recent call last):
  File "/usr/bin/g-ir-scanner", line 36, in <module>
    from giscanner.scannermain import scanner_main
  File "/usr/lib64/gobject-introspection/giscanner/scannermain.py", line 31, in <module>
    from giscanner.dumper import compile_introspection_binary
  File "/usr/lib64/gobject-introspection/giscanner/dumper.py", line 26, in <module>
    from .glibtransformer import IntrospectionBinary
  File "/usr/lib64/gobject-introspection/giscanner/glibtransformer.py", line 34, in <module>
    from .transformer import Names
  File "/usr/lib64/gobject-introspection/giscanner/transformer.py", line 31, in <module>
    from .girparser import GIRParser
  File "/usr/lib64/gobject-introspection/giscanner/girparser.py", line 32, in <module>
    from .girwriter import COMPATIBLE_GIR_VERSION
  File "/usr/lib64/gobject-introspection/giscanner/girwriter.py", line 30, in <module>
    from .xmlwriter import XMLWriter
  File "/usr/lib64/gobject-introspection/giscanner/xmlwriter.py", line 70, in <module>
    with LibtoolImporter:
AttributeError: __exit__
make[4]: *** [PackageKitGlib-1.0.gir] Error 1
make[4]: Leaving directory `/builddir/build/BUILD/PackageKit-0.6.6/lib/packagekit-glib2'
make[3]: Leaving directory `/builddir/build/BUILD/PackageKit-0.6.6/lib/packagekit-glib2'
make[3]: *** [all] Error 2
make[2]: *** [all-recursive] Error 1
make[2]: Leaving directory `/builddir/build/BUILD/PackageKit-0.6.6/lib'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/builddir/build/BUILD/PackageKit-0.6.6'

Looks like this isn't compatible with python 2.7

http://docs.python.org/dev/whatsnew/2.7.html#porting-to-python-2-7 has this which seems the likely explanation:
"Because of an optimization for the with statement, the special methods __enter__() and __exit__() must belong to the object’s type, and cannot be directly attached to the object’s instance. This affects new-style classes (derived from object) and C extension types. (issue 6101.)"

Steps to Reproduce:
koji build dist-f14-py27-rebuild cvs://cvs.fedoraproject.org/cvs/pkgs?rpms/PackageKit/devel#PackageKit-0_6_6-3_fc14
Comment 1 Dave Malcolm 2010-07-23 19:31:55 EDT
Presumably affects any other packages that build .gir files; reassigning to "gobject-introspection"
Comment 2 Dave Malcolm 2010-07-25 20:39:39 EDT
There seems to be some discussion of this in the Python bug tracker:
http://bugs.python.org/issue9259
Comment 4 Dave Malcolm 2010-07-26 06:44:12 EDT
I've tested with that patch and was successfully able to rebulid gtk-vnc on python 2.7 with in.

Committed to CVS; building gobject-introspection-0.9.2-5.fc14 into dist-f14-py27-rebuild as:
http://koji.fedoraproject.org/koji/taskinfo?taskID=2351043
Comment 5 Bug Zapper 2010-07-30 08:48:29 EDT
This bug appears to have been reported against 'rawhide' during the Fedora 14 development cycle.
Changing version to '14'.

More information and reason for this action is here:
http://fedoraproject.org/wiki/BugZappers/HouseKeeping
Comment 6 Fedora End Of Life 2012-08-16 18:36:45 EDT
This message is a notice that Fedora 14 is now at end of life. Fedora 
has stopped maintaining and issuing updates for Fedora 14. It is 
Fedora's policy to close all bug reports from releases that are no 
longer maintained.  At this time, all open bugs with a Fedora 'version'
of '14' have been closed as WONTFIX.

(Please note: Our normal process is to give advanced warning of this 
occurring, but we forgot to do that. A thousand apologies.)

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, feel free to reopen 
this bug and simply change the 'version' to a later Fedora version.

Bug Reporter: Thank you for reporting this issue and we are sorry that 
we were unable to fix it before Fedora 14 reached 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, you are encouraged to click on 
"Clone This Bug" (top right of this page) and open it against that 
version of Fedora.

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

Note You need to log in before you can comment on or make changes to this bug.