Separate upgrade task from install and delete.
Rework install and update logic.
Try to register local conflicts.
Fix order of jobs applying.