[Python-Dev] Testing tkinter on Linux
Zachary Ware
zachary.ware+pydev at gmail.com
Fri Aug 28 08:55:01 CEST 2015
On Thu, Aug 27, 2015 at 4:13 PM, Chris Angelico <rosuav at gmail.com> wrote:
> On Fri, Aug 28, 2015 at 5:00 AM, R. David Murray <rdmurray at bitdance.com> wrote:
>> I believe gui depends on the existence of the DISPLAY environment
>> variable on unix/linux (that is, TK will fail to start if DISPLAY is not
>> set, so _is_gui_available will return False). You should be able to
>> confirm this by looking at the text of the skip message in the buildbot
>> output.
>
> A recent buildbot log [1] shows that the GUI tests are being skipped,
> although I'm not seeing the message. Where do I go to set DISPLAY for
> the bot (which runs mostly in the background)?
>
> Note that it's all running as root, which may make a difference to the
> defaults, so this might have to be done more explicitly than it
> otherwise would. (But root is quite happy to use X; running xclock
> brings up a clock just fine.)
I just set up a buildslave building with X available [1]. I don't
know if the way I did it is strictly correct, but my slave is set up
with Xvfb set to start at boot, and I hacked the buildbot.tac file to
add 'os.environ["DISPLAY"] = ":100"' (which is what Xvfb starts on) as
that was the simplest way I could figure out to do it. It seems to
work; an initial test build of 2.7 passed all the Tcl/Tk tests [2].
For those interested, the slave has Tcl/Tk 8.5.17 installed (which is
the latest "stable" release in portage).
[1] http://buildbot.python.org/all/buildslaves/ware-gentoo-x86
[2] http://buildbot.python.org/all/builders/x86%20Gentoo%20Non-Debug%20with%20X%202.7/builds/0/steps/test/logs/stdio
--
Zach
More information about the Python-Dev
mailing list