You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@maven.apache.org by Mark Struberg <st...@yahoo.de> on 2011/07/29 16:22:46 UTC

broken test in maven-javadoc-plugin

Hi!

This is a sum-up of my last 5 hours of debugging.

Currently there is a failing test in the maven-javadoc-plugin: JavadocReportTest#testProxy()

This test fails since the last commit but I actually think it only ever worked by accident. It did rely on a commons-logging-1.0.4.pom which got resolved by a test which did run previously.
But after updating to commons-logging.1.1.1 there is no pre-resolved artifact available in target/local-repo anymore, thus the javadoc link info cannot get built and the test fails in line 829:
> assertTrue( optionsContent.contains( "-link 'http://commons.apache.org/logging/apidocs'" ) );

I'll for now just disable this line of code, because the test as far as I can see _never_ did go upstream. The remoteRepository list used is always empty!.

If anyone has an idea how to get this fixed properly, then please speak up ;)

LieGrue,
strug 





---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org


RE: broken test in maven-javadoc-plugin

Posted by Mark Struberg <st...@yahoo.de>.
Heh Robert, thanks for sharing ;)
I actually was not 100% sure, so it took me a bit time to really understand what this thing might be supposed to do. And that it was actually only working by accident so far.

LieGrue,
strub

--- On Fri, 7/29/11, Robert Scholte <rf...@codehaus.org> wrote:

> From: Robert Scholte <rf...@codehaus.org>
> Subject: RE: broken test in maven-javadoc-plugin
> To: dev@maven.apache.org
> Date: Friday, July 29, 2011, 4:57 PM
> 
> I discovered the same issue. The problem didn't show itself
> with a dirty target-folder, but after a "mvn clean test" it
> was easy to reproduce.I noticed the test had to do with the
> proxy, couldn't figure out how this test should work. Now I
> know: it doesn't. -Robert > Date: Fri, 29 Jul 2011
> 15:22:46 +0100
> > From: struberg@yahoo.de
> > Subject: broken test in maven-javadoc-plugin
> > To: dev@maven.apache.org
> > 
> > Hi!
> > 
> > This is a sum-up of my last 5 hours of debugging.
> > 
> > Currently there is a failing test in the
> maven-javadoc-plugin: JavadocReportTest#testProxy()
> > 
> > This test fails since the last commit but I actually
> think it only ever worked by accident. It did rely on a
> commons-logging-1.0.4.pom which got resolved by a test which
> did run previously.
> > But after updating to commons-logging.1.1.1 there is
> no pre-resolved artifact available in target/local-repo
> anymore, thus the javadoc link info cannot get built and the
> test fails in line 829:
> > > assertTrue( optionsContent.contains( "-link 'http://commons.apache.org/logging/apidocs'" ) );
> > 
> > I'll for now just disable this line of code, because
> the test as far as I can see _never_ did go upstream. The
> remoteRepository list used is always empty!.
> > 
> > If anyone has an idea how to get this fixed properly,
> then please speak up ;)
> > 
> > LieGrue,
> > strug 
> > 
> > 
> > 
> > 
> > 
> >
> ---------------------------------------------------------------------
> > To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
> > For additional commands, e-mail: dev-help@maven.apache.org
> > 
>     
>         
>           
>   

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org


RE: broken test in maven-javadoc-plugin

Posted by Robert Scholte <rf...@codehaus.org>.
I discovered the same issue. The problem didn't show itself with a dirty target-folder, but after a "mvn clean test" it was easy to reproduce.I noticed the test had to do with the proxy, couldn't figure out how this test should work. Now I know: it doesn't. -Robert > Date: Fri, 29 Jul 2011 15:22:46 +0100
> From: struberg@yahoo.de
> Subject: broken test in maven-javadoc-plugin
> To: dev@maven.apache.org
> 
> Hi!
> 
> This is a sum-up of my last 5 hours of debugging.
> 
> Currently there is a failing test in the maven-javadoc-plugin: JavadocReportTest#testProxy()
> 
> This test fails since the last commit but I actually think it only ever worked by accident. It did rely on a commons-logging-1.0.4.pom which got resolved by a test which did run previously.
> But after updating to commons-logging.1.1.1 there is no pre-resolved artifact available in target/local-repo anymore, thus the javadoc link info cannot get built and the test fails in line 829:
> > assertTrue( optionsContent.contains( "-link 'http://commons.apache.org/logging/apidocs'" ) );
> 
> I'll for now just disable this line of code, because the test as far as I can see _never_ did go upstream. The remoteRepository list used is always empty!.
> 
> If anyone has an idea how to get this fixed properly, then please speak up ;)
> 
> LieGrue,
> strug 
> 
> 
> 
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
> For additional commands, e-mail: dev-help@maven.apache.org
> 
 		 	   		  

