jira.codehaus.org

  • Log In Access more options
    • Online Help
    • Keyboard Shortcuts
    • About JIRA
    • JIRA Credits
    • What?s New
  • Dashboards Access more options (Alt+d)
  • Projects Access more options (Alt+p)
  • Issues Access more options (Alt+i)
  • Maven 1.x JCoverage Plugin
  • MPJCOVERAGE-15

FileNotFoundException after project clean goal run.

  • Log In
  • Views
    • XML
    • Word
    • Printable

Details

  • Type: Bug Bug
  • Status: Open Open
  • Priority: Major Major
  • Resolution: Unresolved
  • Affects Version/s: None
  • Fix Version/s: None
  • Labels:
    None
  • Environment:
    Maven 1.0, Java 1.4.2_05, Windows XP

Description

I get a FileNotFoundException running the jcoverage goal after a clean goal has been run. See attached stacktrace.

  • Options
    • Sort By Name
    • Sort By Date
    • Ascending
    • Descending
    • Download All

Attachments

  1. Java Source File
    CoverageReport.java
    13/Sep/05 5:59 PM
    23 kB
    Steve Gudmundson
  2. Hide
    Java Archive File
    maven-jcoverage-plugin-1.0.9-PATCHED-MPJCOVERAGE-15.jar
    13/Sep/05 6:00 PM
    32 kB
    Steve Gudmundson
    1. XML File
      project.xml 6 kB
    2. Text File
      META-INF/LICENSE.txt 11 kB
    3. File
      META-INF/MANIFEST.MF 0.5 kB
    4. Text File
      META-INF/NOTICE.txt 0.1 kB
    5. File
      org/apache/.../jcoveragereport/Clazz.class 3 kB
    6. File
      org/apache/.../ClazzComparator.class 0.9 kB
    7. File
      org/apache/.../Coverage.class 4 kB
    8. File
      org/apache/.../CoverageReport.class 15 kB
    9. File
      org/apache/.../CoverageReportGenerator.class 3 kB
    10. File
      org/apache/.../CoverageUnmarshaller.class 3 kB
    11. File
      org/apache/.../JavaToHtml.class 6 kB
    12. File
      org/apache/.../jcoveragereport/Line.class 0.7 kB
    13. File
      org/apache/.../jcoveragereport/Main.class 0.7 kB
    14. File
      org/apache/.../jcoveragereport/Package.class 3 kB
    15. File
      org/apache/.../PackageComparator.class 1.0 kB
    16. File
      plugin-resources/style.css 2 kB
    17. File
      plugin.jelly 10 kB
    18. File
      plugin.properties 1 kB
    19. File
      project.properties 0.9 kB
    Download Zip
    Show
    Java Archive File
    maven-jcoverage-plugin-1.0.9-PATCHED-MPJCOVERAGE-15.jar
    13/Sep/05 6:00 PM
    32 kB
    Steve Gudmundson
  3. Text File
    stacktrace.txt
    06/Oct/04 6:03 AM
    4 kB
    Ricardo Gladwell

Activity

Ascending order - Click to sort in descending order
  • All
  • Comments
  • Work Log
  • History
  • Activity
Hide
Permalink
Ricardo Gladwell added a comment - 06/Oct/04 6:03 AM

Stack trace of FileNotFoundException.

Show
Ricardo Gladwell added a comment - 06/Oct/04 6:03 AM Stack trace of FileNotFoundException.
Hide
Permalink
Ricardo Gladwell added a comment - 15/Oct/04 5:18 AM

This is caused by an out-of-date jcoverage.ser file. Since this file is not stored in the target directory when it is generated, but in the root of the project it is not deleted during a 'clean' goal and therefore attempts to generate output for deleted files, etc.

Show
Ricardo Gladwell added a comment - 15/Oct/04 5:18 AM This is caused by an out-of-date jcoverage.ser file. Since this file is not stored in the target directory when it is generated, but in the root of the project it is not deleted during a 'clean' goal and therefore attempts to generate output for deleted files, etc.
Hide
Permalink
Steve Gudmundson added a comment - 13/Sep/05 4:26 PM

I am also getting this error. I have found that if I create the full directory path that the FileNotFoundException references then run the goal again, it will work. So the problem seems to be that it is trying to write the file to a directory that has not yet been created. Is anyone working on this? If not maybe I will pop the code open and have a look.

Show
Steve Gudmundson added a comment - 13/Sep/05 4:26 PM I am also getting this error. I have found that if I create the full directory path that the FileNotFoundException references then run the goal again, it will work. So the problem seems to be that it is trying to write the file to a directory that has not yet been created. Is anyone working on this? If not maybe I will pop the code open and have a look.
Hide
Permalink
Steve Gudmundson added a comment - 13/Sep/05 5:58 PM

Here is the fix compared to MAVEN_JCOVERAGE_1_0_9 version of the CoverageReport.java file:

159a160,164
> // BEGIN MPJCOVERAGE-15 FIX //
> String pkgdirname = pkg.getDirectory() + "/";
> File pkgFileDir = new File(dir, pkgdirname);
> pkgFileDir.mkdirs();
> // END MPJCOVERAGE-15 FIX //

http://svn.apache.org/repos/asf/maven/maven-1/plugins/tags/MAVEN_JCOVERAGE_1_0_9/jcoverage/src/main/org/apache/maven/jcoveragereport/CoverageReport.java

Attached is the .class file with this change and a new maven-jcoverage-plugin.jar containing this change.

Show
Steve Gudmundson added a comment - 13/Sep/05 5:58 PM Here is the fix compared to MAVEN_JCOVERAGE_1_0_9 version of the CoverageReport.java file: 159a160,164 > // BEGIN MPJCOVERAGE-15 FIX // > String pkgdirname = pkg.getDirectory() + "/"; > File pkgFileDir = new File(dir, pkgdirname); > pkgFileDir.mkdirs(); > // END MPJCOVERAGE-15 FIX // http://svn.apache.org/repos/asf/maven/maven-1/plugins/tags/MAVEN_JCOVERAGE_1_0_9/jcoverage/src/main/org/apache/maven/jcoveragereport/CoverageReport.java Attached is the .class file with this change and a new maven-jcoverage-plugin.jar containing this change.

People

  • Assignee:
    Unassigned
    Reporter:
    Ricardo Gladwell
Vote (1)
Watch (1)

Dates

  • Created:
    06/Oct/04 6:02 AM
    Updated:
    13/Sep/07 4:29 AM
  • Atlassian JIRA (v5.0.4#731-sha1:3aa7374)
  • Report a problem
  • Powered by a free Atlassian JIRA open source license for Codehaus. Try JIRA - bug tracking software for your team.