Why do we have State and Schedule State for Defects in Rally - what is the relationship between them?
State and Schedule State are generally set independently of each other.
Schedule State - generally used to track developer actions
Indicates the progress that has been made toward the completion of the defect. Schedule State normally has more granularity and is focused on developer actions.
A defect's state may go from Submitted --> Closed without the Schedule State changing at all. For instance, QA submits the defect, development reviews and decides everything is working as expected and closes the defect (sets State to Closed).
Alternatively, after a Defect was submitted, development may review and decide to move it to define it and create tasks(set Schedule State to Defined) and start working on it (set Schedule State of the first task to In Progress). After they complete the fix (Schedule State is set to Complete for last task), QA reviews, and if satisfied they may mark the defect State to Fixed. Or it could be that the Product Owner sets the Schedule State to Accepted and QA uses that information to verify the fix and mark it as Fixed/Closed.
State - generally used by product owners and higher-level executives to see the progress
Usually more focused on overall (big picture) status.
Indicates the rolled-up state of all predecessors for this defect. If multiple predecessors are associated to the defect, the lowest State value of any predecessor is rolled up and displayed in this field.
Defects are not officially closed until they have a closed state.