Author: Matti Picus <matti.pi...@gmail.com> Branch: numpy-tests Changeset: r872:f78c853a0134 Date: 2013-11-04 14:00 +0200 http://bitbucket.org/pypy/buildbot/changeset/f78c853a0134/
Log: downloading works diff --git a/bot2/pypybuildbot/builds.py b/bot2/pypybuildbot/builds.py --- a/bot2/pypybuildbot/builds.py +++ b/bot2/pypybuildbot/builds.py @@ -1,4 +1,5 @@ from buildbot.steps.source.mercurial import Mercurial +from buildbot.steps.source.git import Git from buildbot.process.buildstep import BuildStep from buildbot.process import factory from buildbot.steps import shell, transfer @@ -85,7 +86,7 @@ properties = self.build.getProperties() branch = map_branch_name(properties['branch']) - revision = properties['final_file_name'] + revision = properties.getProperty('final_file_name') mastersrc = os.path.expanduser(self.mastersrc) if branch.startswith('/'): @@ -185,6 +186,7 @@ # XXX in general it would be nice to drop the revision-number using only the # changeset-id for got_revision and final_file_name and sorting the builds # chronologically + class UpdateGitCheckout(ShellCmd): description = 'git checkout' command = 'UNKNOWN' @@ -326,45 +328,16 @@ def update_git(platform, factory, repourl, workdir, use_branch, force_branch=None): - if platform == 'win32': - command = "if not exist .git rmdir /q /s ." - else: - command = "if [ ! -d .git ]; then rm -fr * .[a-z]*; fi" - factory.addStep(ShellCmd(description="rmdir?", - command=command, - workdir=workdir, - haltOnFailure=False)) - # - if platform == "win32": - command = "if not exist .git %s" - else: - command = "if [ ! -d .git ]; then %s; fi" - command = command % ("git clone " + repourl + " .") - factory.addStep(ShellCmd(description="git clone", - command=command, - workdir=workdir, - timeout=3600, - haltOnFailure=True)) - # - factory.addStep( - ShellCmd(description="git clean", - command="git clean", - workdir=workdir, - haltOnFailure=True)) - # - factory.addStep(ShellCmd(description="git pull", - command="git pull", - workdir=workdir)) - # - if use_branch or force_branch: - factory.addStep(UpdateGitCheckout(workdir=workdir, - haltOnFailure=True, - force_branch=force_branch)) - else: - factory.addStep(ShellCmd(description="git checkout", - command=WithProperties("git checkout -f %(revision)s"), - workdir=workdir)) - + factory.addstep( + Git( + repourl=repourl, + mode='full', + method='fresh', + defaultBranch=force_branch, + branchType='inrepo', + clobberOnBranchChange=False, + workdir=workdir, + logEnviron=False)) def setup_steps(platform, factory, workdir=None, repourl='https://bitbucket.org/pypy/pypy/', @@ -832,22 +805,21 @@ def __init__(self, platform='linux', app_tests=False, lib_python=False, - pypyjit=False, + pypyjit=True, prefix=None, translationArgs=[] ): factory.BuildFactory.__init__(self) - # XXX extend to checkout the specific revision of the build - setup_steps(platform, self) - + self.addStep(ParseRevision(hideStepIf=ParseRevision.hideStepIf, + doStepIf=ParseRevision.doStepIf)) # download corresponding nightly build self.addStep(ShellCmd( description="Clear pypy-c", command=['rm', '-rf', 'pypy-c'], workdir='.')) extension = get_extension(platform) - name = build_name(platform, pypyjit, translationArgs, placeholder='%(revision)s') + extension + name = build_name(platform, pypyjit, translationArgs, placeholder='%(final_file_name)s') + extension self.addStep(PyPyDownload( basename=name, mastersrc='~/nightly', @@ -860,34 +832,32 @@ else: self.addStep(ShellCmd( description="decompress pypy-c", - command=['tar', '--extract', '--file=pypy_build'+ extension, - '--strip-components=1', '--directory=.'], - workdir='pypy-c/download')) + command=['tar', '--extract', '--file=pypy_build'+ extension, '--strip-components=1', '--directory=.'], + workdir='pypy-c', + haltOnFailure=True, + )) # virtualenv the download self.addStep(ShellCmd( description="create virtualenv", - command=['virtualenv','-p', 'download/bin/pypy', 'install'], - workdir='pypy-c')) + command=['virtualenv','-p', 'bin/pypy', 'install'], + workdir='pypy-c', + haltOnFailure=True, + )) self.addStep(ShellCmd( description="install nose", command=['install/bin/pip', 'install','nose'], - workdir='pypy-c')) + workdir='pypy-c', + haltOnFailure=True, + )) # obtain a pypy-compatible branch of numpy - numpy_url = 'https://github.com/mattip/numpy' + numpy_url = 'https://www.bitbucket.org/pypy/numpy' numpy_pypy_branch = 'pypy' update_git(platform, self, numpy_url, 'numpy_src', use_branch=True, force_branch=numpy_pypy_branch) - if os.path.exists('pypy_c/download/lib_pypy/numpy.py'): - self.addStep(ShellCmd( - description="delete lib_pypy/numpy.*", - command=['rm', 'download/lib_pypy/numpy.*'], - workdir='pypy-c')) - - self.addStep(ShellCmd( description="install numpy", command=['install/bin/python', 'setup.py','install'], diff --git a/bot2/pypybuildbot/master.py b/bot2/pypybuildbot/master.py --- a/bot2/pypybuildbot/master.py +++ b/bot2/pypybuildbot/master.py @@ -148,7 +148,7 @@ pypyJITBenchmarkFactory64_tannit = pypybuilds.JITBenchmark(platform='linux64', postfix='-64') -pypyNumpyCompatability = pypybuilds.NativeNumpyTests() +pypyNumpyCompatability = pypybuilds.NativeNumpyTests(platform='linux64') # @@ -266,6 +266,7 @@ JITONLYLINUXPPC64, JITBENCH, JITBENCH64, + NUMPY_64, ] + ARM.builderNames, properties=[]), ] + ARM.schedulers, _______________________________________________ pypy-commit mailing list pypy-commit@python.org https://mail.python.org/mailman/listinfo/pypy-commit