Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[OJS] Infinite loop in upgrade from 2.4.8.2 to 3.1, failing to skip missing files #2942

Closed
ianthe opened this issue Oct 25, 2017 · 5 comments
Assignees

Comments

@ianthe
Copy link

ianthe commented Oct 25, 2017

When upgrading from 2.4.8.2 to 3.1.0.0, there was an infinite loop when attempting to skip a missing file:

[lacddt@lac-php-test2 tools]$ php upgrade.php check
Code version: 3.1.0.0
Database version: 2.4.8.2
Latest version: 3.1.0.0
Database version is older than code version
Run "upgrade.php upgrade" to update
[lacddt@lac-php-test2 tools]$ php upgrade.php upgrade
[pre-install]
[load: upgrade.xml]
[version: 3.1.0.0]
[code: Installer Installer::syncSeriesAssocType]
[data: dbscripts/xml/upgrade/2.4.0_preupdate_usageStatistics.xml (skipped)]
[data: dbscripts/xml/upgrade/2.4.0_preupdate_usageStatistics2.xml (skipped)]
[code: Installer Installer::removeReviewEntries]
WARNING: Unable to find a match for "1167-4677-1-RV.docx" in "/home/lib/lacddt/hostedjournals/devojs-files//journals/7//articles/1167/". Skipping this file.
WARNING: Unable to find a match for "1167-4677-1-RV.docx" in "/home/lib/lacddt/hostedjournals/devojs-files//journals/7//articles/1167/". Skipping this file.
WARNING: Unable to find a match for "1167-4677-1-RV.docx" in "/home/lib/lacddt/hostedjournals/devojs-files//journals/7//articles/1167/". Skipping this file.
WARNING: Unable to find a match for "1167-4677-1-RV.docx" in "/home/lib/lacddt/hostedjournals/devojs-files//journals/7//articles/1167/". Skipping this file.
WARNING: Unable to find a match for "1167-4677-1-RV.docx" in "/home/lib/lacddt/hostedjournals/devojs-files//journals/7//articles/1167/". Skipping this file.
...

Looking in the files directory the file is missing from the submission folders even though there is an entry for it in the database.

Unfortunately, it seems that the upgrade script is failing to skip the file and keeps trying to.

As a workaround, I created an empty file and placed it in the appropriate submission directory and this let the upgrade continue and complete successfully.

@bozana
Copy link
Collaborator

bozana commented Oct 25, 2017

@ianthe, what comes after those warnings?

@bozana bozana self-assigned this Oct 25, 2017
@bozana
Copy link
Collaborator

bozana commented Oct 25, 2017

Oh I see... It's infinite...

@ianthe
Copy link
Author

ianthe commented Oct 25, 2017

Exactly... it just goes on and on writing out the same error until I cancelled it.

@bozana
Copy link
Collaborator

bozana commented Oct 25, 2017

PRs:
ojs master: pkp/ojs#1635
ojs ojs-stable-3_1_0: pkp/ojs#1636

bozana added a commit to pkp/ojs that referenced this issue Oct 25, 2017
pkp/pkp-lib#2942 fix infinite loop in upgrade if file is missing
bozana added a commit to pkp/ojs that referenced this issue Oct 25, 2017
pkp/pkp-lib#2942 fix infinite loop in upgrade if file is missing
@bozana
Copy link
Collaborator

bozana commented Oct 25, 2017

Everything merged, thus closeing

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants