[Yahoo-eng-team] [Bug 1566353] [NEW] glance: use ostestr instead of testr

2016-04-05 Thread Danny Al-Gaaf
Public bug reported:

Glance should use ostestr instead of testr. ostestr is more powerful and
provide much prettier output than testr. Other projects like cinder or
neutron already uses the testr wrapper for openstack projects.

see: http://docs.openstack.org/developer/os-testr/readme.html#

** Affects: glance
 Importance: Undecided
 Assignee: Danny Al-Gaaf (danny-al-gaaf)
 Status: New

** Changed in: glance
 Assignee: (unassigned) => Danny Al-Gaaf (danny-al-gaaf)

** Description changed:

  Glance should use ostestr instead of testr. ostestr is more powerful and
  provide much prettier output than testr. Other projects like cinder or
  neutron already uses the testr wrapper for openstack projects.
+ 
+ see: http://docs.openstack.org/developer/os-testr/readme.html#

-- 
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to Glance.
https://bugs.launchpad.net/bugs/1566353

Title:
  glance: use ostestr instead of testr

Status in Glance:
  New

Bug description:
  Glance should use ostestr instead of testr. ostestr is more powerful
  and provide much prettier output than testr. Other projects like
  cinder or neutron already uses the testr wrapper for openstack
  projects.

  see: http://docs.openstack.org/developer/os-testr/readme.html#

To manage notifications about this bug go to:
https://bugs.launchpad.net/glance/+bug/1566353/+subscriptions

-- 
Mailing list: https://launchpad.net/~yahoo-eng-team
Post to : yahoo-eng-team@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yahoo-eng-team
More help   : https://help.launchpad.net/ListHelp


[Yahoo-eng-team] [Bug 1566354] [NEW] glance_store: use ostestr instead of testr

2016-04-05 Thread Danny Al-Gaaf
Public bug reported:

glance_store should use ostestr instead of testr. ostestr is more
powerful and provide much prettier output than testr. Other projects
like cinder or neutron already uses the testr wrapper for openstack
projects.

see: http://docs.openstack.org/developer/os-testr/readme.html#

** Affects: glance
 Importance: Undecided
 Assignee: Danny Al-Gaaf (danny-al-gaaf)
 Status: New

** Changed in: glance
 Assignee: (unassigned) => Danny Al-Gaaf (danny-al-gaaf)

-- 
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to Glance.
https://bugs.launchpad.net/bugs/1566354

Title:
  glance_store: use ostestr instead of testr

Status in Glance:
  New

Bug description:
  glance_store should use ostestr instead of testr. ostestr is more
  powerful and provide much prettier output than testr. Other projects
  like cinder or neutron already uses the testr wrapper for openstack
  projects.

  see: http://docs.openstack.org/developer/os-testr/readme.html#

To manage notifications about this bug go to:
https://bugs.launchpad.net/glance/+bug/1566354/+subscriptions

-- 
Mailing list: https://launchpad.net/~yahoo-eng-team
Post to : yahoo-eng-team@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yahoo-eng-team
More help   : https://help.launchpad.net/ListHelp


[Yahoo-eng-team] [Bug 1565732] [NEW] glance_store run_tests.sh fails due to missing dependencies

2016-04-04 Thread Danny Al-Gaaf
Public bug reported:

Calling rund_tests.sh from the glance store repository fails with:


Running `tools/with_venv.sh python setup.py testr --testr-args='--subunit 
--concurrency 0  '`
running testr
Non-zero exit code (2) from test listing.
error: testr failed (3)
running=OS_STDOUT_CAPTURE=${OS_STDOUT_CAPTURE:-1} \
OS_STDERR_CAPTURE=${OS_STDERR_CAPTURE:-1} \
OS_TEST_TIMEOUT=${OS_TEST_TIMEOUT:-160} \
${PYTHON:-python} -m subunit.run discover -t ./ ./glance_store/tests --list 
--- import errors ---
Failed to import test module: glance_store.tests.unit.test_cinder_store
Traceback (most recent call last):
  File 
