Ensure complete reversibility of the archive_group feature flag

Original discussion: !201072 (comment 2687711313)

When the archive_group feature flag is disabled, all side effects from group archiving must be completely invisible to users. The platform should behave as if the group archiving feature never existed.

When the group is previously archived but the archive_group flag is then disabled:

  • The group.archived fields in the APIs must either be hidden or return nil. Unless they are documented as experimental.
  • The project.archived fields in the APIs must return false. Unless the project itself is archived.
  • The archived parameter in Group APIs must be ignored.
  • The archived parameter in Project APIs must ignore the parent group's archived status.
  • The active parameter in Group APIs must not check for the archive status.
  • The active parameter in Project APIs must ignore the parent group's archived status.
  • Archived badge and banners in the Groups overview page must not be visible
  • Archived badge and banners in the Projects overview page must not be visible. Unless the project itself is archived.
  • Must be able to archive/unarchive projects in the settings page.
  • Archived groups must not appear in Inactive tabs.
  • Projects in archived groups must not appear in Inactive/Archived tabs. Unless the project itself is archived.

Proposal

When the flag is disabled, the following must be true:

  1. Namespace#self_or_ancestors_archived? should always return false.
  2. The group's :archived, :self_or_ancestors_archived, :non_archived, :self_and_ancestors_non_archived scopes should all be no-op.
  3. The group's :active, :inactive, :self_and_ancestors_active, and :self_or_ancestors_inactive scopes should only check for the deletion schedule.
  4. The project's :self_or_ancestors_archived, :self_and_ancestors_active and :self_or_ancestors_inactive should ignore the group's archived status.
  5. Projects::ArchiveService should not check for AncestorAlreadyArchivedError.
  6. Projects::UnarchiveService should not check for AncestorArchivedError.
  7. Groups::ArchiveService should be a no-op.
  8. Groups::UnarchiveService should be a no-op.
Edited by Shane Maglangit