FS#38409 - [python2-migrate] Buildbot unusable with latest updates, sqlalchemy too new

Attached to Project: Community Packages
Opened by nightstrike (nightstrike) - Tuesday, 07 January 2014, 18:32 GMT
Last edited by Balló György (City-busz) - Monday, 13 January 2014, 12:10 GMT
Task Type Bug Report
Category Upstream Bugs
Status Closed
Assigned To Sergej Pupykin (sergej)
Jelle van der Waa (jelly)
Architecture All
Severity High
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 0
Private No

Details

Description:
The latest bout of pacman -Su results in updating dependencies for buildbot. However, buildbot cannot work at all with the version of sqlalchemy-migrate currently provided. Trying to do even the most basic of buildbot actions results in this:

Traceback (most recent call last):
File "/usr/bin/buildbot", line 4, in <module>
runner.run()
File "/usr/lib/python2.7/site-packages/buildbot/scripts/runner.py", line 730, in run
subcommandFunction = reflect.namedObject(subconfig.subcommandFunction)
File "/usr/lib/python2.7/site-packages/twisted/python/_reflectpy3.py", line 151, in namedObject
module = namedModule('.'.join(classSplit[:-1]))
File "/usr/lib/python2.7/site-packages/twisted/python/_reflectpy3.py", line 137, in namedModule
topLevel = __import__(name)
File "/usr/lib/python2.7/site-packages/buildbot/scripts/upgrade_master.py", line 25, in <module>
from buildbot.db import connector
File "/usr/lib/python2.7/site-packages/buildbot/db/connector.py", line 22, in <module>
from buildbot.db import pool, model, changes, schedulers, sourcestamps, sourcestampsets
File "/usr/lib/python2.7/site-packages/buildbot/db/model.py", line 17, in <module>
import migrate
File "/usr/lib/python2.7/site-packages/migrate/__init__.py", line 9, in <module>
from migrate.changeset import *
File "/usr/lib/python2.7/site-packages/migrate/changeset/__init__.py", line 21, in <module>
from migrate.changeset.schema import *
File "/usr/lib/python2.7/site-packages/migrate/changeset/schema.py", line 15, in <module>
from migrate.changeset.databases.visitor import (get_engine_visitor,
File "/usr/lib/python2.7/site-packages/migrate/changeset/databases/visitor.py", line 6, in <module>
from migrate.changeset import ansisql
File "/usr/lib/python2.7/site-packages/migrate/changeset/ansisql.py", line 10, in <module>
from sqlalchemy.schema import SchemaVisitor
ImportError: cannot import name SchemaVisitor
This task depends upon

Closed by  Balló György (City-busz)
Monday, 13 January 2014, 12:10 GMT
Reason for closing:  Fixed
Additional comments about closing:  python2-migrate 0.7.2-6
Comment by Dustin J. Mitchell (djmitche) - Tuesday, 07 January 2014, 18:40 GMT
Per https://github.com/buildbot/buildbot/blob/master/master/setup.py#L215

Buildbot requires sqlalchemy between 0.6 and 0.7.10 (they've since released 0.7.11 too, which works), and one of the listed versions of sqlalchemy-migrate:
'sqlalchemy-migrate ==0.6.1, ==0.7.0, ==0.7.1, ==0.7.2'

The issue is an incompatibility between sqlalchemy-migrate and sqlalchemy.
Comment by Balló György (City-busz) - Saturday, 11 January 2014, 02:30 GMT
It looks like sqlalchemy-migrate 0.7.2 is incompatible with sqlalchemy 0.9.

Is it solve the problem if you downgrade python2-sqlalchemy package to version 0.8.4-1? You can download it from here:
http://seblu.net/a/arm/2013/12/31/community/os/x86_64/python2-sqlalchemy-0.8.4-1-x86_64.pkg.tar.xz

In this case please report the problem to the upstream maintainers of sqlalchemy-migrate:
https://code.google.com/p/sqlalchemy-migrate/issues/list
Comment by xduugu (xduugu) - Monday, 13 January 2014, 11:31 GMT
According to lifo2[1], it can be fixed by:
>That I fixed by editing /usr/lib/python2.7/site-packages/migrate/changeset/ansisql.py to change the following line:
>from sqlalchemy.schema import SchemaVisitor
>by:
>from sqlalchemy.sql.base import SchemaVisitor

[1] https://aur.archlinux.org/packages/pytrainer/
Comment by Balló György (City-busz) - Monday, 13 January 2014, 11:58 GMT
@xduugu: I'll fix the package, but please open an upstream bug report: https://code.google.com/p/sqlalchemy-migrate/issues/entry

Loading...