1
0
Fork 0
mirror of https://we.phorge.it/source/phorge.git synced 2024-11-24 15:52:41 +01:00
phorge-phorge/src/applications/maniphest
epriestley 857e3aee83 Improve ApplicationTransaction behavior for poorly constructed transactions
Summary:
Ref T2222. Five very small improvements:

  - I hit this exception and it took a bit to understand which transaction was causing problems. Add an `Exception` subclass which does a better job of making the message debuggable.
  - The `oldValue` of a transaction may be `null`, legitimately (for example, changing the `repositoryPHID` for a revision from `null` to some valid PHID). Do a check to see if `setOldValue()` has been called, instead of a check for a `null` value.
  - Add an additional check for the other case (shouldn't have a value, but does).
  - When we're not generating a value, don't bother calling the code to generate it. The best case scenario is that it has no effect; any effect it might have (changing the value) is always wrong.
  - Maniphest didn't fall back to the parent correctly when computing this flag, so it got the wrong result for `CustomField` transactions.

Test Plan: Resolved the issue I was hitting more easily, made updates to a `null`-valued custom field, and applied other normal sorts of transactions successfully.

Reviewers: btrahan

Reviewed By: btrahan

CC: aran

Maniphest Tasks: T4557, T2222

Differential Revision: https://secure.phabricator.com/D8401
2014-03-05 10:44:21 -08:00
..
application Various linter fixes. 2014-02-26 12:44:58 -08:00
capability Add capabilities for editing task triage details (priority, assignee, etc) 2013-10-21 16:59:06 -07:00
conduit Check for null, strictly, in maniphest.update param validation 2014-03-04 11:42:18 -08:00
config Convert maniphest to use standard fields 2013-09-19 11:56:15 -07:00
constants Move many task status hardcodes into ManiphestTaskStatus 2014-02-17 15:59:31 -08:00
controller Project work boards - make editing tasks from workboards work 2014-03-04 11:50:44 -08:00
editor Maniphest Tasks + Project Boards - some polish 2014-03-04 17:01:33 -08:00
event ProjectView improvements 2014-02-13 14:36:49 -08:00
export Implemented support for different export formats. 2013-04-11 11:27:36 -07:00
field Move many task status hardcodes into ManiphestTaskStatus 2014-02-17 15:59:31 -08:00
lipsum Move many task status hardcodes into ManiphestTaskStatus 2014-02-17 15:59:31 -08:00
mail Move many task status hardcodes into ManiphestTaskStatus 2014-02-17 15:59:31 -08:00
phid Move many task status hardcodes into ManiphestTaskStatus 2014-02-17 15:59:31 -08:00
query Move many task status hardcodes into ManiphestTaskStatus 2014-02-17 15:59:31 -08:00
remarkup Remove obsolete/deprecated withTaskIDs() / withTaskPHIDs() 2013-09-10 15:34:04 -07:00
search Use ApplicationTransactions/CustomField to power Differential global search 2014-02-26 11:18:06 -08:00
storage Improve ApplicationTransaction behavior for poorly constructed transactions 2014-03-05 10:44:21 -08:00
view Bump number of visible Maniphest tags to 4 (from 2) 2014-02-13 10:05:47 -08:00