Page MenuHomePhabricator

Ensure that a user who is partially blocked from creating pages is also blocked from uploading files
Closed, ResolvedPublic1 Estimated Story Points

Description

This task is for meeting the acceptance criterion from T199918: Allow a user to be blocked from creating pages only:

When the 'Creating page' checkbox is selected, the 'Uploading files' checkbox should become selected and disabled. (Uploading a file creates the file page.)

This has been made into a separate task since it involves some design discussion.

A checked and disabled checkbox will not be submitted, so checking and disabling may not be the best idea, since it would involve extra wiring in the backend. This would also need repeating for the API. This wiring code would also be quite ugly, since it would involve more components being aware of the details of which actions are blockable; at the moment this is all handled by (and hidden away in) the BlockActionInfo service.

How about simply adding some inline help text to the 'create' checkbox to warn that it is helpful to check 'upload' too?

Event Timeline

AGueyte set the point value for this task to 2.

I confirm a partially blocked user from creating a new page isn't allowed to upload files.
I have created a partial block against a Named user, which results in being blocked from creating a page + and receiving a block error message when attempting to upload a file

Screenshot 2023-07-11 at 10.39.21 AM.png (482×2 px, 164 KB)

Screenshot 2023-07-11 at 10.39.35 AM.png (1×2 px, 316 KB)

This is the block error message when multiple blocks are against the users + IP used.

Screenshot 2023-07-11 at 10.37.54 AM.png (1×2 px, 315 KB)

@AGueyte Thanks for confirming that it's blocking upload.

The task was asking for something different though - could you possibly read over the task description again?

Hi, thanks for the update.
cc @KColeman-WMF and @Niharika for the design discussion

Partial Block: Creating page blocks from

  • creating pages
  • uploading files

Partial Block; Uploading files blocks from

  • uploading files

The task description suggests "How about simply adding some inline help text to the 'create' checkbox to warn that it is helpful to check 'upload' too?"

Suggestion:

  • Should the inline help precise that blocking from creating pages also prevents from uploading a file - therefore, disabling the upload file checkbox?

Just change the wording?

ipb-action-create: Creating new pages and uploading new files
ipb-action-move: Moving pages and files
ipb-action-upload: Uploading files (including overwritting files)

That would fit better for the current implementation and avoids to distinct between upload and reupload (there are also user rights for reupload-own or reupload-shared, but that is blocked as well)

Change 951099 had a related patch set uploaded (by AGueyte; author: AGueyte):

[mediawiki/core@master] Update the wording of partial block actions

https://gerrit.wikimedia.org/r/951099

Change 951099 merged by jenkins-bot:

[mediawiki/core@master] Update the wording of partial block actions

https://gerrit.wikimedia.org/r/951099

Just change the wording?

ipb-action-create: Creating new pages and uploading new files
ipb-action-move: Moving pages and files
ipb-action-upload: Uploading files (including overwritting files)

That would fit better for the current implementation and avoids to distinct between upload and reupload (there are also user rights for reupload-own or reupload-shared, but that is blocked as well)

I think this makes sense. @AGueyte can you confirm if this is the new wording per your patch?

Just change the wording?

ipb-action-create: Creating new pages and uploading new files
ipb-action-move: Moving pages and files
ipb-action-upload: Uploading files (including overwritting files)

That would fit better for the current implementation and avoids to distinct between upload and reupload (there are also user rights for reupload-own or reupload-shared, but that is blocked as well)

I think this makes sense. @AGueyte can you confirm if this is the new wording per your patch?

Yes! The patch was updated to these ones.
Thank you

Aklapper added a subscriber: AGueyte.

Removing inactive task assignee (please do so as part of offboarding steps).