Re: broken test in maven-javadoc-plugin

Posted by Hervé BOUTEMY <he...@free.fr>.
yes, I tried too and couldn't find (then chose to continue on m-site-p...), but 
your conclusion is really plausible

I tried on every CI failures, fixed what I could fix, but actual failures are 
really hard to fix (AFAIK, were the same on previous Sonatype's CI, then there 
is really some logic in them, not only bad specific configuration): thanks for 
your work and sharing

once the CI will be fully ok, we'll have to celebrate!
:)

Regards,

Hervé

Le vendredi 29 juillet 2011, Dennis Lundberg a écrit :
> Hi Mark
> 
> I spent a couple of hours debugging this earlier this week.
> Unfortunately I wasn't able to crack it. But I find your conclusion very
> plausible.
> 
> On 2011-07-29 16:22, Mark Struberg wrote:
> > Hi!
> > 
> > This is a sum-up of my last 5 hours of debugging.
> > 
> > Currently there is a failing test in the maven-javadoc-plugin:
> > JavadocReportTest#testProxy()
> > 
> > This test fails since the last commit but I actually think it only ever
> > worked by accident. It did rely on a commons-logging-1.0.4.pom which got
> > resolved by a test which did run previously.
> > 
> > But after updating to commons-logging.1.1.1 there is no pre-resolved 
artifact available in target/local-repo anymore, thus the javadoc link info 
cannot get built and the test fails in line 829:
> >> assertTrue( optionsContent.contains( "-link
> >> 'http://commons.apache.org/logging/apidocs'" ) );
> > 
> > I'll for now just disable this line of code, because the test as far as I
> > can see _never_ did go upstream. The remoteRepository list used is
> > always empty!.
> > 
> > If anyone has an idea how to get this fixed properly, then please speak
> > up ;)
> > 
> > LieGrue,
> > strug
> > 
> > 
> > 
> > 
> > 
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
> > For additional commands, e-mail: dev-help@maven.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org


Re: broken test in maven-javadoc-plugin

Posted by Dennis Lundberg <de...@apache.org>.
On 2011-07-30 00:13, Mark Struberg wrote:
> Hi Dennis!
> 
> I think we could test this if we start a local jetty serving as a repo http server which only provides one dummy artifact. Then we need to startup a proxy and point maven to this proxy.
> 
> Sounds like a bit more work, and I'd rather do that in an integration test and not via a unit test.

Yup, that's the way to go. I found the tests overly complicated for
being just unit tests.

> 
> LieGrue,
> strub 
> 
> --- On Fri, 7/29/11, Dennis Lundberg <de...@apache.org> wrote:
> 
>> From: Dennis Lundberg <de...@apache.org>
>> Subject: Re: broken test in maven-javadoc-plugin
>> To: "Maven Developers List" <de...@maven.apache.org>
>> Date: Friday, July 29, 2011, 9:59 PM
>> Hi Mark
>>
>> I spent a couple of hours debugging this earlier this
>> week.
>> Unfortunately I wasn't able to crack it. But I find your
>> conclusion very
>> plausible.
>>
>> On 2011-07-29 16:22, Mark Struberg wrote:
>>> Hi!
>>>
>>> This is a sum-up of my last 5 hours of debugging.
>>>
>>> Currently there is a failing test in the
>> maven-javadoc-plugin: JavadocReportTest#testProxy()
>>>
>>> This test fails since the last commit but I actually
>> think it only ever worked by accident. It did rely on a
>> commons-logging-1.0.4.pom which got resolved by a test which
>> did run previously.
>>> But after updating to commons-logging.1.1.1 there is
>> no pre-resolved artifact available in target/local-repo
>> anymore, thus the javadoc link info cannot get built and the
>> test fails in line 829:
>>>> assertTrue( optionsContent.contains( "-link 'http://commons.apache.org/logging/apidocs'" ) );
>>>
>>> I'll for now just disable this line of code, because
>> the test as far as I can see _never_ did go upstream. The
>> remoteRepository list used is always empty!.
>>>
>>> If anyone has an idea how to get this fixed properly,
>> then please speak up ;)
>>>
>>> LieGrue,
>>> strug 
>>>
>>>
>>>
>>>
>>>
>>>
>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
>>> For additional commands, e-mail: dev-help@maven.apache.org
>>>
>>>
>>
>>
>> -- 
>> Dennis Lundberg
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
>> For additional commands, e-mail: dev-help@maven.apache.org
>>
>>
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
> For additional commands, e-mail: dev-help@maven.apache.org
> 
> 


