install throws errors about SADeprecationWarning

Bug #925609 reported by Scott Moser
12
This bug affects 2 people
Affects Status Importance Assigned to Milestone
Glance
Fix Released
Low
David Ripton
Folsom
Fix Released
Low
Eoghan Glynn
glance (Ubuntu)
Fix Released
Medium
Chuck Short
Precise
Fix Released
Medium
Chuck Short

Bug Description

install of glance shows:

Setting up glance-common (2012.1~e3-0ubuntu1) ...
Adding system user `glance' (UID 123) ...
Adding new user `glance' (UID 123) with group `glance' ...
Not creating home directory `/var/lib/glance'.
Setting up glance-api (2012.1~e3-0ubuntu1) ...
glance-api start/running, process 30295
Setting up glance-registry (2012.1~e3-0ubuntu1) ...
/usr/lib/python2.7/dist-packages/glance/registry/db/migrate_repo/versions/001_add_images_table.py:40: SADeprecationWarning: useexisting is deprecated. Use extend_existing.
  useexisting=True)
/usr/lib/python2.7/dist-packages/glance/registry/db/migrate_repo/versions/001_add_images_table.py:40: SADeprecationWarning: useexisting is deprecated. Use extend_existing.
  useexisting=True)
/usr/lib/python2.7/dist-packages/glance/registry/db/migrate_repo/versions/002_add_image_properties_table.py:45: SADeprecationWarning: useexisting is deprecated. Use extend_existing.
  useexisting=True)
/usr/lib/python2.7/dist-packages/glance/registry/db/migrate_repo/versions/004_add_checksum.py:48: SADeprecationWarning: useexisting is deprecated. Use extend_existing.
  useexisting=True)
/usr/lib/python2.7/dist-packages/glance/registry/db/migrate_repo/versions/007_add_owner.py:50: SADeprecationWarning: useexisting is deprecated. Use extend_existing.
  useexisting=True)
/usr/lib/python2.7/dist-packages/glance/registry/db/migrate_repo/versions/007_add_owner.py:50: SADeprecationWarning: useexisting is deprecated. Use extend_existing.
  useexisting=True)
/usr/lib/python2.7/dist-packages/glance/registry/db/migrate_repo/versions/008_add_image_members_table.py:64: SADeprecationWarning: useexisting is deprecated. Use extend_existing.
  useexisting=True)
/usr/lib/python2.7/dist-packages/glance/registry/db/migrate_repo/versions/009_add_mindisk_and_minram.py:50: SADeprecationWarning: useexisting is deprecated. Use extend_existing.
  useexisting=True)
/usr/lib/python2.7/dist-packages/glance/registry/db/migrate_repo/versions/007_add_owner.py:50: SADeprecationWarning: useexisting is deprecated. Use extend_existing.
  useexisting=True)
/usr/lib/python2.7/dist-packages/migrate/changeset/schema.py:124: MigrateDeprecationWarning: Passing a Column object to alter_column is deprecated. Just pass in keyword parameters instead.
  MigrateDeprecationWarning
glance-registry start/running, process 30351
Setting up glance (2012.1~e3-0ubuntu1) ...

ProblemType: Bug
DistroRelease: Ubuntu 12.04
Package: glance-registry 2012.1~e3-0ubuntu1
ProcVersionSignature: Ubuntu 3.2.0-12.20-generic 3.2.2
Uname: Linux 3.2.0-12-generic x86_64
ApportVersion: 1.91-0ubuntu1
Architecture: amd64
Date: Thu Feb 2 12:37:52 2012
EcryptfsInUse: Yes
InstallationMedia: Ubuntu 11.10 "Oneiric Ocelot" - Release amd64 (20111012)
PackageArchitecture: all
ProcEnviron:
 PATH=(custom, user)
 LANG=en_US.UTF-8
 SHELL=/bin/bash
SourcePackage: glance
UpgradeStatus: Upgraded to precise on 2011-11-07 (87 days ago)
modified.conffile..etc.glance.glance.registry.conf: [deleted]
modified.conffile..etc.glance.glance.registry.paste.ini: [deleted]

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

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in glance (Ubuntu):
status: New → Confirmed
Revision history for this message
shake.chen (shake-chen) wrote :
Download full text (4.2 KiB)

HI I try the ubuntu 12.04 alpha 2

root@node34:~# apt-cache policy glance
glance:
  Installed: 2012.1~e3-0ubuntu1
  Candidate: 2012.1~e3-0ubuntu1
  Version table:
 *** 2012.1~e3-0ubuntu1 0
        500 http://cn.archive.ubuntu.com/ubuntu/ precise/main amd64 Packages
        100 /var/lib/dpkg/status

after install glance

# glance-manage db_sync
/usr/lib/python2.7/dist-packages/glance/registry/db/migrate_repo/versions/001_add_images_table.py:40: SADeprecationWarning: useexisting is deprecated. Use extend_existing.
  useexisting=True)
Traceback (most recent call last):
  File "/usr/bin/glance-manage", line 128, in <module>
    main()
  File "/usr/bin/glance-manage", line 124, in main
    dispatch_cmd(conf, args)
  File "/usr/bin/glance-manage", line 99, in dispatch_cmd
    cmd_func(conf, args)
  File "/usr/bin/glance-manage", line 87, in do_db_sync
    glance.registry.db.migration.db_sync(conf, version=db_version)
  File "/usr/lib/python2.7/dist-packages/glance/registry/db/migration.py", line 123, in db_sync
    upgrade(conf, version=version)
  File "/usr/lib/python2.7/dist-packages/glance/registry/db/migration.py", line 66, in upgrade
    return versioning_api.upgrade(sql_connection, repo_path, version)
  File "/usr/lib/python2.7/dist-packages/migrate/versioning/api.py", line 186, in upgrade
    return _migrate(url, repository, version, upgrade=True, err=err, **opts)
  File "<string>", line 2, in _migrate
  File "/usr/lib/python2.7/dist-packages/migrate/versioning/util/__init__.py", line 159, in with_engine
    return f(*a, **kw)
  File "/usr/lib/python2.7/dist-packages/migrate/versioning/api.py", line 366, in _migrate
    schema.runchange(ver, change, changeset.step)
  File "/usr/lib/python2.7/dist-packages/migrate/versioning/schema.py", line 91, in runchange
    change.run(self.engine, step)
  File "/usr/lib/python2.7/dist-packages/migrate/versioning/script/py.py", line 145, in run
    script_func(engine)
  File "/usr/lib/python2.7/dist-packages/glance/registry/db/migrate_repo/versions/001_add_images_table.py", line 49, in upgrade
    create_tables(tables)
  File "/usr/lib/python2.7/dist-packages/glance/registry/db/migrate_repo/schema.py", line 97, in create_tables
    table.create()
  File "/usr/lib/python2.7/dist-packages/sqlalchemy/schema.py", line 564, in create
    checkfirst=checkfirst)
  File "/usr/lib/python2.7/dist-packages/sqlalchemy/engine/base.py", line 2234, in _run_visitor
    conn._run_visitor(visitorcallable, element, **kwargs)
  File "/usr/lib/python2.7/dist-packages/sqlalchemy/engine/base.py", line 1904, in _run_visitor
    **kwargs).traverse_single(element)
  File "/usr/lib/python2.7/dist-packages/sqlalchemy/sql/visitors.py", line 86, in traverse_single
    return meth(obj, **kw)
  File "/usr/lib/python2.7/dist-packages/sqlalchemy/engine/ddl.py", line 86, in visit_table
    self.connection.execute(schema.CreateTable(table))
  File "/usr/lib/python2.7/dist-packages/sqlalchemy/engine/base.py", line 1405, in execute
    params)
  File "/usr/lib/python2.7/dist-packages/sqlalchemy/engine/base.py", line 1496, in _execute_ddl
    compiled
  File "/usr/lib/python2.7/dist-packages/sqlalchemy/engine/base.py", line 1646, in _execute...

Read more...

Revision history for this message
Peng Yong (ppyy) wrote :

@shake.chen, it's not same bug.

sqlalchemy.exc.OperationalError: (OperationalError) (1050, "Table 'images' already exists") '\nCREATE TABLE images (\n\tid INTEGER NOT NULL

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to glance (master)

Fix proposed to branch: master
Review: https://review.openstack.org/5031

Changed in glance:
assignee: nobody → Chuck Short (zulcss)
status: New → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to glance (master)

Reviewed: https://review.openstack.org/5031
Committed: http://github.com/openstack/glance/commit/630c9a594a97b3516476e3e04d516f08ec725f1f
Submitter: Jenkins
Branch: master

commit 630c9a594a97b3516476e3e04d516f08ec725f1f
Author: Chuck Short <email address hidden>
Date: Wed Mar 7 10:44:31 2012 -0500

    Fix deprecated warnings.

    Fixes deprecated warnings when using sqlalchemy 0.7.4.
    Fixes bug 925609.

    Change-Id: I5ad5042dbc9785829694553f2657df3eb6e3ef20
    Signed-off-by: Chuck Short <email address hidden>

Changed in glance:
status: In Progress → Fix Committed
Revision history for this message
Vibhav Pant (vibhavp) wrote :
Revision history for this message
James Page (james-page) wrote :

Hi Vibhav

Thanks for taking the time to prepare a patch for this bug.

Looking at the bug history this has now been fixed in upstream; this should land in Ubuntu precise in the new few days.

Unsubscribing ubuntu-sponsors as no action is require.

Thanks for your work

Cheers

James

Changed in glance (Ubuntu):
assignee: nobody → Chuck Short (zulcss)
milestone: none → ubuntu-12.04-beta-2
Changed in glance (Ubuntu Precise):
importance: Undecided → Medium
status: Confirmed → In Progress
Thierry Carrez (ttx)
Changed in glance:
milestone: none → essex-rc1
status: Fix Committed → Fix Released
Chuck Short (zulcss)
Changed in glance (Ubuntu Precise):
status: In Progress → Fix Released
Thierry Carrez (ttx)
Changed in glance:
milestone: essex-rc1 → 2012.1
Changed in glance:
assignee: Chuck Short (zulcss) → David Ripton (dripton)
status: Fix Released → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote :

Reviewed: https://review.openstack.org/14177
Committed: http://github.com/openstack/glance/commit/baf402652b578ade15263c5c9357797cf04ec824
Submitter: Jenkins
Branch: master

commit baf402652b578ade15263c5c9357797cf04ec824
Author: David Ripton <email address hidden>
Date: Mon Oct 8 15:24:45 2012 -0400

    Change useexisting to extend_existing to fix deprecation warnings.

    This squelches a deprecation warning during installation.

    We're already using extend_existing in other places, so I don't
    think this causes any new version compatibility issues.

    Fixes bug 925609. (Already marked fixed, but this hits more cases.)

    Includes some merges with a whitespace-cleanup fix.

    Change-Id: Ia166e9184ed3e13753c5669a1006a3711738319a

Changed in glance:
status: In Progress → Fix Committed
Brian Waldon (bcwaldon)
Changed in glance:
importance: Undecided → Low
Thierry Carrez (ttx)
Changed in glance:
status: Fix Committed → Fix Released
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to glance (stable/folsom)

Fix proposed to branch: stable/folsom
Review: https://review.openstack.org/20492

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to glance (stable/folsom)

Reviewed: https://review.openstack.org/20492
Committed: http://github.com/openstack/glance/commit/4c96080375553f5ffaaaa4b1470160464bcfb910
Submitter: Jenkins
Branch: stable/folsom

commit 4c96080375553f5ffaaaa4b1470160464bcfb910
Author: David Ripton <email address hidden>
Date: Mon Oct 8 15:24:45 2012 -0400

    Change useexisting to extend_existing to fix deprecation warnings.

    This squelches a deprecation warning during installation.

    We're already using extend_existing in other places, so I don't
    think this causes any new version compatibility issues.

    Fixes bug 925609. (Already marked fixed, but this hits more cases.)

    Includes some merges with a whitespace-cleanup fix.

    Change-Id: Ia166e9184ed3e13753c5669a1006a3711738319a

tags: added: in-stable-folsom
Mark McLoughlin (markmc)
tags: removed: in-stable-folsom
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.