Hi Pierre,
Attached is my Dockerfile with my most recent attempt. If that's not the way to 
share, let me know the preferred method.

I'll add the 'virtualenv' commands back in to see if that helps.

Thanks,
hank

From: Pierre Tardy [mailto:[email protected]] 
Sent: Monday, August 08, 2016 2:10 PM
To: Barta, Hank <[email protected]>; users ([email protected]) 
<[email protected]>
Subject: Re: [[email protected]] SQLAlchemy and SQLAlchemy-Migrate versions?

I think it is indeed better to just use virtualenv in order to be safe. 
The error you are posting means that there is a corruption somehow on the 
python environment on your docker image maybe due to those force installs. I 
would start from scratch. Do you use a Dockerfile you can share?

Le lun. 8 août 2016 20:38, Barta, Hank <[email protected]> a écrit :
Hi Pierre,
Thanks for the quick reply.

We're running Buildbot in a Docker container. Will the --force-reinstall lead 
to an incoherent state for Buildbot? I'm not really concerned about other apps 
because Buildbot is the only thing we plan to run in the container.

Will Virtualenv solve the seeming version conflict between SQLAlchemy and 
SQLAlchemy-Migrate versions (and what Buildbot needs?)

I'm far from a Python guru so I'm not sure how to find what versions of these 
two packages will play nice with each other and support the needs of Buildbot 
other than trial and error. That seems like a pretty tedious adventure. ;)

Right now I'm working in a 16.04 LTS based container so I can use current 
versions of these packages. I did not have this conflict with the older stuff ( 
0.8.8 on Ubuntu 14.04) but it did not send email notification either.

Thanks,
hank

From: Pierre Tardy [mailto:[email protected]]
Sent: Monday, August 08, 2016 1:07 PM
To: Barta, Hank <[email protected]>; users ([email protected]) 
<[email protected]>
Subject: Re: [[email protected]] SQLAlchemy and SQLAlchemy-Migrate versions?

Hi Hank,

It is highly recommended to use virtualenv to install buildbot.
Messing up with distro python packages with such options as --force-reinstall 
will lead to incoherent state and maybe instability of other distro programs.

http://trac.buildbot.net/wiki/RunningBuildbotWithVirtualEnv




Le lun. 8 août 2016 à 19:06, Barta, Hank <[email protected]> a écrit :
OS: Ubuntu 16.04 LTS
Python 2.7.12
Buildbot version: 0.8.12
Twisted version: 16.0.0

I'm confused. The manual at 
http://docs.buildbot.net/current/manual/installation.html#requirements (Says 
"Buildbot 0.8.12 documentation" at the top of the page) states:

"Buildbot requires SQLAlchemy 0.6.0 or higher. SQLAlchemy allows Buildbot to 
build database schemas and queries for a wide variety of database systems."

I have the default package for Ubuntu 16.04 installed:
"ii  python-sqlalchemy          1.0.11+ds1-1ubuntu2             all          
SQL toolkit and Object Relational Mapper for Python"
(Looks like 1.0.11 to me.)

A bit further on the same page I see:
"Buildbot requires one of the following SQLAlchemy-Migrate versions: 0.7.1, 
0.7.2 and 0.9. SQLAlchemy-Migrate-0.9 is required for compatibility with 
SQLAlchemy versions 0.8 and above. Buildbot uses SQLAlchemy-Migrate to manage 
schema upgrades from version to version."

I install 0.9 using:
"pip install -I sqlalchemy-migrate==0.9 --force-reinstall"

When I run Buildbot it starts up but when it tries to send email, it gets an 
error:
2016-08-08 16:50:29+0000 [-] Exception caught notifying 
<buildbot.status.mail.MailNotifier object at 0x7f9aa740e390> of buildFinished 
event
2016-08-08 16:50:29+0000 [-] Unhandled Error
        Traceback (most recent call last):
          File "/usr/lib/python2.7/dist-packages/buildbot/status/build.py", 
line 320, in buildFinished
            w.callback(self)
          File "/usr/lib/python2.7/dist-packages/twisted/internet/defer.py", 
line 393, in callback
            self._startRunCallbacks(result)
          File "/usr/lib/python2.7/dist-packages/twisted/internet/defer.py", 
