Page MenuHomePhabricator

Filtering by date on Special:NewPagesFeed does not work
Closed, ResolvedPublicBUG REPORT

Description

List of steps to reproduce (step by step, including full links if applicable):

  • Click on set filters
  • Enter Date Range for a specific date, e.g. 11/1/21 -11/31/21 or 12/15/21 - 12/15/21
  • Click "Set Filters"

What happens?:
The date range defaults to the current day, e.g. 3/4/22 - 3/4/22

What should have happened instead?:
The list should only show entries from the specific date range.

Software version (if not a Wikimedia wiki), browser information, screenshots, other information, etc.:

Event Timeline

I can confirm this issue.

List of steps to reproduce

  1. Visit https://en.wikipedia.org/wiki/Special:NewPagesFeed
  2. Note that the "New Page Patrol" radio button is set
  3. Click "Set filters"
  4. Set Date range - From to: 01/01/2022
  5. Set Date range - To to: 01/02/2022
  6. Click the green "Set filters" button

Result

  • The following API calls are sent:
    • https://en.wikipedia.org/w/api.php?action=pagetriagelist&format=json&show_predicted_issues_attack=1&show_predicted_issues_copyvio=1&show_predicted_issues_none=1&show_predicted_issues_spam=1&show_predicted_issues_vandalism=1&date_range_from=2022-03-04T00%3A00%3A00.000Z&date_range_to=2022-03-04T23%3A59%3A59.000Z&namespace=0&showreviewed=1&showunreviewed=1&showdeleted=1&showothers=1&learners=1&dir=newestfirst&limit=20&version=2
    • https://en.wikipedia.org/w/api.php?action=pagetriagestats&format=json&show_predicted_issues_attack=1&show_predicted_issues_copyvio=1&show_predicted_issues_none=1&show_predicted_issues_spam=1&show_predicted_issues_vandalism=1&date_range_from=2022-03-04T00%3A00%3A00.000Z&date_range_to=2022-03-04T23%3A59%3A59.000Z&namespace=0&showreviewed=1&showunreviewed=1&showdeleted=1&showothers=1&learners=1&nppDir=newestfirst
  • Only pages between the two date_range_from / date_range_to are shown

Expected

  • The correct API calls are sent, and pages between the requested dates are shown

Other notes

  • Manually calling https://en.wikipedia.org/w/api.php?action=pagetriagelist&format=json&show_predicted_issues_attack=1&show_predicted_issues_copyvio=1&show_predicted_issues_none=1&show_predicted_issues_spam=1&show_predicted_issues_vandalism=1&date_range_from=2022-01-01T00%3A00%3A00.000Z&date_range_to=2022-02-01T23%3A59%3A59.000Z&namespace=0&showreviewed=1&showunreviewed=1&showdeleted=1&showothers=1&learners=1&dir=newestfirst&limit=20&version=2 works as expected
  • Both API calls have warnings for unrecognized parameters (version and nppDir)
TheresNoTime renamed this task from PageCuration to Filtering by date on Special:NewPagesFeed does not work.Mar 4 2022, 11:36 PM
TheresNoTime added a project: PageTriage.

Change 768185 had a related patch set uploaded (by Samtar; author: Samtar):

[mediawiki/extensions/PageTriage@master] PageCuration: Use value of date selectors

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

Confirmed on betalabs (enwiki) - the selection of date range doesn't work. Any entered dates will default to the current day.

  • select the date range

From : 01/01/2022
To: 01/02/2022

  • the displayed result is of the most recent date
  • when checking the date range in the filters, the filters are automatically get set to the most recent day.

Notes: The following actions will not affect the outcome - the result will default to the most recent day:

  • entering dates by typing or selecting from the calendar
  • using filtering options Sort by:Newest/Oldest

My patch is failing quibble-vendor-mysql-php72-noselenium-docker, but I think that's an issue with the Jenkins job 😭

My patch is failing quibble-vendor-mysql-php72-noselenium-docker, but I think that's an issue with the Jenkins job 😭

Just FYI, this is failing due to T303092

based — the Jenkins job has been fixed, and 768185 is now passing ✨

Change 768185 merged by jenkins-bot:

[mediawiki/extensions/PageTriage@master] PageCuration: Use value of date selectors

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

Checked on testwiki wmf.4 - the date range selection works as expected. Closing as Resolved.