Bug 737817 - putproject,putversion,putuser have property names inconsistent with their config parameter names
putproject,putversion,putuser have property names inconsistent with their con...
Status: CLOSED CURRENTRELEASE
Product: Zanata
Classification: Community
Component: Component-Maven, Usability (Show other bugs)
1.4-RC
Unspecified Unspecified
unspecified Severity unspecified
: ---
: ---
Assigned To: Runa Bhattacharjee
Ding-Yi Chen
: Reopened
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2011-09-13 03:36 EDT by Ding-Yi Chen
Modified: 2013-03-03 21:21 EST (History)
5 users (show)

See Also:
Fixed In Version: 1.4-SNAPSHOT (20110915-1852)
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2011-10-28 04:12:21 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:


Attachments (Terms of Use)

  None (edit)
Description Ding-Yi Chen 2011-09-13 03:36:25 EDT
Description of problem:
According to Zanata plugin documentation (https://zanata.ci.cloudbees.com/job/zanata-site/site/zanata-maven-plugin/putversion-mojo.html)

versionProject and versionSlug are valid and required parameters.
However, specifying these parameters do not actually works.

Version-Release number of selected component (if applicable):


How reproducible:
Always

Steps to Reproduce:
1. Assume project "AboutFedora" exists in zanata server.


2. Assume zanata.ini has following line:

zanata_1_4_auto.url=http://zanata.server.com/
zanata_1_4_auto.username=admin
zanata_1_4_auto.key=b6d7044e9ee3b2447c28fb7c50d86d98


3. mvn -e zanata:putversion  -Dzanata.project.type=podir  -Dzanata.versionProject=AboutFedora -Dzanata.versionSlug=f13


  
Actual results:
[ERROR] Failed to execute goal org.zanata:zanata-maven-plugin:1.4-SNAPSHOT:putversion (default-cli) on project null: The parameters 'versionProject', 'versionSlug' for goal org.zanata:zanata-maven-plugin:1.4-SNAPSHOT:putversion are missing or invalid -> [Help 1]

org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal org.zanata:zanata-maven-plugin:1.4-SNAPSHOT:putversion (default-cli) on project null: The parameters 'versionProject', 'versionSlug' for goal org.zanata:zanata-maven-plugin:1.4-SNAPSHOT:putversion are missing or invalid



Expected results:
Version "f13" is created for project "AboutFedora"

Additional info:
Parameters which actually work are:
-Dzanata.version.slug=f13 
-Dzanata.version.project=AboutFedora
Comment 1 Sean Flanigan 2011-09-13 03:42:55 EDT
According to:
https://zanata.ci.cloudbees.com/job/zanata-site/site/zanata-maven-plugin/putversion-mojo.html#versionProject

the system property ("expression") for the configuration parameter "versionProject" is "zanata.version.project".  Similarly for versionSlug.
Comment 2 Ding-Yi Chen 2011-09-13 21:16:01 EDT
(In reply to comment #1)
> According to:
> https://zanata.ci.cloudbees.com/job/zanata-site/site/zanata-maven-plugin/putversion-mojo.html#versionProject
> 
> the system property ("expression") for the configuration parameter
> "versionProject" is "zanata.version.project".  Similarly for versionSlug.

Which is inconsistent with other parameters of other goals, such as projectConfig, userConfig, and projectType.
Comment 3 David Mason 2011-09-13 21:32:42 EDT
This is related to the trouble I was having with mvn zanata:putproject. There was no way to determine from the error messages or usage information how to specify these properties.
Comment 4 Sean Flanigan 2011-09-13 21:45:59 EDT
> Which is inconsistent with other parameters of other goals, such as
projectConfig, userConfig, and projectType.

Yes, true.  I can break backward compatibility if you like.  I'm pretty sure no-one but us uses these options.

But if I change it in master only (1.5), your test scripts will need to be different between 1.4 and 1.5.


> This is related to the trouble I was having with mvn zanata:putproject. There
was no way to determine from the error messages or usage information how to
specify these properties.

That's just Maven for you.  It only appears in the generated site docs, not the stdout usage.

But making it consistent with the other goals would probably help.
Comment 5 Sean Flanigan 2011-09-13 23:34:10 EDT
Okay, the goals putproject, putversion and putuser now use the same naming conventions for property names (compared to the config param names) as all the other goals: if the param name is "abcXyz", the property name is "zanata.abcXyz". eg -Dzanata.abcXyz=foo

This is in 1.4 and master.  https://github.com/zanata/zanata/commit/fdf3c6f94100be1ec859df2677f8ad8a5d9ac61a
Comment 6 Ding-Yi Chen 2011-09-13 23:58:46 EDT
Test system changed accordingly, will verify it once the REST tests pass.
Comment 7 Ding-Yi Chen 2011-09-19 00:28:52 EDT
VERIFIED with Zanata version 1.4-SNAPSHOT (20110915-1852).

Note You need to log in before you can comment on or make changes to this bug.