line 501, in _startRunCallbacks
            self._runCallbacks()
          File "/usr/lib/python2.7/dist-packages/twisted/internet/defer.py", 
line 588, in _runCallbacks
            current.result = callback(current.result, *args, **kw)
        --- <exception caught here> ---
          File "/usr/lib/python2.7/dist-packages/buildbot/status/builder.py", 
line 597, in _buildFinished
            w.buildFinished(name, s, results)
          File "/usr/lib/python2.7/dist-packages/buildbot/status/mail.py", line 
537, in buildFinished
            return self.buildMessage(name, [build], results)
          File "/usr/lib/python2.7/dist-packages/buildbot/status/mail.py", line 
735, in buildMessage
            build=build, results=build.results)
          File "/usr/lib/python2.7/dist-packages/buildbot/status/mail.py", line 
716, in buildMessageDict
            self.master_status)
          File "/var/lib/devops/buildbot/master/master.cfg", line 143, in 
messageFormatter
            result = util.Results[results]
          File "/usr/lib/python2.7/dist-packages/buildbot/plugins/db.py", line 
238, in __getattr__
            raise AttributeError(str(err))
        exceptions.AttributeError: Requirements are not satisfied for 
buildbot.util:Results: (sqlalchemy-migrate 0.9 
(/usr/local/lib/python2.7/dist-packages), 
Requirement.parse('sqlalchemy-migrate==0.7.2'))

If I try sqlalchemy-migrate==0.7.2 the master errors on startup with:
2016-08-08 16:46:43+0000 [-] while starting BuildMaster
        Traceback (most recent call last):
          File "/usr/lib/python2.7/dist-packages/twisted/internet/defer.py", 
line 501, in _startRunCallbacks
            self._runCallbacks()
          File "/usr/lib/python2.7/dist-packages/twisted/internet/defer.py", 
line 588, in _runCallbacks
            current.result = callback(current.result, *args, **kw)
          File "/usr/lib/python2.7/dist-packages/twisted/internet/defer.py", 
line 1184, in gotResult
            _inlineCallbacks(r, g, deferred)
          File "/usr/lib/python2.7/dist-packages/twisted/internet/defer.py", 
line 1128, in _inlineCallbacks
            result = g.send(result)
        --- <exception caught here> ---
          File "/usr/lib/python2.7/dist-packages/buildbot/master.py", line 206, 
in startService
            yield self.db.setup()
          File "/usr/lib/python2.7/dist-packages/buildbot/db/connector.py", 
line 101, in setup
            basedir=self.basedir)
          File 
"/usr/lib/python2.7/dist-packages/buildbot/db/enginestrategy.py", line 249, in 
create_engine
            return sa.create_engine(*args, **kwargs)
          File 
"/usr/local/lib/python2.7/dist-packages/sqlalchemy/engine/__init__.py", line 
386, in create_engine
            return strategy.create(*args, **kwargs)
          File 
"/usr/lib/python2.7/dist-packages/buildbot/db/enginestrategy.py", line 203, in 
create
            self.check_sqlalchemy_version()
          File 
"/usr/lib/python2.7/dist-packages/buildbot/db/enginestrategy.py", line 198, in 
check_sqlalchemy_version
            "SQLAlchemy-Migrate version %d.%d.%d" % (version, mvt[0], mvt[1], 
mvt[2]))
        exceptions.RuntimeError: SQLAlchemy version 1.0.14 is not supported by 
SQLAlchemy-Migrate version 0.7.2

(Hmmm... package name is 1.0.11 and module identifies itself as 1.0.14 ...)

What versions of these modules should I be running?

Thanks,
hank
________________________________
NOTICE OF CONFIDENTIALITY:
This message may contain information that is considered confidential and which 
may be prohibited from disclosure under applicable law or by contractual 
agreement. The information is intended solely for the use of the individual or 
entity named above. If you are not the intended recipient, you are hereby 
notified that any disclosure, copying, distribution or use of the information 
contained in or attached to this message is strictly prohibited. If you have 
received this email transmission in error, please notify the sender by replying 
to this email and then delete it from your system.
_______________________________________________
users mailing list
[email protected]
https://lists.buildbot.net/mailman/listinfo/users

Attachment: Dockerfile
Description: Dockerfile

_______________________________________________
users mailing list
[email protected]
https://lists.buildbot.net/mailman/listinfo/users

Reply via email to