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

Code duplication pairs not correcty mapped. A in B is correctly shown, but B in A stays empty. Simian

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Resolved (View Workflow)
    • Priority: Major
    • Resolution: Fixed
    • Component/s: dry-plugin
    • Labels:
      None
    • Similar Issues:

      Description

      I'm using the DRY plugin to display duplicated code found with Simian.

      The overview of all found code duplication pairs is working correctly (see 1).
      The first occurrence of a code duplication pair A - B is correctly displayed (see 2) however the second occurrence (see 3) B - A is empty.

      Solutions:
      1. Either file B should be completely removed from overview "1"
      or
      2. Should correctly display the link to file A

      I checked https://issues.jenkins-ci.org/browse/JENKINS-16688 and it seems to be a similar issue. This is related to "■If a duplication is in two files, then on the left only one file is shown" which I think might be the best solution.

        Attachments

          Issue Links

            Activity

            Hide
            drulli Ulli Hafner added a comment -

            Most likely the same problem.

            Show
            drulli Ulli Hafner added a comment - Most likely the same problem.
            Hide
            scm_issue_link SCM/JIRA link daemon added a comment -

            Code changed in jenkins
            User: Ulli Hafner
            Path:
            clean.sh
            src/main/java/hudson/plugins/dry/parser/DuplicateCode.java
            src/main/java/hudson/plugins/dry/parser/cpd/CpdParser.java
            src/main/java/hudson/plugins/dry/parser/simian/SimianParser.java
            src/main/resources/hudson/plugins/dry/DryTabDetail/dry-details.jelly
            src/main/resources/hudson/plugins/dry/DryTabDetail/dry-warnings.jelly
            src/test/java/hudson/plugins/dry/parser/AbstractDuplicationParserTest.java
            src/test/java/hudson/plugins/dry/parser/cpd/CpdParserTest.java
            src/test/java/hudson/plugins/dry/parser/simian/SimianParserTest.java
            http://jenkins-ci.org/commit/dry-plugin/6b47152e304d65876dda1ae608b0426ef8b32bed
            Log:
            [FIXED JENKINS-17958] Fixed navigation to duplications.

            Show
            scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: Ulli Hafner Path: clean.sh src/main/java/hudson/plugins/dry/parser/DuplicateCode.java src/main/java/hudson/plugins/dry/parser/cpd/CpdParser.java src/main/java/hudson/plugins/dry/parser/simian/SimianParser.java src/main/resources/hudson/plugins/dry/DryTabDetail/dry-details.jelly src/main/resources/hudson/plugins/dry/DryTabDetail/dry-warnings.jelly src/test/java/hudson/plugins/dry/parser/AbstractDuplicationParserTest.java src/test/java/hudson/plugins/dry/parser/cpd/CpdParserTest.java src/test/java/hudson/plugins/dry/parser/simian/SimianParserTest.java http://jenkins-ci.org/commit/dry-plugin/6b47152e304d65876dda1ae608b0426ef8b32bed Log: [FIXED JENKINS-17958] Fixed navigation to duplications.

              People

              • Assignee:
                drulli Ulli Hafner
                Reporter:
                patricks Patrick S
              • Votes:
                0 Vote for this issue
                Watchers:
                2 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: