Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-32892

SVN_REVISION(_1) gets set to an unexpected value, seems to be "Last Changed Rev" from previous build.

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Major Major
    • subversion-plugin
    • AMD64
      Debian GNU/Linux 8
      Jenkins LTS 1.609.3
      Tomcat 7.0.54
      Oracle JDK 8
      Subversion Plugin 1.5.7
      LANG=de_DE.UTF-8

      SVN_REVISION(_1) gets set to an unexpected value, seems to be "last modified" from previous build.

      For a regular job (here maven, but seems to happen also on freestyle) using subversion plugin for checkout, we get the following behaviour:

      Job overview states
      Revision: 55304

      Checking out http://svn-[.....]/trunk at revision '2016-02-11T13:04:54.819 +0100'
      At revision 55305

      variables set in this build by subversion plugin:
      SVN_REVISION_1=55291
      SVN_REVISION=55291

      svn info from prebuild-step shell command states:
      Revision: 55305
      Last Changed Rev: 55304

      When running another build of this job:

      Job overview states
      Revision: 55304

      Checking out http://svn-[...]/trunk at revision '2016-02-11T13:10:41.523 +0100'
      At revision 55315

      variables set in this build by subversion plugin:
      SVN_REVISION_1=55304
      SVN_REVISION=55304

      svn info from prebuild-step shell command states:
      Revision: 55315
      Last changed Rev: 55304

      We expected SVN_REVISION(_1) to be set to the value of svn info "Last Changed Rev" of the current build, but it seems like it gets set to the value of svn info "Last Changed Rev" which was seen in the previous build.

      When we start a checkout, abort the job immediately after checkout, and start again, we get the SVN_REVISION(_1) set as expected, but only if nobody has checked in new changes before starting a new build.

      This behaviour is reproducible for us for all jobs using subversion plugin for checkout.

            Unassigned Unassigned
            tcb_xy Tim-Christian Bloss
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated: