Closed stevenday closed 10 years ago
This seems to be a problem with the response form specifically: marking the problem as closed updates the problem's status, but doesn't calculate the resolved timestamp. Doing this manually from within other code doesn't seem to have the same problem, so it must be something to do with the way the form does it.
The issue here is that the form which gets the new problem status saves it as a string, not as a integer, and so when the problem is saved and checks to see if it needs to set the timestamp, Problem.RESOLVED
is != self.status
here: https://github.com/mysociety/citizenconnect/blob/master/issues/models.py#L586
This commit is the culprit: https://github.com/mysociety/citizenconnect/commit/48c47bfdf2fa8ae41b28f36e0b8c2457060152ca as it replaced int(self.status)
with just self.status
. So therefore this has been an issue since we rolled out the removal of escalation.
Two issues (P193 and P190) have a status of "closed", but no
resolved
timestamp set.Django reversion's history shows when the change took place, so I have manually added the missing data, but we need to figure out how it got missed in the first place.