Page MenuHomePhabricator

listpages.py: Add option for adding custom text before the list
Open, LowPublicFeature

Description

I have idea that we should add option for adding custom text before the list. It will be good so users can know what is list about.

Example:

In this list are articles with ref tags but have {{unreferenced}}.

* Article1
* Article2
* Article3

Event Timeline

Kizule changed the subtype of this task from "Task" to "Feature Request".Feb 29 2020, 9:00 PM
This comment was removed by Dvorapa.
Xqt triaged this task as Low priority.Mar 2 2020, 11:10 AM

@Dvorapa I've a couple of getting started questions related to this task. Should the code changes take place in the script file core/scripts/listpages.py in https://gerrit.wikimedia.org/r/#/admin/projects/pywikibot/core? Should the main() function be expanded to handle an additional argument related to custom text? Please share any other tips for getting started on this task.

Both yes and yes! The script provides many parameters, so inspired by those adding another one should be an easy step. A newcomer then have to find a place where adding the prologue would be appropriate.

I have idea that we should add option for adding custom text before the list. It will be good so users can know what is list about.

I think we can have both, text before and text after the list probably with options -pre and -post or something like that.

Change 611929 had a related patch set uploaded (by Shreyasminocha; owner: Shreyasminocha):
[pywikibot/core@master] Allow defining custom prefix/suffix in listpages

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

Xqt removed a project: Patch-Needs-Improvement.
Xqt added a subscriber: Shreyasminocha.

Change 611929 abandoned by Xqt:
[pywikibot/core@master] Allow defining custom prefix/suffix in listpages

Reason:
not an appropriate implementation

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

I would like to tackle this task if it's still active and would like to know what exactly should be done here. Thanks for the help!

@Xqt What should be done here? Thanks a lot for helping! :D

@Xqt Need help in getting started with this!

Shashikantsingh7 subscribed.

Hi, @Kizule could you explain in more detail, how to solve this task?
Thanks!

@Shashikantsingh7

@Dvorapa I've a couple of getting started questions related to this task. Should the code changes take place in the script file core/scripts/listpages.py in https://gerrit.wikimedia.org/r/#/admin/projects/pywikibot/core? Should the main() function be expanded to handle an additional argument related to custom text? Please share any other tips for getting started on this task.

I have idea that we should add option for adding custom text before the list. It will be good so users can know what is list about.

I think we can have both, text before and text after the list probably with options -pre and -post or something like that.

See also https://www.mediawiki.org/wiki/Manual:Pywikibot/Development and https://www.mediawiki.org/wiki/Gerrit/Tutorial.

@Kizule I think this task has alread been solved or under review .@Shreyasminocha had already send pr : https://gerrit.wikimedia.org/r/611929
Thanks!!

@Kizule I think this task has alread been solved or under review .@Shreyasminocha had already send pr : https://gerrit.wikimedia.org/r/611929
Thanks!!

@Shashikantsingh7 Patch is abandoned by @Xqt with reason: "not an appropriate implementation" (see T246549#6574133), so new one should be uploaded.

@Shashikantsingh7: Hi! This task has been assigned to you a while ago. Could you maybe share an update? Do you still plan to work on this task, or do you need any help?

@Shashikantsingh7: I am resetting the assignee of this task because there has not been progress lately (please correct me if I am wrong!). Resetting the assignee avoids the impression that somebody is already working on this task. It also allows others to potentially work towards fixing this task. Please claim this task again when you plan to work on it (via Add Action...Assign / Claim in the dropdown menu). Thanks for your understanding.

Change 670166 had a related patch set uploaded (by Gauravahlawat81; owner: Gauravahlawat81):
[pywikibot/core@master] Adding Description about the Lists

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

@Xqt The patch is still WIP, I just wanted to see if I am moving in right direction. Please provide me with feedback regarding the patch, thanks!

Please remove the i18n from submitting your patch

Yup, I didn't know how it got added, I will remove it