Bug 6071 - Duplicate "crossref" plugins create conflicts
Duplicate "crossref" plugins create conflicts
Status: RESOLVED FIXED
Product: OJS
Classification: Unclassified
Component: Plug-ins
2.3.x
PC Linux
: P5 enhancement
Assigned To: jerico
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2010-10-26 12:19 PDT by Alec Smecher
Modified: 2011-02-09 16:34 PST (History)
2 users (show)

See Also:
Version Reported In:
Also Affects:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Alec Smecher 2010-10-26 12:19:49 PDT
There are several plugins named "crossref" in their version.xml descriptors. This will cause conflicts, i.e. the addPluginVersions code in classes/install/Upgrade.inc.php doesn't appear to discriminate based on category. Running addPluginVersions causes the following message to appear:

You are trying to downgrade the product "crossref" from version [1.1.0.0] to version [1.0.0.0]. Downgrades are not supported.
Comment 1 Alec Smecher 2010-10-26 12:21:18 PDT
Florian, a potentially related problem: now that OJS 2.3.3 is out, running tools/upgrade.php will no longer trigger addPluginVersions to be executed. AFAIK, this leaves us without a way to get new plugins entered into the versions table.
Comment 2 jerico 2010-10-29 04:32:01 PDT
The addPluginVersions() problem has been reported in bug #6076. See there. The duplicate crossref version entries problem will be solved here.
Comment 3 jerico 2010-10-29 10:23:17 PDT
I think it's not necessary to have unique product (=plug-in) names across all categories as we include the category name in the plug-in class and therefore shouldn't get duplicate class names. Do you see any problem with having the same plug-in name in two different categories? If not, I'll change VersionDAO to check the category name also.
Comment 4 Alec Smecher 2010-10-29 10:38:12 PDT
Florian, that sounds fine to me.
Comment 7 jerico 2010-11-06 16:46:51 PDT
And one in lib-pkp also https://github.com/pkp/pkp-lib/commit/0e874bb4b5d76b5db8ab5cf4f622f51b19c2ed9f