Now that we have the machinery for per-branch ACLs, it's possible for the webapp to intervene when somebody tries to delete a branch. However, I still have some concerns about that approach: for example, if a project's default repository is an imported repository (which isn't uncommon, e.g. https://launchpad.net/grub), and a series is linked to a branch which is deleted on the remote side, what can we do? We shouldn't fail the import, but it would also be bad for the import to contain a silently-orphaned branch which now cannot be deleted despite not existing on the remote.
I think it would probably be better to have soft links in the same sort of way that we do for merge proposals. We'd check that the branch exists when creating the link, but there'd be nothing to stop it being deleted later, and the UI would only render it as a link if the branch exists. This isn't completely ideal, but I can't think of a better alternative.
Now that we have the machinery for per-branch ACLs, it's possible for the webapp to intervene when somebody tries to delete a branch. However, I still have some concerns about that approach: for example, if a project's default repository is an imported repository (which isn't uncommon, e.g. https:/ /launchpad. net/grub), and a series is linked to a branch which is deleted on the remote side, what can we do? We shouldn't fail the import, but it would also be bad for the import to contain a silently-orphaned branch which now cannot be deleted despite not existing on the remote.
I think it would probably be better to have soft links in the same sort of way that we do for merge proposals. We'd check that the branch exists when creating the link, but there'd be nothing to stop it being deleted later, and the UI would only render it as a link if the branch exists. This isn't completely ideal, but I can't think of a better alternative.