1
0
Fork 0
mirror of https://we.phorge.it/source/phorge.git synced 2024-11-25 08:12:40 +01:00
phorge-phorge/src/applications/owners
epriestley ebb7ca8cbd Convert Owners paths to application transactions
Summary:
Ref T8320. Fixes T8317. Fixes T2831. Fixes T8073. Fixes T7127.

There was a bug with this line:

  for ($ii = 0; $ii < count($paths); $ii++) {

...because the array may be sparse if there have been deletes, so `count($paths)` might be 3, but the real keys could be `1`, `5` and `6`. I think this was the primary issue behind T7127.

The old Editor did a lot of work to try to validate paths. When a path failed to validate, it silently discarded it. This was silly and pointless: it's incredibly bad UX; and it's totally fine if users saves "invalid" paths. This was likely the cause of T8317, and probably the cause of T8073.

T2831 I'm less sure about, but I can't reproduce it and I rewrote all the logic so I suspect it's gone.

This also records and shows edits, so if stuff does keep happening it should be more clear what's going on.

I removed some adjacent stuff:

  - I removed the ability to delete packages. I'll add "disable" in a future diff, plus `bin/remove destroy`, like other objects. Getting rid of this now let me get rid of all the mail stuff.
  - I removed "path validation" where packages would try to automatically update in response to commits. This doesn't necessarily make sense in Git/Mercurial, is sketchy, could easily have been the source of T2831, and seems generally complicated and not very valuable. We could maybe restore it some day, but I'd like to get Owners stable before trying to do crazy stuff like that.

Test Plan: {F437687}

Reviewers: chad, btrahan

Reviewed By: btrahan

Subscribers: epriestley

Maniphest Tasks: T8317, T8073, T7127, T2831, T8320

Differential Revision: https://secure.phabricator.com/D13032
2015-05-27 10:30:26 -07:00
..
application Convert Owners paths to application transactions 2015-05-27 10:30:26 -07:00
conduit phtize all the things 2015-05-22 21:16:39 +10:00
config Remove all application-specific reply handler class overrides 2015-03-31 17:22:01 -07:00
controller Convert Owners paths to application transactions 2015-05-27 10:30:26 -07:00
editor Convert Owners paths to application transactions 2015-05-27 10:30:26 -07:00
mail Convert Owners paths to application transactions 2015-05-27 10:30:26 -07:00
phid Rename PHIDType classes 2014-07-24 08:05:46 +10:00
query Use ApplicationTransactions for all non-path edits to Owners packages 2015-05-27 10:30:08 -07:00
storage Convert Owners paths to application transactions 2015-05-27 10:30:26 -07:00
typeahead Give typeahead browse dialogs sensible titles 2015-04-20 10:06:23 -07:00