Add a fix for the ETD publication bug #2187
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
The GraduationJob is leaving certain works in a state where they
cannot be viewed after graduation. Attempting to view the ETDs in question
gives the message:
This change adds a test that puts the ETD in the same pregraduation state:
a placeholder pre-graduation-embargo is created
open access before they gradute, but the placeholder embargo does not
get removed
because of the left-over embargo conflicts with the request for open access
The previous code attempted to find an existing pre-graduation embargo and
update the expiration date and visibility.
The fix applied here deletes any embargo applied prior to the student's
graduation. This prevents "open access" ETDs from being published with orphan
embargoes left over from the setps described above. The graduation job applies
embargoes only when a valid embargo request is still in place at graduation.