Maven Verifier Plugin
  1. Maven Verifier Plugin
  2. MVERIFIER-10

Print the absolute path to the input file when verification fails

    Details

    • Type: New Feature New Feature
    • Status: Closed Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 1.1
    • Fix Version/s: 1.1
    • Labels:
      None
    • Number of attachments :
      0

      Description

      While building Tycho, I had this exception: {{org.apache.maven.it.VerificationException: org.xml.sax.SAXException: Invalid
      mavenProfile entry. Missing one or more fields:

      {localRepository}

      .}}

      The error message was useless for me because I have no idea which file caused the error.

        Activity

        Hide
        Aaron Digulla added a comment -

        Here is the complete stack trace:

        org.apache.maven.it.VerificationException: org.xml.sax.SAXException: Invalid
        mavenProfile entry. Missing one or more fields: {localRepository}.
                at org.apache.maven.it.Verifier$UserModelReader.parse(Verifier.java:1917)
                at org.apache.maven.it.Verifier.retrieveLocalRepo(Verifier.java:781)
                at org.apache.maven.it.Verifier.findLocalRepo(Verifier.java:1822)
                at org.apache.maven.it.Verifier.<init>(Verifier.java:150)
                at org.apache.maven.it.Verifier.<init>(Verifier.java:127)
                at org.apache.maven.it.Verifier.<init>(Verifier.java:121)
                at org.apache.maven.it.Verifier.<init>(Verifier.java:176)
                at org.eclipse.tycho.test.AbstractTychoIntegrationTest.getVerifier(AbstractTychoIntegrationTest.java:81)
                at org.eclipse.tycho.test.AbstractTychoIntegrationTest.getVerifier(AbstractTychoIntegrationTest.java:51)
                at org.eclipse.tycho.test.AbstractTychoIntegrationTest.getVerifier(AbstractTychoIntegrationTest.java:109)
        
        Show
        Aaron Digulla added a comment - Here is the complete stack trace: org.apache.maven.it.VerificationException: org.xml.sax.SAXException: Invalid mavenProfile entry. Missing one or more fields: {localRepository}. at org.apache.maven.it.Verifier$UserModelReader.parse(Verifier.java:1917) at org.apache.maven.it.Verifier.retrieveLocalRepo(Verifier.java:781) at org.apache.maven.it.Verifier.findLocalRepo(Verifier.java:1822) at org.apache.maven.it.Verifier.<init>(Verifier.java:150) at org.apache.maven.it.Verifier.<init>(Verifier.java:127) at org.apache.maven.it.Verifier.<init>(Verifier.java:121) at org.apache.maven.it.Verifier.<init>(Verifier.java:176) at org.eclipse.tycho.test.AbstractTychoIntegrationTest.getVerifier(AbstractTychoIntegrationTest.java:81) at org.eclipse.tycho.test.AbstractTychoIntegrationTest.getVerifier(AbstractTychoIntegrationTest.java:51) at org.eclipse.tycho.test.AbstractTychoIntegrationTest.getVerifier(AbstractTychoIntegrationTest.java:109)
        Hide
        Olivier Lamy added a comment -

        fixed r1152710

        Show
        Olivier Lamy added a comment - fixed r1152710
        Hide
        Thomas Broyer added a comment -

        I faced this issue recently with 1.3.

        The problem was that my settings.xml contained an empty <localRepository/> element. A minimal settings.xml that would reproduce the issue would probably be:

        <settings xmlns="http://maven.apache.org/SETTINGS/1.0.0"
          xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
          xsi:schemaLocation="http://maven.apache.org/SETTINGS/1.0.0
                              http://maven.apache.org/xsd/settings-1.0.0.xsd">
        
          <localRepository/>
        </settings>
        

        MVERIFIER, when processing that element (Verifier.java line 1883 in MVERIFIER 1.3) throws a SAXException. It should probably use the default value instead of throwing, as Maven otherwise has no problem with the empty element (and uses the default value).

        Show
        Thomas Broyer added a comment - I faced this issue recently with 1.3. The problem was that my settings.xml contained an empty <localRepository/> element. A minimal settings.xml that would reproduce the issue would probably be: <settings xmlns= "http: //maven.apache.org/SETTINGS/1.0.0" xmlns:xsi= "http: //www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http: //maven.apache.org/SETTINGS/1.0.0 http: //maven.apache.org/xsd/settings-1.0.0.xsd"> <localRepository/> </settings> MVERIFIER, when processing that element ( Verifier.java line 1883 in MVERIFIER 1.3) throws a SAXException . It should probably use the default value instead of throwing, as Maven otherwise has no problem with the empty element (and uses the default value).

          People

          • Assignee:
            Olivier Lamy
            Reporter:
            Aaron Digulla
          • Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: