Jump to content

Deleting a task from an app doesn't uninstall it


Recommended Posts

This feels very much like a bug, but the IPS core code appears to deliberately work around it. If you delete a task in the dev center, it removes the task on the dev install (including the task's PHP file), and removes it from the tasks.json file so it isn't installed on any new installs. However, when the app is updated on an existing install it only updates existing tasks and adds new ones - it doesn't delete the tasks that are no longer required.

For a traditional setup, this results in the task continuing to be run, because the old PHP file won't be deleted. I deploy most of my stuff through git, so for me and some other large sites this results in the task failing because the file has been removed but the task has not.

As there is core code that works around this (by deleting tasks on upgrade), I guess this is probably something that is sort of known, but it's definitely not good and should be changed. It makes no sense to do it this way.

Link to comment
Share on other sites

2 minutes ago, Adriano Faria said:

You probably need to delete the entry on core_tasks table?

Same happens when you delete a setting. You have to delete it from settings table. 

Yes, but my point is that I shouldn't have to. While there might arguably be reason for leaving the settings intact (such as recovery in case something screwed up), there's no reason to leave the task. It has been removed from the dev install, and there is no indication when you remove it that it won't be removed from the live installs.

Link to comment
Share on other sites


This topic is now archived and is closed to further replies.

  • Recently Browsing   0 members

    • No registered users viewing this page.
  • Create New...