-
Luke Duncalfe authored
Fixes missing target types in `TargetTypeEnum` and separates the EE-specific types. Adds `calls_gitaly` for the `TodoType#body` field, as an error is raised when requesting the `todo.body field` for a `Commit` `Todo`: RuntimeError (Gitaly is called for field 'body' on Types::TodoType - please either specify a constant complexity or add `calls_gitaly: true` to the field declaration) When the `Todo` (a polymorphic model) has a `target_type` of `Commit`, requesting the `body` field calls Gitaly (`Todo#body` calls `Todo#target` which fetches the `Commit` from Gitaly) and we get the above error. I've set `calls_gitaly: true` for the `TodoType#body` field (affecting all Todos, regardless of the `target_type`) in order to avoid the error, while we work out a better solution. https://gitlab.com/gitlab-org/gitlab/issues/34757 https://gitlab.com/gitlab-org/gitlab/issues/34757#note_234752665
a51ed1c4