Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 364727

Summary: should progress service run error handlers if task fails?
Product: [ECD] Orion Reporter: Susan McCourt <susan>
Component: ClientAssignee: Malgorzata Janczarska <malgorzata.tomczyk>
Status: RESOLVED FIXED QA Contact:
Severity: normal    
Priority: P3    
Version: 0.3   
Target Milestone: 7.0   
Hardware: PC   
OS: Windows 7   
Whiteboard:
Bug Depends on:    
Bug Blocks: 344012    

Description Susan McCourt CLA 2011-11-24 11:35:40 EST
please see discussion in bug 361006 comment 9.
Comment 1 Susan McCourt CLA 2011-11-24 11:36:48 EST
assigning to Gosia while she reviews progress API.  
The original bug was about adding more progress indication to tasks, and this question is really a separate question.
Comment 2 Malgorzata Janczarska CLA 2011-11-24 11:55:19 EST
I'll look at it tomorrow.
Comment 3 Malgorzata Janczarska CLA 2011-11-25 07:30:00 EST
You found an important issue that needs to be rethought and I think unified.
Task can now fail in two ways:
1. Task is scheduled, returning 201 and then one of the responses from progress service contains "error" indicating that task failed. But still the responose has status===200
2. Task is not scheduled, but we get the result straight away. This means we can also get an error (status !== 200 && status !==201)
Good that you made a fix in commit 0f965d7f230d4004a0eb9af3fdf93258f114e5f7 (new file and new folder operations could use progress indicator, add errback to progress handler), because case "2" was until now swallowed. But I think we still need to return it in somehow.
Look at merge command in gitCommands.js it tried to solve this problem. But I think this should be somehow unified, so that we don't have to add double error handling like in merge command.
Comment 4 Szymon Brandys CLA 2011-12-12 09:19:57 EST
The answer for this question is part of bug 344012 work.
Comment 5 Malgorzata Janczarska CLA 2014-09-12 08:11:13 EDT
Looks like this problem was solved.