diff --git a/upload/views/empty_upload.py b/upload/views/empty_upload.py index 6d7f8d5ba3..dfcd3cc422 100644 --- a/upload/views/empty_upload.py +++ b/upload/views/empty_upload.py @@ -16,6 +16,7 @@ GlobalTokenAuthentication, OrgLevelTokenAuthentication, RepositoryLegacyTokenAuthentication, + UploadTokenRequiredAuthenticationCheck, repo_auth_custom_exception_handler, ) from codecov_auth.authentication.types import RepositoryAsUser @@ -73,6 +74,7 @@ class EmptyUploadSerializer(serializers.Serializer): class EmptyUploadView(CreateAPIView, GetterMixin): permission_classes = [CanDoCoverageUploadsPermission] authentication_classes = [ + UploadTokenRequiredAuthenticationCheck, GlobalTokenAuthentication, OrgLevelTokenAuthentication, GitHubOIDCTokenAuthentication, diff --git a/upload/views/test_results.py b/upload/views/test_results.py index fbe9f40da2..86dc756430 100644 --- a/upload/views/test_results.py +++ b/upload/views/test_results.py @@ -14,7 +14,6 @@ OrgLevelTokenAuthentication, RepositoryLegacyTokenAuthentication, TokenlessAuthentication, - UploadTokenRequiredAuthenticationCheck, repo_auth_custom_exception_handler, ) from codecov_auth.authentication.types import RepositoryAsUser @@ -59,7 +58,6 @@ class TestResultsView( ): permission_classes = [UploadTestResultsPermission] authentication_classes = [ - UploadTokenRequiredAuthenticationCheck, OrgLevelTokenAuthentication, GitHubOIDCTokenAuthentication, RepositoryLegacyTokenAuthentication, diff --git a/upload/views/upload_completion.py b/upload/views/upload_completion.py index cbc6cc04dc..edb1df6aed 100644 --- a/upload/views/upload_completion.py +++ b/upload/views/upload_completion.py @@ -10,6 +10,7 @@ GlobalTokenAuthentication, OrgLevelTokenAuthentication, RepositoryLegacyTokenAuthentication, + UploadTokenRequiredAuthenticationCheck, repo_auth_custom_exception_handler, ) from reports.models import ReportSession @@ -25,6 +26,7 @@ class UploadCompletionView(CreateAPIView, GetterMixin): permission_classes = [CanDoCoverageUploadsPermission] authentication_classes = [ + UploadTokenRequiredAuthenticationCheck, GlobalTokenAuthentication, OrgLevelTokenAuthentication, GitHubOIDCTokenAuthentication,