"/develop/OpenStack/glance_store/.venv/lib/python2.7/site-packages/unittest2/loader.py",
 line 456, in _find_test_path
module = self._get_module_from_name(name)
  File 
"/develop/OpenStack/glance_store/.venv/lib/python2.7/site-packages/unittest2/loader.py",
 line 395, in _get_module_from_name
__import__(name)
  File "glance_store/tests/unit/test_cinder_store.py", line 27, in 
from os_brick.initiator import connector
ImportError: No module named os_brick.initiator

Failed to import test module: glance_store.tests.unit.test_s3_store
Traceback (most recent call last):
  File 
"/develop/OpenStack/glance_store/.venv/lib/python2.7/site-packages/unittest2/loader.py",
 line 456, in _find_test_path
module = self._get_module_from_name(name)
  File 
"/develop/OpenStack/glance_store/.venv/lib/python2.7/site-packages/unittest2/loader.py",
 line 395, in _get_module_from_name
__import__(name)
  File "glance_store/tests/unit/test_s3_store.py", line 22, in 
import boto.s3.connection
ImportError: No module named boto.s3.connection

Failed to import test module: glance_store.tests.unit.test_swift_store
Traceback (most recent call last):
  File 
"/develop/OpenStack/glance_store/.venv/lib/python2.7/site-packages/unittest2/loader.py",
 line 456, in _find_test_path
module = self._get_module_from_name(name)
  File 
"/develop/OpenStack/glance_store/.venv/lib/python2.7/site-packages/unittest2/loader.py",
 line 395, in _get_module_from_name
__import__(name)
  File "glance_store/tests/unit/test_swift_store.py", line 35, in 
import swiftclient
ImportError: No module named swiftclient

Failed to import test module: glance_store.tests.unit.test_vmware_store
Traceback (most recent call last):
  File 
"/develop/OpenStack/glance_store/.venv/lib/python2.7/site-packages/unittest2/loader.py",
 line 456, in _find_test_path
module = self._get_module_from_name(name)
  File 
"/develop/OpenStack/glance_store/.venv/lib/python2.7/site-packages/unittest2/loader.py",
 line 395, in _get_module_from_name
__import__(name)
  File "glance_store/tests/unit/test_vmware_store.py", line 23, in 
from oslo_vmware import api
ImportError: No module named oslo_vmware


Ran 0 tests in 1.632s

OK


The root cause is that the created virtualenv is missing some packages
defined in setup.cfg as extras for optional stores but missing those
packages in test-requirements.txt.

** Affects: glance
 Importance: Undecided
 Assignee: Danny Al-Gaaf (danny-al-gaaf)
 Status: New

** Changed in: glance
 Assignee: (unassigned) => Danny Al-Gaaf (danny-al-gaaf)

-- 
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to Glance.
https://bugs.launchpad.net/bugs/1565732

Title:
  glance_store run_tests.sh fails due to missing dependencies

Status in Glance:
  New

Bug description:
  Calling rund_tests.sh from the glance store repository fails with:

  
  Running `tools/with_venv.sh python setup.py testr --testr-args='--subunit 
--concurrency 0  '`
  running testr
  Non-zero exit code (2) from test listing.
  error: testr failed (3)
  running=OS_STDOUT_CAPTURE=${OS_STDOUT_CAPTURE:-1} \
  OS_STDERR_CAPTURE=${OS_STDERR_CAPTURE:-1} \
  OS_TEST_TIMEOUT=${OS_TEST_TIMEOUT:-160} \
  ${PYTHON:-python} -m subunit.run discover -t ./ ./glance_store/tests --list 
  --- import errors ---
  Failed to import test module: glance_store.tests.unit.test_cinder_store
  Traceback (most recent call last):
File 
"/develop/OpenStack/glance_store/.venv/lib/python2.7/site-packages/unittest2/loader.py",
 line 456, in _find_test_path
  module = self._get_module_from_name(name)
File 
"/develop/OpenStack/glance_store/.venv/lib/python2.7/site-packages/unittest2/loader.py",
 line 395, in _get_module_from_name
  __import__(name)
File "glance_store/tests/unit/test_cinder_store.py", line 27, in 
  from os_brick.initiator import connector
  ImportError: No module named os_brick.initiator

  Failed to import test module: glance_store.tests.unit.test_s3_store
  Traceback (most recent call last):
File 
"/develop/OpenStack/glance_store/.venv/lib/python2.7/site-packages/unittest2/loader.p

[Yahoo-eng-team] [Bug 1565722] [NEW] glance_store should support RBD cluster name

2016-04-04 Thread Danny Al-Gaaf
Public bug reported:

As the cinder rbd driver the glance_store should support to pass the ceph 
cluster name to the Rados/RBD driver while initiating a connection. This 
will be useful if you have either non-default cluster names or e.g. multiple
clusters setup.

See similar issue with cinder in bug #1563889

** Affects: glance
 Importance: Undecided
 Assignee: Danny Al-Gaaf (danny-al-gaaf)
 Status: In Progress

** Description changed:

- As the cinder rbd driver the glance_store should support to pass the
- ceph cluster name to the Rados/RBD driver while initiating a connection.
+ As the cinder rbd driver the glance_store should support to pass the ceph 
cluster name to the Rados/RBD driver while initiating a connection. This 
+ will be useful if you have either non-default cluster names or e.g. multiple
+ clusters setup.
  
  See similar issue with cinder in bug #1563889

** Changed in: glance
 Assignee: (unassigned) => Danny Al-Gaaf (danny-al-gaaf)

** Changed in: glance
   Status: New => In Progress

-- 
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to Glance.
https://bugs.launchpad.net/bugs/1565722

Title:
  glance_store should support RBD cluster name

Status in Glance:
  In Progress

Bug description:
  As the cinder rbd driver the glance_store should support to pass the ceph 
cluster name to the Rados/RBD driver while initiating a connection. This 
  will be useful if you have either non-default cluster names or e.g. multiple
  clusters setup.

  See similar issue with cinder in bug #1563889

To manage notifications about this bug go to:
https://bugs.launchpad.net/glance/+bug/1565722/+subscriptions

-- 
Mailing list: https://launchpad.net/~yahoo-eng-team
Post to : yahoo-eng-team@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yahoo-eng-team
More help   : https://help.launchpad.net/ListHelp


[Yahoo-eng-team] [Bug 1556818] [NEW] docstring warnings in glance

2016-03-14 Thread Danny Al-Gaaf
Public bug reported:

Building the glance docs produces some docstring warnings:

/develop/OpenStack/glance/glance/common/rpc.py:docstring of 
glance.common.rpc.Controller:9: WARNING: Definition list ends without a blank 
line; unexpected unindent.
/develop/OpenStack/glance/glance/common/rpc.py:docstring of 
glance.common.rpc.Controller:15: WARNING: Field list ends without a blank line; 
unexpected unindent.
/develop/OpenStack/glance/glance/common/rpc.py:docstring of 
glance.common.rpc.Controller.register:5: WARNING: Field list ends without a 
blank line; unexpected unindent.
/develop/OpenStack/glance/glance/common/rpc.py:docstring of 
glance.common.rpc.RPCClient.bulk_request:4: WARNING: Field list ends without a 
blank line; unexpected unindent.
/develop/OpenStack/glance/glance/common/rpc.py:docstring of 
glance.common.rpc.RPCClient.bulk_request:9: WARNING: Definition list ends 
without a blank line; unexpected unindent.

** Affects: glance
 Importance: Undecided
 Assignee: Danny Al-Gaaf (danny-al-gaaf)
 Status: New

** Changed in: glance
 Assignee: (unassigned) => Danny Al-Gaaf (danny-al-gaaf)

-- 
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to Glance.
https://bugs.launchpad.net/bugs/1556818

Title:
  docstring warnings in glance

Status in Glance:
  New

Bug description:
  Building the glance docs produces some docstring warnings:

  /develop/OpenStack/glance/glance/common/rpc.py:docstring of 
glance.common.rpc.Controller:9: WARNING: Definition list ends without a blank 
line; unexpected unindent.
  /develop/OpenStack/glance/glance/common/rpc.py:docstring of 
