[Openstack-poc] [Bug 925775] [NEW] utils.import_object sometimes masks the failed import

2012-02-02 Thread Jason Kölker
Public bug reported:

146 def import_class(import_str):
147 Returns a class from a string including module and class
148 mod_str, _sep, class_str = import_str.rpartition('.')
149 try:
150 __import__(mod_str)
151 return getattr(sys.modules[mod_str], class_str)
152 except (ImportError, ValueError, AttributeError):
153 raise exception.NotFound('Class %s cannot be found' % class_str)

From time to time we are seeing the exception raised without the
class_str being filled in making it fun to track down what is not
installed.

** Affects: openstack-common
 Importance: Undecided
 Status: Confirmed

-- 
You received this bug notification because you are a member of OpenStack
Common Drivers, which is the registrant for openstack-common.
https://bugs.launchpad.net/bugs/925775

Title:
  utils.import_object sometimes masks the failed import

Status in openstack-common:
  Confirmed

Bug description:
  146 def import_class(import_str):
  147 Returns a class from a string including module and class
  148 mod_str, _sep, class_str = import_str.rpartition('.')
  149 try:
  150 __import__(mod_str)
  151 return getattr(sys.modules[mod_str], class_str)
  152 except (ImportError, ValueError, AttributeError):
  153 raise exception.NotFound('Class %s cannot be found' % class_str)

  From time to time we are seeing the exception raised without the
  class_str being filled in making it fun to track down what is not
  installed.

To manage notifications about this bug go to:
https://bugs.launchpad.net/openstack-common/+bug/925775/+subscriptions

___
Mailing list: https://launchpad.net/~openstack-poc
Post to : openstack-poc@lists.launchpad.net
Unsubscribe : https://launchpad.net/~openstack-poc
More help   : https://help.launchpad.net/ListHelp


[Openstack-poc] [Bug 925775] Re: utils.import_object sometimes masks the failed import

2012-02-02 Thread Jason Kölker
** Changed in: openstack-common
   Status: New = Confirmed

-- 
You received this bug notification because you are a member of OpenStack
Common Drivers, which is the registrant for openstack-common.
https://bugs.launchpad.net/bugs/925775

Title:
  utils.import_object sometimes masks the failed import

Status in openstack-common:
  Confirmed

Bug description:
  146 def import_class(import_str):
  147 Returns a class from a string including module and class
  148 mod_str, _sep, class_str = import_str.rpartition('.')
  149 try:
  150 __import__(mod_str)
  151 return getattr(sys.modules[mod_str], class_str)
  152 except (ImportError, ValueError, AttributeError):
  153 raise exception.NotFound('Class %s cannot be found' % class_str)

  From time to time we are seeing the exception raised without the
  class_str being filled in making it fun to track down what is not
  installed.

To manage notifications about this bug go to:
https://bugs.launchpad.net/openstack-common/+bug/925775/+subscriptions

___
Mailing list: https://launchpad.net/~openstack-poc
Post to : openstack-poc@lists.launchpad.net
Unsubscribe : https://launchpad.net/~openstack-poc
More help   : https://help.launchpad.net/ListHelp