You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@forrest.apache.org by Ron Blaschke <ma...@rblasch.org> on 2005/06/16 23:12:33 UTC

[Testing 0.7rc1] Calling site from ant may not download plugin

Ross: simplifiedDocbook worked ok, the page rendered nicely.  Thanks!


There are two other things I'd like to mention

0.7/docs/your-project.html says

    <property environment="env"/>
    <property name="forrest.home" value="${env.FORREST_HOME}"/>
    <import file="${env.FORREST_HOME}/forrest.build.xml"/>

but forrest.build.xml is in directory main, so I guess it should read

    <import file="${env.FORREST_HOME}/main/forrest.build.xml"/>

Another problem seems to be fetching the plugin, when calling
from within ant.

...
check-java-version:
This is apache-forrest-0.7-dev
Using Java 1.4 from C:\Program Files\Java\jdk1.4.2\jre
...
check-plugin:
org.apache.forrest.plugin.input.projectInfo is not available in the build dir

ERROR
=====

Unable to retrieve the ${plugin.name} plugin.
...

Two noteworthy things: Calling "forrest init-plugins" installs the
plugin sucessfully.  And the error message says "${plugin.name}",
instead of the real name of the plugin.

Calling the site target from within ant works fine, once the plugins
are installed.

Anyone else seeing this?  Anything wrong on my side?

Almost forgot to mention my box:
Windows XP, SP2
JRE 1.4.2
Ant 1.6.5

Ron


Re: [Testing 0.7rc1] Calling site from ant may not download plugin

Posted by Ron Blaschke <ma...@rblasch.org>.
Friday, June 17, 2005, 11:01:40 PM, Ross Gardler wrote:
> Ron Blaschke wrote:
>> Friday, June 17, 2005, 11:54:47 AM, Ross Gardler wrote:

>> My forrest.properties says this:
>> project.required.plugins=org.apache.forrest.plugin.input.projectInfo,
>> org.apache.forrest.plugin.input.simplifiedDocbook

> I assume you get the same behaviour with simplifiedDocbook?

Yes.  Actually, this is how I found out about this, as projectInfo was
already installed, but I needed simplifiedDocbook, too (remember the
simplified-docbook issue).

> You certainly found what looks like a bug. Please do raise an issue and
> link it to this thread in the archives, you have provided some useful
> info here.

Done.

I'll try to find out some more about this problem.

Ron


Re: [Testing 0.7rc1] Calling site from ant may not download plugin

