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

Property Variables "Randomly" Not Working/Getting Unset

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Component/s: envinject-plugin
    • Labels:
      None
    • Environment:
      Windows Server 2003 SP2
    • Similar Issues:

      Description

      Variables are randomly getting unset or not resolved depending upon the name and length of the variable name itself.
      This is broken in 0.15, but was working correctly in 0.14.

      To reproduce:
      1) Create a task and configure it
      2) Add a "Inject Environment Variables" build step
      3) Paste the following into the Properties Content section:
      -----------------------------------------------------------------
      A=value
      B=$

      {A}

      ZIP=${B}
      TIP=${B}
      TZP=${B}
      AIP=${B}
      UIP=${B}_${UNSETVAR}
      VIP=${B}_${UNSETVAR}
      -----------------------------------------------------------------
      4) Run the build

      Result in the log:
      ----------------------------------------------------------------------
      [EnvInject] - Injecting as environment variables the properties content
      'A=value
      B=${A}

      ZIP=$

      {B}
      TIP=${B}

      TZP=$

      {B}
      AIP=${B}

      UIP=$

      {B}_${UNSETVAR}
      VIP=${B}

      _$

      {UNSETVAR}'

      [EnvInject] - Unset 'VIP' variable.
      [EnvInject] - Unset 'TIP' variable.
      [EnvInject] - Unset 'ZIP' variable.
      ----------------------------------------------------------------------

      Problems:
      1) ZIP and TIP get unset even though they are identical to TZP and AIP
      2) UIP does not get unset, even though it has ${UNSETVAR}

      in it which cannot be resolved

      Should consider changing unset feature to optional, as some variables need to have the $ symbol in them,
      which will make it appear as unresolved.

        Attachments

          Activity

            People

            • Assignee:
              gbois Gregory Boissinot
              Reporter:
              pixman20 pixman20
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: