1. wrong property name is created when referenced
project contains spaces in name
(see also issue 42903)
Adam, I realized that this is your bug. The reference ID uses
ProjectInformation.getName() and Javadoc of this method says that
returned name is programmatic name for usage in Ant scripts. It is job
of your project type to return something without spaces.
Check also issue 42732 in which I implemented two methods which you
could use for this.
Adam, see also issue 43364.
I hope ReferenceHelper does appropriate sanity checking of incoming
reference IDs, e.g. from ProjectInformation.getName(), and reacts
appropriately? Should IMHO either create a proper name quietly or log
a proper message. Prefer the former, since ReferenceHelper is
responsible for making its own suitable IDs for subprojects - PI.name
should be used as a hint, but it may be uniquified anyway.
RH can do sanity check of incoming IDs, but is not that useless code
duplicity? The PI.getName is API and says that it must be ID. What you
are suggesting means that nobody should rely on it and create their
own IDs. Then what's the value of PI.getName. I could use directly
displayName and encode an ID from it.
It is trivial change (and I already had that done) to call
PU.getUsablePropertyName, but it seemed to me redundant.
Feel free to log an error message if the PI.name is inappropriate, but
RH should still be more robust against API usage errors.
new revision: 1.10; previous revision: 1.9