<type 'exceptions.NameError'>: global name 'logging' is not defined

Bug #752220 reported by baytuni
844
This bug affects 101 people
Affects Status Importance Assigned to Milestone
aptdaemon (Ubuntu)
Fix Released
High
Barry Warsaw
Natty
Fix Released
High
Barry Warsaw

Bug Description

Binary package hint: aptdaemon

Crash

ProblemType: Crash
DistroRelease: Ubuntu 11.04
Package: aptdaemon 0.41+bzr614-0ubuntu1
ProcVersionSignature: Ubuntu 2.6.38-8.41-generic 2.6.38.2
Uname: Linux 2.6.38-8-generic x86_64
Annotation: Installation of software failed
Architecture: amd64
Date: Wed Apr 6 07:19:07 2011
DesktopFile: /usr/share/aptdaemon/aptdaemon.desktop
ExecutablePath: /usr/sbin/aptd
InstallationMedia: Ubuntu 10.10 "Maverick Meerkat" - Release amd64 (20101007)
PackageArchitecture: all
SourcePackage: aptdaemon
Title: <type 'exceptions.NameError'>: global name 'logging' is not defined
TransactionDepends: [[], [], [], [], [], [], []]
TransactionErrorCode: error-unknown
TransactionKwargs: {}
TransactionLocale: en_US.UTF8
TransactionOutput:

TransactionPackages: [[dbus.String(u'desktopcouch-ubuntuone')], [], [], [], [], []]
TransactionRole: role-install-packages
UpgradeStatus: Upgraded to natty on 2011-04-05 (0 days ago)

Related branches

Revision history for this message
baytuni (oytun-peksel) wrote :
Robert Roth (evfool)
Changed in aptdaemon (Ubuntu):
status: New → Confirmed
Changed in aptdaemon (Ubuntu):
status: Confirmed → Triaged
importance: Undecided → High
Revision history for this message
Jean-Baptiste Lallement (jibel) wrote :

this was introduced in lock.py r62

Changed in aptdaemon (Ubuntu Natty):
assignee: nobody → Canonical Foundations Team (canonical-foundations)
Revision history for this message
Barry Warsaw (barry) wrote :

Note that lock.py has other problems, as reported by pyflakes. E.g. line 151 and 152 have references to 'lock' which should probably be alt_lock, though I'm not positive about that. And line 176 has a reference to TransactionCancelled() which is also undefined. The logging one is shallow though so I'll try to fix that now and file bugs for the other problems.

Changed in aptdaemon (Ubuntu Natty):
assignee: Canonical Foundations Team (canonical-foundations) → Barry Warsaw (barry)
Revision history for this message
AhronZombi (ahron) wrote : Re: [Bug 752220] Re: <type 'exceptions.NameError'>: global name 'logging' is not defined

Unsubscribe
On Apr 8, 2011 6:20 PM, "Barry Warsaw" <email address hidden> wrote:
> Note that lock.py has other problems, as reported by pyflakes. E.g.
> line 151 and 152 have references to 'lock' which should probably be
> alt_lock, though I'm not positive about that. And line 176 has a
> reference to TransactionCancelled() which is also undefined. The
> logging one is shallow though so I'll try to fix that now and file bugs
> for the other problems.
>
> ** Changed in: aptdaemon (Ubuntu Natty)
> Assignee: Canonical Foundations Team (canonical-foundations) => Barry
Warsaw (barry)
>
> --
> You received this bug notification because you are a direct subscriber
> of a duplicate bug (753030).
> https://bugs.launchpad.net/bugs/752220
>
> Title:
> <type 'exceptions.NameError'>: global name 'logging' is not defined
>
> To unsubscribe from this bug, go to:
> https://bugs.launchpad.net/ubuntu/+source/aptdaemon/+bug/752220/+subscribe

Revision history for this message
Andy Barilla (andybarilla) wrote :

A patch to the python-aptdaemon package is attached.

Changed in aptdaemon (Ubuntu Natty):
status: Triaged → Fix Committed
tags: added: patch
Revision history for this message
Michael Vogt (mvo) wrote :

Uploaded now, waiting in the queue.

Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package aptdaemon - 0.41+bzr614-0ubuntu3

---------------
aptdaemon (0.41+bzr614-0ubuntu3) natty; urgency=low

  * debian/patches/04_import_logging.patch:
    - Import logging to resolve undefined name. (LP: #752220)
 -- Barry Warsaw <email address hidden> Fri, 08 Apr 2011 18:36:22 -0400

Changed in aptdaemon (Ubuntu Natty):
status: Fix Committed → Fix Released
tags: added: iso-testing
Revision history for this message
grovalmitch (grovalmitch) wrote :

You do not have variable defined within the function or at the global level. More on...python global variable...

http://net-informations.com/python/iq/global.htm

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.