Last modified: 2014-10-27 16:08:17 UTC

Wikimedia Bugzilla is closed!

Wikimedia migrated from Bugzilla to Phabricator. Bug reports are handled in Wikimedia Phabricator.
This static website is read-only and for historical purposes. It is not possible to log in and except for displaying bug reports and their history, links might be broken. See T74563, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 72563 - Tasks should clean up after themselves when they fail in STARTING phase
Tasks should clean up after themselves when they fail in STARTING phase
Status: NEW
Product: Analytics
Classification: Unclassified
Wikimetrics (Other open bugs)
unspecified
All All
: Unprioritized normal
: ---
Assigned To: Nobody - You can work on this!
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2014-10-27 15:59 UTC by nuria
Modified: 2014-10-27 16:08 UTC (History)
8 users (show)

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments

Description nuria 2014-10-27 15:59:21 UTC
Tasks should clean up after themselves when SoftTimeLimitExceeded exception is raised. 

If not a report (=task) will appear on the database with status STARTED when in fact will never complete, as it was cancelled (for taking too much time)


This is happening right now with PagesCreated and NamespaceCreated for enwiki

 | 1791117 | 2014-10-21 00:00:00 | enwiki - PagesCreated | STARTED |
 | 1791122 | 2014-10-22 00:00:00 | enwiki - PagesCreated | STARTED |

In the code we are handling properly reports left in stage "PENDING" but not started (which indicate that report could not even start really)
Comment 1 nuria 2014-10-27 16:06:17 UTC
>Tasks should clean up after themselves when SoftTimeLimitExceeded exception is raised.
Taking this back, this is already happening. Now, what is missing is exceptions raised 
within the STARTING or PENDING phase that are not related to tasks taking too long.


Any exception should mark task as "FAILURE" so a future run of the scheduler (if recurrent) can pick it up.
Comment 2 nuria 2014-10-27 16:08:17 UTC
We likely need to catch all db errors via catching the highest level exception on sqlalchemy exception classes at the same level where we are catching now  SoftTimeLimitExceeded

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links