-
Notifications
You must be signed in to change notification settings - Fork 86
Description
Describe the bug
When an article is published in Janeway, the system modifies the date_declined and date_complete fields of declined reviews, overwriting them with the article's publication timestamp. This occurs even though the review was declined prior to publication and should retain its original declined date.
Specifically:
The original date_declined timestamp is overwritten with the publication date
The date_complete field (which was correctly NULL for a declined review) is populated with the publication date
This behavior appears to be intentional in the codebase, but it causes loss of accurate review timeline data.
Janeway version
Current version: 1.7.2
Planned upgrade: 1.8 (pending)
Steps to reproduce the behavior:
-
Assign a review to a reviewer for an article (e.g., article ID 3541, reviewer ID 2916)
-
Have the reviewer decline the review through the interface
-
Verify in the database that date_declined is set and date_complete is NULL
-
Publish the article
-
Check the database again - observe that both date_declined and date_complete have been overwritten with the publication timestamp
Detailed example with database states:
table: Review_ReviewAssingment
Initial state after review assignment:
id: 7488
article_id: 3541
reviewer_id: 2916
date_requested: 2025-11-11 09:43:31.005556+01
date_due: 2025-11-18
date_declined: NULL
date_complete: NULL
is_complete: false
decision: NULL
State after reviewer declines (correct behavior):
id: 7488
article_id: 3541
reviewer_id: 2916
date_requested: 2025-11-11 09:43:31.005556+01
date_due: 2025-12-02
date_declined: 2025-11-11 09:46:15.06182+01
date_complete: NULL
is_complete: true
decision: NULL
State after article publication (unexpected behavior):
id: 7488
article_id: 3541
reviewer_id: 2916
date_requested: 2025-11-11 09:43:31.005556+01
date_due: 2025-12-02
date_declined: 2025-11-11 09:40:43.236946+01 ← Changed!
date_complete: 2025-11-11 09:40:43.236946+01 ← Now populated!
date_accepted: NULL
is_complete: true
decision: NULL
Expected behavior
When an article is published, declined reviews should retain their original date_declined timestamp. The date_complete field should remain NULL for declined reviews, as the review was not completed but rather declined.
At most, it might be acceptable to set date_complete (though this would still be unusual for a declined review), but overwriting the date_declined timestamp causes loss of accurate historical data about when the review was actually declined.
Additional context
-
Upon examination of the Janeway codebase, this behavior appears to be intentional in the code logic
-
The issue was also reported on Discord but has not received feedback: https://discord.com/channels/509105368207720449/981461208785887282/1450577506615951583
-
This affects the accuracy of review timeline analytics and historical records