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

Show path of file with duplicated code

    XMLWordPrintable

Details

    • Improvement
    • Status: Closed (View Workflow)
    • Minor
    • Resolution: Fixed
    • dry-plugin
    • None

    Description

      The path to the source files that contain duplicated source code is not shown. If there are several source files with the same name, but in different locations, there is no way of knowing in which files the duplication occurs.

      The problem becomes apparent when the source files are in the C language and there is no package names associated with the files.

      If there are no package associated with a source file, the path should be presented instead.

      Attachments

        1. cpd.xml
          9 kB
        2. dry.html
          17 kB
        3. dry.png
          dry.png
          42 kB
        4. dry-warnings.xml
          56 kB

        Issue Links

          Activity

            etomhel etomhel added a comment - - edited

            Email discussion with Ullrich Hafner on this problem attached in file dry.html.

            etomhel etomhel added a comment - - edited Email discussion with Ullrich Hafner on this problem attached in file dry.html.

            Code changed in hudson
            User: : drulli
            Path:
            trunk/hudson/plugins/analysis-core/src/main/java/hudson/plugins/analysis/util/model/AbstractAnnotation.java
            trunk/hudson/plugins/analysis-core/src/main/java/hudson/plugins/analysis/util/model/FileAnnotation.java
            trunk/hudson/plugins/dry/clean.sh
            trunk/hudson/plugins/dry/pom.xml
            trunk/hudson/plugins/dry/src/main/java/hudson/plugins/dry/DryPublisher.java
            trunk/hudson/plugins/dry/src/main/java/hudson/plugins/dry/parser/DuplicateCode.java
            trunk/hudson/plugins/dry/src/main/java/hudson/plugins/dry/parser/DuplicationParserRegistry.java
            http://jenkins-ci.org/commit/31723
            Log:
            [FIXED JENKINS-6683] Show links of dry warnings with package name or relative path.

            scm_issue_link SCM/JIRA link daemon added a comment - Code changed in hudson User: : drulli Path: trunk/hudson/plugins/analysis-core/src/main/java/hudson/plugins/analysis/util/model/AbstractAnnotation.java trunk/hudson/plugins/analysis-core/src/main/java/hudson/plugins/analysis/util/model/FileAnnotation.java trunk/hudson/plugins/dry/clean.sh trunk/hudson/plugins/dry/pom.xml trunk/hudson/plugins/dry/src/main/java/hudson/plugins/dry/DryPublisher.java trunk/hudson/plugins/dry/src/main/java/hudson/plugins/dry/parser/DuplicateCode.java trunk/hudson/plugins/dry/src/main/java/hudson/plugins/dry/parser/DuplicationParserRegistry.java http://jenkins-ci.org/commit/31723 Log: [FIXED JENKINS-6683] Show links of dry warnings with package name or relative path.
            drulli Ulli Hafner added a comment -

            Integrated in Hudson Plug-ins (Compile) #10
            [FIXED JENKINS-6683] Show links of dry warnings with package name or relative path.
            [FIXED JENKINS-6683] Show links of dry warnings with package name or relative path.

            drulli Ulli Hafner added a comment - Integrated in Hudson Plug-ins (Compile) #10 [FIXED JENKINS-6683] Show links of dry warnings with package name or relative path. [FIXED JENKINS-6683] Show links of dry warnings with package name or relative path.
            drulli Ulli Hafner added a comment - - edited

            Do you have a local (or test) instance where you could install the new plug-ins (analysis-core and dry) from Hudson Plug-ins (Compile) #10?

            Since I only have Java projects in my test setup it might be good to have a test run with a non Java project before the official release will be out.

            Expected behavior:

            • The duplication links of old builds (recorded with the old plugin) show the full path
            • The duplication links of new builds (recorded with the new plugin) show the relative path (starting from the workspace root)

            Thanks, Ulli

            drulli Ulli Hafner added a comment - - edited Do you have a local (or test) instance where you could install the new plug-ins (analysis-core and dry) from Hudson Plug-ins (Compile) #10 ? Since I only have Java projects in my test setup it might be good to have a test run with a non Java project before the official release will be out. Expected behavior: The duplication links of old builds (recorded with the old plugin) show the full path The duplication links of new builds (recorded with the new plugin) show the relative path (starting from the workspace root) Thanks, Ulli
            etomhel etomhel added a comment -
            • The duplication links of old builds (recorded with the old plugin) show the full path

            Confirmed to work.

            • The duplication links of new builds (recorded with the new plugin) show the relative path (starting from the workspace root)

            Confirmed to work.

            etomhel etomhel added a comment - The duplication links of old builds (recorded with the old plugin) show the full path Confirmed to work. The duplication links of new builds (recorded with the new plugin) show the relative path (starting from the workspace root) Confirmed to work.

            People

              drulli Ulli Hafner
              etomhel etomhel
              Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: