Skip to content

[ENG-9198] Do not show page not found for preprint pending moderation#11567

Merged
adlius merged 5 commits intoCenterForOpenScience:feature/pbs-26-2from
mkovalua:feature/ENG--9198
Feb 4, 2026
Merged

[ENG-9198] Do not show page not found for preprint pending moderation#11567
adlius merged 5 commits intoCenterForOpenScience:feature/pbs-26-2from
mkovalua:feature/ENG--9198

Conversation

@mkovalua
Copy link
Contributor

@mkovalua mkovalua commented Jan 28, 2026

Ticket

Purpose

There is no unified access-control handling for preprints that are pending moderation. The system does not consistently intercept direct access attempts and route non-authorized users to a clear, informative state explaining that the preprint is under moderation.

Introduce a generic static “Preprint Pending Moderation” page that is shown when a preprint is in a pending moderation state and belongs to a provider that requires pre-moderation.

Allowed access:

Contributors on the preprint (all roles: read, write, admin)

Moderators for the specific preprint provider

Restricted access:

Logged-in users who are not contributors

Logged-in users who are not moderators for that provider

Logged-out users

Any general user accessing the preprint via direct URL

Changes

if preprint is pending moderation show it for not contributors/moderators/Logged-out users using /pending-moderation redirection on access (ticket related front end updates CenterForOpenScience/angular-osf#835)

96a5-15e4-48c7-8a79-17ff261adc06.mp4

Side Effects

QE Notes

CE Notes

Documentation

# May raise a permission denied
if check_object_permissions:
self.check_object_permissions(self.request, preprint)

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I believe it's better to leave it where it was in order to not break current behavior

Copy link
Contributor Author

@mkovalua mkovalua Jan 30, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

it is needed to implement the following workflow and behaviour described in the ticket

image

Copy link
Contributor

@ihorsokhanexoft ihorsokhanexoft left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

@adlius adlius changed the base branch from feature/pbs-25-25 to feature/pbs-26-2 February 4, 2026 10:23
@adlius adlius merged commit 41f5d7c into CenterForOpenScience:feature/pbs-26-2 Feb 4, 2026
15 of 16 checks passed
ihorsokhanexoft pushed a commit to ihorsokhanexoft/osf.io that referenced this pull request Feb 16, 2026
…CenterForOpenScience#11567)

* if preprint is pending moderation show it for not contributors/moderators/Logged-out users using /pending-moderation redirection on access

* update testcases to be it compatable with 'This preprint is pending moderation and is not yet publicly available.' logic

* test update

* test update

* test update
Vlad0n20 pushed a commit to Vlad0n20/osf.io that referenced this pull request Feb 16, 2026
…CenterForOpenScience#11567)

* if preprint is pending moderation show it for not contributors/moderators/Logged-out users using /pending-moderation redirection on access

* update testcases to be it compatable with 'This preprint is pending moderation and is not yet publicly available.' logic

* test update

* test update

* test update
ihorsokhanexoft pushed a commit to ihorsokhanexoft/osf.io that referenced this pull request Feb 17, 2026
…CenterForOpenScience#11567)

* if preprint is pending moderation show it for not contributors/moderators/Logged-out users using /pending-moderation redirection on access

* update testcases to be it compatable with 'This preprint is pending moderation and is not yet publicly available.' logic

* test update

* test update

* test update
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

Successfully merging this pull request may close these issues.

3 participants