Posted by Ross Gardler <rg...@apache.org>.
Ron Blaschke wrote:
> Friday, June 17, 2005, 11:54:47 AM, Ross Gardler wrote:
> 
>>Ron Blaschke wrote:
>>
>>>Unable to retrieve the ${plugin.name} plugin.
>>>
>>>Two noteworthy things: Calling "forrest init-plugins" installs the
>>>plugin sucessfully.  And the error message says "${plugin.name}",
>>>instead of the real name of the plugin.
> 
> 
>>The two things are related. It looks like that the {plugin.name} is not
>>being set for some reason (and I guess {versioned.name} is not set either.
> 
> 
>>These are set in the init-plugins target of targets/plugins.xml
> 
> 
> I ran my build.xml with "ant -d," and found the following:
> 
>   Setting ro project property: plugin.name -> ${plugin.name}
>   Setting ro project property: plugin.version -> ${plugin.version}
>   Setting ro project property: versioned.name ->
> org.apache.forrest.plugin.input.projectInfo

Actually that is as expected. The {plugin.name} and {plugin.version} 
values are set by a regexp looking for the the version number. Since 
there is no version number in the plugin required the regexp fails and 
so no value for the property. The rest of the script tries to get the 
{versioned.name} plugin. If it fails it falls back to the unversioned 
plugin.

This explains why the error message shows ${plugin.name}, I've changed 
that to use the {versioned.name} so at least it will give a more 
meaningful error.

> "forrest -d" says:
> 
>   Setting ro project property: plugin.name ->
> org.apache.forrest.plugin.input.projectInfo
>   Setting ro project property: plugin.version ->
>   Setting ro project property: versioned.name ->
> org.apache.forrest.plugin.input.projectInfo

This I don't understand. The bechaviour should be the same as above. The 
relevant portion of the ANT script is at line 337 of targets/plugins.xml


> My forrest.properties says this:
> 
>   project.required.plugins=org.apache.forrest.plugin.input.projectInfo,
> org.apache.forrest.plugin.input.simplifiedDocbook

I assume you get the same behaviour with simplifiedDocbook?

> Out of curiosity, I added the plugin version.
> 
>   project.required.plugins=org.apache.forrest.plugin.input.projectInfo-0.1,
> org.apache.forrest.plugin.input.simplifiedDocbook
> 
> The debug trace of my build.xml changes to the following, and the
> plugin is successfully installed.
> 
>   Setting ro project property: plugin.name ->
> org.apache.forrest.plugin.input.projectInfo
>   Setting ro project property: plugin.version -> 0.1
>   Setting ro project property: versioned.name ->
> org.apache.forrest.plugin.input.projectInfo-0.1

This looks like the behaviour expected.

>>I have no idea why this is happening and don't have the time to explore
>>this just yet. I can't raise an issue either since the issue tracker is
>>down right now.
> 
> 
> I hope it's alright for everyone that I am thinking out loud here.  If
> not, please tell me so.

We certainly don;t mind you helping debug the problem. Every step you 
take like the above is one less step other devs have to take in 
debugging. We are *very* grateful for your thoughts.

Furthermore, our conversation here goes in the archives and helps people 
debuging similar stuff in the future.

> If you think that I really found a bug, and not just made a stupid
> mistake, I'll gladly create an issue myself, and try to help resolving
> it.

You certainly found what looks like a bug. Please do raise an issue and 
link it to this thread in the archives, you have provided some useful 
info here.

We are only an hour from the second release build so I'll add a warning 
and a workaround in the docs for this.

Ross

Re: [Testing 0.7rc1] Calling site from ant may not download plugin

Posted by Ron Blaschke <ma...@rblasch.org>.
Friday, June 17, 2005, 11:54:47 AM, Ross Gardler wrote:
> Ron Blaschke wrote:
>> Unable to retrieve the ${plugin.name} plugin.
>>
>> Two noteworthy things: Calling "forrest init-plugins" installs the
>> plugin sucessfully.  And the error message says "${plugin.name}",
>> instead of the real name of the plugin.

> The two things are related. It looks like that the {plugin.name} is not
> being set for some reason (and I guess {versioned.name} is not set either.

> These are set in the init-plugins target of targets/plugins.xml

I ran my build.xml with "ant -d," and found the following:

  Setting ro project property: plugin.name -> ${plugin.name}
  Setting ro project property: plugin.version -> ${plugin.version}
  Setting ro project property: versioned.name ->
org.apache.forrest.plugin.input.projectInfo

"forrest -d" says:

  Setting ro project property: plugin.name ->
org.apache.forrest.plugin.input.projectInfo
  Setting ro project property: plugin.version ->
  Setting ro project property: versioned.name ->
org.apache.forrest.plugin.input.projectInfo

My forrest.properties says this:

  project.required.plugins=org.apache.forrest.plugin.input.projectInfo,
org.apache.forrest.plugin.input.simplifiedDocbook

Out of curiosity, I added the plugin version.

  project.required.plugins=org.apache.forrest.plugin.input.projectInfo-0.1,
org.apache.forrest.plugin.input.simplifiedDocbook

The debug trace of my build.xml changes to the following, and the
plugin is successfully installed.

  Setting ro project property: plugin.name ->
org.apache.forrest.plugin.input.projectInfo
  Setting ro project property: plugin.version -> 0.1
  Setting ro project property: versioned.name ->
org.apache.forrest.plugin.input.projectInfo-0.1

> I have no idea why this is happening and don't have the time to explore
> this just yet. I can't raise an issue either since the issue tracker is
> down right now.

I hope it's alright for everyone that I am thinking out loud here.  If
not, please tell me so.

If you think that I really found a bug, and not just made a stupid
mistake, I'll gladly create an issue myself, and try to help resolving
it.

> If we don't get time to fix this before the release I suggest adding a
> warning to the your-project.html in the instructions for using Forrest
> via Ant (i.e. you must manually install the plugins for it to work).

Yup, this will be fine.

Ron











Re: [Testing 0.7rc1] Calling site from ant may not download plugin

Posted by Ross Gardler <rg...@apache.org>.
Ron Blaschke wrote:
> Ross: simplifiedDocbook worked ok, the page rendered nicely.  Thanks!
> 
> 
> There are two other things I'd like to mention
> 
> 0.7/docs/your-project.html says
> 
>     <property environment="env"/>
>     <property name="forrest.home" value="${env.FORREST_HOME}"/>
>     <import file="${env.FORREST_HOME}/forrest.build.xml"/>
> 
> but forrest.build.xml is in directory main, so I guess it should read
> 
>     <import file="${env.FORREST_HOME}/main/forrest.build.xml"/>

Correct - fixed - thanks.

> Another problem seems to be fetching the plugin, when calling
> from within ant.
> 
> ...
> check-java-version:
> This is apache-forrest-0.7-dev
> Using Java 1.4 from C:\Program Files\Java\jdk1.4.2\jre
> ...
> check-plugin:
> org.apache.forrest.plugin.input.projectInfo is not available in the build dir
> 
> ERROR
> =====
> 
> Unable to retrieve the ${plugin.name} plugin.
> ...
> 
> Two noteworthy things: Calling "forrest init-plugins" installs the
> plugin sucessfully.  And the error message says "${plugin.name}",
> instead of the real name of the plugin.

The two things are related. It looks like that the {plugin.name} is not 
being set for some reason (and I guess {versioned.name} is not set either.

These are set in the init-plugins target of targets/plugins.xml

I have no idea why this is happening and don't have the time to explore 
this just yet. I can't raise an issue either since the issue tracker is 
down right now.

If we don't get time to fix this before the release I suggest adding a 
warning to the your-project.html in the instructions for using Forrest 
via Ant (i.e. you must manually install the plugins for it to work).

Thanks for spotting this one.

Ross