glance.common.rpc.Controller:15: WARNING: Field list ends without a blank line; 
unexpected unindent.
  /develop/OpenStack/glance/glance/common/rpc.py:docstring of 
glance.common.rpc.Controller.register:5: WARNING: Field list ends without a 
blank line; unexpected unindent.
  /develop/OpenStack/glance/glance/common/rpc.py:docstring of 
glance.common.rpc.RPCClient.bulk_request:4: WARNING: Field list ends without a 
blank line; unexpected unindent.
  /develop/OpenStack/glance/glance/common/rpc.py:docstring of 
glance.common.rpc.RPCClient.bulk_request:9: WARNING: Definition list ends 
without a blank line; unexpected unindent.

To manage notifications about this bug go to:
https://bugs.launchpad.net/glance/+bug/1556818/+subscriptions

-- 
Mailing list: https://launchpad.net/~yahoo-eng-team
Post to : yahoo-eng-team@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yahoo-eng-team
More help   : https://help.launchpad.net/ListHelp


[Yahoo-eng-team] [Bug 1556672] [NEW] doc: wrong internal link in opts/index.rst

2016-03-13 Thread Danny Al-Gaaf
Public bug reported:

Building the docs generates the following output:

glance/doc/source/opts/index.rst:5: WARNING: unknown document:
configuring

The code is:

Refer to :doc:`Basic Configuration `

Due to the location of the file in the tree it should be:

Refer to :doc:`Basic Configuration <../../configuring>`

to generate the correct link.

** Affects: glance
 Importance: Undecided
 Assignee: Danny Al-Gaaf (danny-al-gaaf)
 Status: New

** Changed in: glance
 Assignee: (unassigned) => Danny Al-Gaaf (danny-al-gaaf)

-- 
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to Glance.
https://bugs.launchpad.net/bugs/1556672

Title:
  doc: wrong internal link in opts/index.rst

Status in Glance:
  New

Bug description:
  Building the docs generates the following output:

  glance/doc/source/opts/index.rst:5: WARNING: unknown document:
  configuring

  The code is:

  Refer to :doc:`Basic Configuration `

  Due to the location of the file in the tree it should be:

  Refer to :doc:`Basic Configuration <../../configuring>`

  to generate the correct link.

To manage notifications about this bug go to:
https://bugs.launchpad.net/glance/+bug/1556672/+subscriptions

-- 
Mailing list: https://launchpad.net/~yahoo-eng-team
Post to : yahoo-eng-team@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yahoo-eng-team
More help   : https://help.launchpad.net/ListHelp


[Yahoo-eng-team] [Bug 1413205] Re: RBD backend errors are not raised correctly

2016-03-13 Thread Danny Al-Gaaf
*** This bug is a duplicate of bug 1501443 ***
https://bugs.launchpad.net/bugs/1501443

** This bug has been marked a duplicate of bug 1501443
   glance_store exceptions trigger child exceptions (which break Glance's error 
handling)

-- 
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to Glance.
https://bugs.launchpad.net/bugs/1413205

Title:
  RBD backend errors are not raised correctly

Status in Glance:
  New

Bug description:
  glance_store 2014.2
  When operation on RBD backend fail, e.g. by trying to open missing image in 
RBD pool, glance_store tries to raise exception NotFound with incorrect 
argument list, so glance API returns Internal Server Error 500.
  Older version (2014.1) returns 404.

  Steps to reproduce:
  $ glance image-create --name test --disk-format qcow2 --container-format bare 
--copy-from http://download.cirros-cloud.net/0.3.3/cirros-0.3.3-i386-disk.img
  # rbd -p images snap unprotect dbedacd2-a140-4816-a96d-b98ef610ddc3@snap
  # rbd -p images snap rm dbedacd2-a140-4816-a96d-b98ef610ddc3@snap
  # rbd -p images rm dbedacd2-a140-4816-a96d-b98ef610ddc3
  # glance-cache-manage -f delete-all-cached-images # only if cache used
  $ glance image-download --file img dbedacd2-a140-4816-a96d-b98ef610ddc3
  HTTPInternalServerError (HTTP 500)

  Backtrace in log:
