settings: Merge settings API endpoints.

This API change removes unnecessary complexity from a client that
wants to change a user's personal settings, and also saves developers
from needing to make decisions about what sort of setting something is
at the API level.

We preserve the old settings endpoints as mapping to the same function
as the new one for backwards-compatibility. We delete the
documentation for the old endpoints, though the documentation for the
merged /settings endpoint mentions how to use the old endpoints when
needed.

We migrate all backend tests to the new endpoints, except for
individual tests for each legacy endpoint to verify they still work.

Co-authored-by: sahil839 <sahilbatra839@gmail.com>
This commit is contained in:
Tim Abbott
2021-07-07 13:08:11 -07:00
parent 89724e5bb4
commit 256091dc15
11 changed files with 547 additions and 551 deletions

View File

@@ -28,9 +28,7 @@ EXCLUDE_UNDOCUMENTED_ENDPOINTS = {
}
# Consists of endpoints with some documentation remaining.
# These are skipped but return true as the validator cannot exclude objects
EXCLUDE_DOCUMENTED_ENDPOINTS = {
("/settings/notifications", "patch"),
}
EXCLUDE_DOCUMENTED_ENDPOINTS: Set[Tuple[str, str]] = set([])
# Most of our code expects allOf to be preprocessed away because that is what
# yamole did. Its algorithm for doing so is not standards compliant, but we