On Thu, Mar 1, 2012 at 6:25 AM, Svante Schubert <[email protected]> wrote: > On 25.02.2012 13:38, Nick Burch wrote: >> On Fri, 24 Feb 2012, Svante Schubert wrote: >>> I would suggest to do it similar here. Has anybody further >>> information on the issue below. Again the apache-rat-plugin triggered >>> the failure. Similar as in my local build yesterday, but on a >>> different project. >> >> The problem is that someone has added new files, but neglected to add >> the Apache license header to them: >> >>>> mavenExecutionResult exceptions not empty >>>> message : Failed to execute goal >>>> org.apache.rat:apache-rat-plugin:0.7:check (default) on project >>>> odfdom-java: Too many unapproved licenses: 2 >>>> cause : Too many unapproved licenses: 2 >>>> Stack trace : >>>> org.apache.maven.lifecycle.LifecycleExecutionException: Failed to >>>> execute goal org.apache.rat:apache-rat-plugin:0.7:check (default) on >>>> project odfdom-java: Too many unapproved licenses: 2 >> >> The license headers should ideally be added by the person who added >> the file. Could whoever has added new files to svn recently please >> double check that the headers are there, and add them if not? >> >> (To check, run "mvn rat:check" then look for rat.txt files which >> report the state) > RAT seems to have a problem. It worked fine under Ubuntu (nightly build > - detail later), but fails on Windows 7. Reported the problem on the RAT > DEV list - see details here as soon a moderator allow my first mail > (although I had subscribed previously) - > http://mail-archives.apache.org/mod_mbox/incubator-rat-dev/201203.mbox/browser > (I copy the mail below) > > In addition "mvn rat:check" does not work from trunk level. Perhaps the > a maven problem as the ID profile is not activated, but "mvn rat:check > -Ppedantic" does not work, either. > What puzzles me, is that only the CHANGES.txt had to be removed, while > the KEYS text file is fine, although it has no copyright header. Could > not fine any default set in documentation. >
My guess is that RAT may have hard-coded rules about standard Apache release files, like LICENSE and NOTICE and KEYS. CHANGES.txt might not be hard coded. -Rob > > MAIL TO RAT DEV LIST (NOT IN ARCHIVE YET): > =========================================================================================== > Hi guys, > > thank you for your work. It is very helpful to have the RAT Maven plugin > to check the sources. > > Today I stumbled over an anomaly. > > Our nightly build went fine on Ubuntu: > https://builds.apache.org/job/ODFToolkit/28/org.apache.odftoolkit$schema2template/console > > [INFO] Building jar: > /home/jenkins/jenkins-slave/workspace/ODFToolkit/trunk/generator/schema2template/target/schema2template-0.8.9-incubating-SNAPSHOT-javadoc.jar > [INFO] > [INFO] *--- apache-rat-plugin:0.7:check (default) @ schema2template --- > *[INFO] Exclude: src/test/resources/examples/odf/*.ref > [PMD] No report found for mojo check > > > On Windows 7 on the same source revision I got a problem with RAT and a > binary document, which have to explicitly exclude to let the test pass: > > [INFO] --- apache-rat-plugin:0.7:check (default) @ schema2template --- > [INFO] Exclude: src/test/resources/examples/odf/*.ref > [INFO] > ------------------------------------------------------------------------ > [INFO] Reactor Summary: > [INFO] > [INFO] Apache ODF Toolkit ................................ SUCCESS > [2:12.294s] > [INFO] ODF Custom Javadoc Taglets ........................ SUCCESS > [1:32.394s] > [INFO] XML Schema to Template Mapping Tool: Parent POM ... SUCCESS [0.202s] > [INFO] XML Schema to Template Mapping Tool: Library ...... FAILURE > [1:49.980s] > [INFO] XML Schema to Template Mapping Tool: Maven2 Plugin SKIPPED > [INFO] ODFDOM ............................................ SKIPPED > [INFO] ODF XSLT-Runner ................................... SKIPPED > [INFO] ODF XSLT-Runner Ant Task .......................... SKIPPED > [INFO] ODF Validator ..................................... SKIPPED > [INFO] Simple Java API for ODF (Simple ODF) .............. SKIPPED > [INFO] > ------------------------------------------------------------------------ > [INFO] BUILD FAILURE > [INFO] > ------------------------------------------------------------------------ > [INFO] Total time: 5:35.528s > [INFO] Finished at: Thu Mar 01 11:44:17 CET 2012 > [INFO] Final Memory: 37M/334M > [INFO] > ------------------------------------------------------------------------ > [ERROR] Failed to execute goal > org.apache.rat:apache-rat-plugin:0.7:check (default) on project > schema2template: Too many unapproved licenses: 1 -> [Help 1] > > * First how can the nightly build pass and the local build fail? Did we > used different rat-plugins? How can we remove this uncertainty? > To do a test on your own, just check out "svn co -r 1294009 > https://svn.apache.org/repos/asf/incubator/odf/trunk" and run "mvn clean > install -Ppedantic" > > * Second of all would be possible to list the files that did not pass? > It is not obvious from the output, Help 1 the URL that there is a > target/rat.txt. > * Third, perhaps a Maven problem, but if I run a "mvn rat:check" for our > trunk from command line. Perhaps the exclusion is only for the ID > pedantic? How do you solve this problem in your projects? > > Thanks in advance, > Svante > >