File "/usr/lib/python2.7/dist-packages/glance/api/v1/images.py", line 454, 
in _get_from_store
  image_data, image_size = src_store.get(loc, context=context)
File "/usr/lib/python2.7/dist-packages/glance_store/_drivers/rbd.py", line 
222, in get
  chunk_size or self.get_size(location))
File "/usr/lib/python2.7/dist-packages/glance_store/_drivers/rbd.py", line 
248, in get_size
  raise exceptions.NotFound(msg)
  TypeError: __init__() takes exactly 1 argument (2 given)

  Request log attached.

To manage notifications about this bug go to:
https://bugs.launchpad.net/glance/+bug/1413205/+subscriptions

-- 
Mailing list: https://launchpad.net/~yahoo-eng-team
Post to : yahoo-eng-team@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yahoo-eng-team
More help   : https://help.launchpad.net/ListHelp


[Yahoo-eng-team] [Bug 1555476] [NEW] image delete() doesn't catch exceptions.HasSnapshot() from rbd driver

2016-03-10 Thread Danny Al-Gaaf
Public bug reported:

The glance_store driver raises a exceptions.HasSnapshot() if a image
can't be deleted because it has a snapshot. This exception is ignored in
glance/glance/api/v2/images.py. The code should raise at least a
HTTPConflict and print a useful error message to the user.

** Affects: glance
 Importance: Undecided
 Assignee: Danny Al-Gaaf (danny-al-gaaf)
 Status: New

** Changed in: glance
 Assignee: (unassigned) => Danny Al-Gaaf (danny-al-gaaf)

-- 
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to Glance.
https://bugs.launchpad.net/bugs/1555476

Title:
  image delete() doesn't catch exceptions.HasSnapshot() from rbd driver

Status in Glance:
  New

Bug description:
  The glance_store driver raises a exceptions.HasSnapshot() if a image
  can't be deleted because it has a snapshot. This exception is ignored
  in glance/glance/api/v2/images.py. The code should raise at least a
  HTTPConflict and print a useful error message to the user.

To manage notifications about this bug go to:
https://bugs.launchpad.net/glance/+bug/1555476/+subscriptions

-- 
Mailing list: https://launchpad.net/~yahoo-eng-team
Post to : yahoo-eng-team@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yahoo-eng-team
More help   : https://help.launchpad.net/ListHelp


[Yahoo-eng-team] [Bug 1356406] [NEW] bad indentation in glance code

2014-08-13 Thread Danny Al-Gaaf
Public bug reported:

pylint finds several cases of:

* Module glance.registry.api.v1.__init__
W: 22, 0: Bad indentation. Found 8 spaces, expected 4 (bad-indentation)
W: 24, 0: Bad indentation. Found 8 spaces, expected 4 (bad-indentation)
W: 27, 0: Bad indentation. Found 8 spaces, expected 4 (bad-indentation)
W: 31, 0: Bad indentation. Found 8 spaces, expected 4 (bad-indentation)
W: 35, 0: Bad indentation. Found 8 spaces, expected 4 (bad-indentation)
W: 39, 0: Bad indentation. Found 8 spaces, expected 4 (bad-indentation)
W: 43, 0: Bad indentation. Found 8 spaces, expected 4 (bad-indentation)
W: 47, 0: Bad indentation. Found 8 spaces, expected 4 (bad-indentation)
W: 52, 0: Bad indentation. Found 8 spaces, expected 4 (bad-indentation)
W: 54, 0: Bad indentation. Found 8 spaces, expected 4 (bad-indentation)
W: 58, 0: Bad indentation. Found 8 spaces, expected 4 (bad-indentation)
W: 62, 0: Bad indentation. Found 8 spaces, expected 4 (bad-indentation)
W: 66, 0: Bad indentation. Found 8 spaces, expected 4 (bad-indentation)
W: 70, 0: Bad indentation. Found 8 spaces, expected 4 (bad-indentation)
W: 74, 0: Bad indentation. Found 8 spaces, expected 4 (bad-indentation)
W: 78, 0: Bad indentation. Found 8 spaces, expected 4 (bad-indentation)
* Module glance.registry.api.v2.__init__
W: 21, 0: Bad indentation. Found 8 spaces, expected 4 (bad-indentation)
W: 22, 0: Bad indentation. Found 8 spaces, expected 4 (bad-indentation)
* Module glance.domain.__init__
W:354, 0: Bad indentation. Found 12 spaces, expected 8 (bad-indentation)
W:361, 0: Bad indentation. Found 12 spaces, expected 8 (bad-indentation)
W:362, 0: Bad indentation. Found 16 spaces, expected 12 (bad-indentation)
W:363, 0: Bad indentation. Found 12 spaces, expected 8 (bad-indentation)
W:364, 0: Bad indentation. Found 16 spaces, expected 12 (bad-indentation)

** Affects: glance
 Importance: Undecided
 Assignee: Danny Al-Gaaf (danny-al-gaaf)
 Status: In Progress

** Changed in: glance
 Assignee: (unassigned) = Danny Al-Gaaf (danny-al-gaaf)

** Changed in: glance
   Status: New = In Progress

-- 
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to Glance.
https://bugs.launchpad.net/bugs/1356406

Title:
  bad indentation in glance code

Status in OpenStack Image Registry and Delivery Service (Glance):
  In Progress

Bug description:
  pylint finds several cases of:

  * Module glance.registry.api.v1.__init__
  W: 22, 0: Bad indentation. Found 8 spaces, expected 4 (bad-indentation)
  W: 24, 0: Bad indentation. Found 8 spaces, expected 4 (bad-indentation)
  W: 27, 0: Bad indentation. Found 8 spaces, expected 4 (bad-indentation)
  W: 31, 0: Bad indentation. Found 8 spaces, expected 4 (bad-indentation)
  W: 35, 0: Bad indentation. Found 8 spaces, expected 4 (bad-indentation)
  W: 39, 0: Bad indentation. Found 8 spaces, expected 4 (bad-indentation)
  W: 43, 0: Bad indentation. Found 8 spaces, expected 4 (bad-indentation)
  W: 47, 0: Bad indentation. Found 8 spaces, expected 4 (bad-indentation)
  W: 52, 0: Bad indentation. Found 8 spaces, expected 4 (bad-indentation)
  W: 54, 0: Bad indentation. Found 8 spaces, expected 4 (bad-indentation)
  W: 58, 0: Bad indentation. Found 8 spaces, expected 4 (bad-indentation)
  W: 62, 0: Bad indentation. Found 8 spaces, expected 4 (bad-indentation)
  W: 66, 0: Bad indentation. Found 8 spaces, expected 4 (bad-indentation)
  W: 70, 0: Bad indentation. Found 8 spaces, expected 4 (bad-indentation)
  W: 74, 0: Bad indentation. Found 8 spaces, expected 4 (bad-indentation)
  W: 78, 0: Bad indentation. Found 8 spaces, expected 4 (bad-indentation)
  * Module glance.registry.api.v2.__init__
  W: 21, 0: Bad indentation. Found 8 spaces, expected 4 (bad-indentation)
  W: 22, 0: Bad indentation. Found 8 spaces, expected 4 (bad-indentation)
  * Module glance.domain.__init__
  W:354, 0: Bad indentation. Found 12 spaces, expected 8 (bad-indentation)
  W:361, 0: Bad indentation. Found 12 spaces, expected 8 (bad-indentation)
  W:362, 0: Bad indentation. Found 16 spaces, expected 12 (bad-indentation)
  W:363, 0: Bad indentation. Found 12 spaces, expected 8 (bad-indentation)
  W:364, 0: Bad indentation. Found 16 spaces, expected 12 (bad-indentation)

To manage notifications about this bug go to:
https://bugs.launchpad.net/glance/+bug/1356406/+subscriptions

-- 
Mailing list: https://launchpad.net/~yahoo-eng-team
Post to : yahoo-eng-team@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yahoo-eng-team
More help   : https://help.launchpad.net/ListHelp