-- 
Dennis Lundberg

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org


Re: broken test in maven-javadoc-plugin

Posted by Mark Struberg <st...@yahoo.de>.
Hi Dennis!

I think we could test this if we start a local jetty serving as a repo http server which only provides one dummy artifact. Then we need to startup a proxy and point maven to this proxy.

Sounds like a bit more work, and I'd rather do that in an integration test and not via a unit test.

LieGrue,
strub 

--- On Fri, 7/29/11, Dennis Lundberg <de...@apache.org> wrote:

> From: Dennis Lundberg <de...@apache.org>
> Subject: Re: broken test in maven-javadoc-plugin
> To: "Maven Developers List" <de...@maven.apache.org>
> Date: Friday, July 29, 2011, 9:59 PM
> Hi Mark
> 
> I spent a couple of hours debugging this earlier this
> week.
> Unfortunately I wasn't able to crack it. But I find your
> conclusion very
> plausible.
> 
> On 2011-07-29 16:22, Mark Struberg wrote:
> > Hi!
> > 
> > This is a sum-up of my last 5 hours of debugging.
> > 
> > Currently there is a failing test in the
> maven-javadoc-plugin: JavadocReportTest#testProxy()
> > 
> > This test fails since the last commit but I actually
> think it only ever worked by accident. It did rely on a
> commons-logging-1.0.4.pom which got resolved by a test which
> did run previously.
> > But after updating to commons-logging.1.1.1 there is
> no pre-resolved artifact available in target/local-repo
> anymore, thus the javadoc link info cannot get built and the
> test fails in line 829:
> >> assertTrue( optionsContent.contains( "-link 'http://commons.apache.org/logging/apidocs'" ) );
> > 
> > I'll for now just disable this line of code, because
> the test as far as I can see _never_ did go upstream. The
> remoteRepository list used is always empty!.
> > 
> > If anyone has an idea how to get this fixed properly,
> then please speak up ;)
> > 
> > LieGrue,
> > strug 
> > 
> > 
> > 
> > 
> > 
> >
> ---------------------------------------------------------------------
> > To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
> > For additional commands, e-mail: dev-help@maven.apache.org
> > 
> > 
> 
> 
> -- 
> Dennis Lundberg
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
> For additional commands, e-mail: dev-help@maven.apache.org
> 
> 

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org


Re: broken test in maven-javadoc-plugin

Posted by Dennis Lundberg <de...@apache.org>.
Hi Mark

I spent a couple of hours debugging this earlier this week.
Unfortunately I wasn't able to crack it. But I find your conclusion very
plausible.

On 2011-07-29 16:22, Mark Struberg wrote:
> Hi!
> 
> This is a sum-up of my last 5 hours of debugging.
> 
> Currently there is a failing test in the maven-javadoc-plugin: JavadocReportTest#testProxy()
> 
> This test fails since the last commit but I actually think it only ever worked by accident. It did rely on a commons-logging-1.0.4.pom which got resolved by a test which did run previously.
> But after updating to commons-logging.1.1.1 there is no pre-resolved artifact available in target/local-repo anymore, thus the javadoc link info cannot get built and the test fails in line 829:
>> assertTrue( optionsContent.contains( "-link 'http://commons.apache.org/logging/apidocs'" ) );
> 
> I'll for now just disable this line of code, because the test as far as I can see _never_ did go upstream. The remoteRepository list used is always empty!.
> 
> If anyone has an idea how to get this fixed properly, then please speak up ;)
> 
> LieGrue,
> strug 
> 
> 
> 
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
> For additional commands, e-mail: dev-help@maven.apache.org
> 
> 


-- 
Dennis Lundberg

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org


Re: broken test in maven-javadoc-plugin

Posted by Mark Struberg <st...@yahoo.de>.
Hi!

Thanks for the info.
I'll take the latest ALv2 licensed version of Aether and try to tinker a fix. But this will only happen next week since I'm now off to the country with my family.

LieGrue,
strub

--- On Sat, 7/30/11, Mark Derricutt <ma...@talios.com> wrote:

> From: Mark Derricutt <ma...@talios.com>
> Subject: Re: broken test in maven-javadoc-plugin
> To: "Maven Developers List" <de...@maven.apache.org>
> Date: Saturday, July 30, 2011, 7:22 AM
> This sounds VERY much like the
> problem Richard Vowles reported awhile back which is solved
> by ungrading Maven to use Aether 1.12.
> 
> The problem lies in having some artifcts downloaded
> directly, some from a mirror.  Maven generates a
> metadata file which includes a references to the upstream
> repository id used originally to fetch the artifact, and
> when you run a project that doesn't match that - the
> artifact gets reported as not being found - even if it
> is.  ( at least, thats my simple summation ).
> 
> http://jira.codehaus.org/browse/MNG-5084
> was the ticket that Richard raised.
> 
> Sadly it looks like no one on the Apache team has responded
> to either Richard or my queries about this problem, tho I
> did discover that Aether 1.12 actually fixes the problem -
> unfortunately due to the EPL license change ( see other
> threads ) I'm not sure when we will see this fixed.
> 
> Jason van Zyl has made available a distro/packaging of
> maven with additional fixes ( see his thread about that for
> details ) , including this Aether release - I wonder if you
> could try that and see if this solves the problem you're
> seeing?
> 
> 
> On 30/07/2011, at 2:22 AM, Mark Struberg wrote:
> 
> > This test fails since the last commit but I actually
> think it only ever worked by accident. It did rely on a
> commons-logging-1.0.4.pom which got resolved by a test which
> did run previously.
> > But after updating to commons-logging.1.1.1 there is
> no pre-resolved artifact available in target/local-repo
> anymore, thus the javadoc link info cannot get built and the
> test fails in line 829:
> >> assertTrue( optionsContent.contains( "-link 'http://commons.apache.org/logging/apidocs'" ) );
> > 
> 
> 

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org


Re: broken test in maven-javadoc-plugin

Posted by Mark Derricutt <ma...@talios.com>.
This sounds VERY much like the problem Richard Vowles reported awhile back which is solved by ungrading Maven to use Aether 1.12.

The problem lies in having some artifcts downloaded directly, some from a mirror.  Maven generates a metadata file which includes a references to the upstream repository id used originally to fetch the artifact, and when you run a project that doesn't match that - the artifact gets reported as not being found - even if it is.  ( at least, thats my simple summation ).

http://jira.codehaus.org/browse/MNG-5084 was the ticket that Richard raised.

Sadly it looks like no one on the Apache team has responded to either Richard or my queries about this problem, tho I did discover that Aether 1.12 actually fixes the problem - unfortunately due to the EPL license change ( see other threads ) I'm not sure when we will see this fixed.

Jason van Zyl has made available a distro/packaging of maven with additional fixes ( see his thread about that for details ) , including this Aether release - I wonder if you could try that and see if this solves the problem you're seeing?


On 30/07/2011, at 2:22 AM, Mark Struberg wrote:

> This test fails since the last commit but I actually think it only ever worked by accident. It did rely on a commons-logging-1.0.4.pom which got resolved by a test which did run previously.
> But after updating to commons-logging.1.1.1 there is no pre-resolved artifact available in target/local-repo anymore, thus the javadoc link info cannot get built and the test fails in line 829:
>> assertTrue( optionsContent.contains( "-link 'http://commons.apache.org/logging/apidocs'" ) );
>