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

"runk/file" (missing 't') paths from getAffectedPaths()

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Cannot Reproduce
    • Icon: Major Major
    • subversion-plugin
    • None

      Given the subversion tree:
      /trunk/
      /trunk/ends_with_t/
      /trunk/foo/
      /trunk/foo/file
      /trunk/file

      And the subversion module configuration
      scheme://.../trunk/foo -> foo
      scheme://.../trunk/ends_with_t -> ends_with_t

      hudson.scm.SubversionChangeLogSet.LogEntry.getAffectedPaths() returns
      runk/file
      file

      This is caused by hudson.scm.SubversionChangeLogSet.LogEntry.preparePath() when it uses all of the configured module locations to remove the common parts from file paths. "trunk/file" was not part of the change that was added to the filesystem. When findCommonParts( "trunk/ends_with_t", "trunk/file" ) is called, it returns "t" because that is the common tail of the folder that matches the beginning of the file path. pareparePath then calls substring on the file path with the length of the common part, which removes the "t" from "trunk/file".

            Unassigned Unassigned
            krwalker krwalker
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: