Skip to content

Commit 4ad3fbe

Browse files
ref: move releases into releases module (#97851)
Moves most releases endpoints into releases/endpoints. refs https://linear.app/getsentry/issue/RTC-1110/move-issues-endpoints-into-issues-app --------- Co-authored-by: getsantry[bot] <66042841+getsantry[bot]@users.noreply.github.com>
1 parent b1ba5a4 commit 4ad3fbe

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

43 files changed

+46
-36
lines changed

src/sentry/api/endpoints/project_artifact_bundle_file_details.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,8 @@
1212
from sentry.api.base import region_silo_endpoint
1313
from sentry.api.bases.project import ProjectEndpoint, ProjectReleasePermission
1414
from sentry.api.endpoints.debug_files import has_download_permission
15-
from sentry.api.endpoints.project_release_file_details import ClosesDependentFiles
1615
from sentry.models.artifactbundle import ArtifactBundle, ArtifactBundleArchive
16+
from sentry.releases.endpoints.project_release_file_details import ClosesDependentFiles
1717

1818

1919
class ProjectArtifactBundleFileDetailsMixin:

src/sentry/api/helpers/source_map_helper.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@
66
from packaging.version import Version
77
from rest_framework.exceptions import NotFound, ParseError
88

9-
from sentry.api.endpoints.project_release_files import ArtifactSource
109
from sentry.debug_files.release_files import maybe_renew_releasefiles
1110
from sentry.interfaces.exception import Exception as ExceptionInterface
1211
from sentry.interfaces.stacktrace import Frame
@@ -15,6 +14,7 @@
1514
from sentry.models.release import Release
1615
from sentry.models.releasefile import ReleaseFile, read_artifact_index
1716
from sentry.models.sourcemapprocessingissue import SourceMapProcessingIssue
17+
from sentry.releases.endpoints.project_release_files import ArtifactSource
1818
from sentry.services import eventstore
1919
from sentry.services.eventstore.models import BaseEvent
2020
from sentry.utils.javascript import find_sourcemap

src/sentry/api/serializers/models/plugin.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ def __init__(self, project=None):
3535
self.project = project
3636

3737
def serialize(self, obj, attrs, user, **kwargs):
38-
from sentry.api.endpoints.project_releases_token import _get_webhook_url
38+
from sentry.releases.endpoints.project_releases_token import _get_webhook_url
3939

4040
doc = ""
4141

src/sentry/api/urls.py

Lines changed: 31 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,10 @@
2121
from sentry.api.endpoints.organization_missing_org_members import OrganizationMissingMembersEndpoint
2222
from sentry.api.endpoints.organization_plugins_configs import OrganizationPluginsConfigsEndpoint
2323
from sentry.api.endpoints.organization_plugins_index import OrganizationPluginsEndpoint
24+
from sentry.api.endpoints.organization_releases import (
25+
OrganizationReleasesEndpoint,
26+
OrganizationReleasesStatsEndpoint,
27+
)
2428
from sentry.api.endpoints.organization_sampling_admin_metrics import (
2529
OrganizationDynamicSamplingAdminMetricsEndpoint,
2630
)
@@ -371,6 +375,33 @@
371375
UserNotificationSettingsProvidersEndpoint,
372376
)
373377
from sentry.preprod.api.endpoints import urls as preprod_urls
378+
from sentry.releases.endpoints.organization_release_assemble import (
379+
OrganizationReleaseAssembleEndpoint,
380+
)
381+
from sentry.releases.endpoints.organization_release_commits import (
382+
OrganizationReleaseCommitsEndpoint,
383+
)
384+
from sentry.releases.endpoints.organization_release_details import (
385+
OrganizationReleaseDetailsEndpoint,
386+
)
387+
from sentry.releases.endpoints.organization_release_file_details import (
388+
OrganizationReleaseFileDetailsEndpoint,
389+
)
390+
from sentry.releases.endpoints.organization_release_files import OrganizationReleaseFilesEndpoint
391+
from sentry.releases.endpoints.organization_release_health_data import (
392+
OrganizationReleaseHealthDataEndpoint,
393+
)
394+
from sentry.releases.endpoints.organization_release_meta import OrganizationReleaseMetaEndpoint
395+
from sentry.releases.endpoints.project_release_commits import ProjectReleaseCommitsEndpoint
396+
from sentry.releases.endpoints.project_release_details import ProjectReleaseDetailsEndpoint
397+
from sentry.releases.endpoints.project_release_file_details import ProjectReleaseFileDetailsEndpoint
398+
from sentry.releases.endpoints.project_release_files import ProjectReleaseFilesEndpoint
399+
from sentry.releases.endpoints.project_release_repositories import ProjectReleaseRepositories
400+
from sentry.releases.endpoints.project_release_setup import ProjectReleaseSetupCompletionEndpoint
401+
from sentry.releases.endpoints.project_release_stats import ProjectReleaseStatsEndpoint
402+
from sentry.releases.endpoints.project_releases import ProjectReleasesEndpoint
403+
from sentry.releases.endpoints.project_releases_token import ProjectReleasesTokenEndpoint
404+
from sentry.releases.endpoints.release_deploys import ReleaseDeploysEndpoint
374405
from sentry.relocation.api.endpoints.abort import RelocationAbortEndpoint
375406
from sentry.relocation.api.endpoints.artifacts.details import RelocationArtifactDetailsEndpoint
376407
from sentry.relocation.api.endpoints.artifacts.index import RelocationArtifactIndexEndpoint
@@ -658,17 +689,6 @@
658689
)
659690
from .endpoints.organization_recent_searches import OrganizationRecentSearchesEndpoint
660691
from .endpoints.organization_relay_usage import OrganizationRelayUsage
661-
from .endpoints.organization_release_assemble import OrganizationReleaseAssembleEndpoint
662-
from .endpoints.organization_release_commits import OrganizationReleaseCommitsEndpoint
663-
from .endpoints.organization_release_details import OrganizationReleaseDetailsEndpoint
664-
from .endpoints.organization_release_file_details import OrganizationReleaseFileDetailsEndpoint
665-
from .endpoints.organization_release_files import OrganizationReleaseFilesEndpoint
666-
from .endpoints.organization_release_health_data import OrganizationReleaseHealthDataEndpoint
667-
from .endpoints.organization_release_meta import OrganizationReleaseMetaEndpoint
668-
from .endpoints.organization_releases import (
669-
OrganizationReleasesEndpoint,
670-
OrganizationReleasesStatsEndpoint,
671-
)
672692
from .endpoints.organization_sampling_project_rates import OrganizationSamplingProjectRatesEndpoint
673693
from .endpoints.organization_sdk_deprecations import OrganizationSdkDeprecationsEndpoint
674694
from .endpoints.organization_sdk_updates import (
@@ -712,15 +732,6 @@
712732
ProjectProfilingRawChunkEndpoint,
713733
ProjectProfilingRawProfileEndpoint,
714734
)
715-
from .endpoints.project_release_commits import ProjectReleaseCommitsEndpoint
716-
from .endpoints.project_release_details import ProjectReleaseDetailsEndpoint
717-
from .endpoints.project_release_file_details import ProjectReleaseFileDetailsEndpoint
718-
from .endpoints.project_release_files import ProjectReleaseFilesEndpoint
719-
from .endpoints.project_release_repositories import ProjectReleaseRepositories
720-
from .endpoints.project_release_setup import ProjectReleaseSetupCompletionEndpoint
721-
from .endpoints.project_release_stats import ProjectReleaseStatsEndpoint
722-
from .endpoints.project_releases import ProjectReleasesEndpoint
723-
from .endpoints.project_releases_token import ProjectReleasesTokenEndpoint
724735
from .endpoints.project_repo_path_parsing import ProjectRepoPathParsingEndpoint
725736
from .endpoints.project_reprocessing import ProjectReprocessingEndpoint
726737
from .endpoints.project_rule_actions import ProjectRuleActionsEndpoint
@@ -755,7 +766,6 @@
755766
RelayRegisterChallengeEndpoint,
756767
RelayRegisterResponseEndpoint,
757768
)
758-
from .endpoints.release_deploys import ReleaseDeploysEndpoint
759769
from .endpoints.rule_snooze import MetricRuleSnoozeEndpoint, RuleSnoozeEndpoint
760770
from .endpoints.setup_wizard import SetupWizard
761771
from .endpoints.system_health import SystemHealthEndpoint

src/sentry/releases/__init__.py

Whitespace-only changes.

src/sentry/releases/endpoints/__init__.py

Whitespace-only changes.

src/sentry/api/endpoints/organization_release_file_details.py renamed to src/sentry/releases/endpoints/organization_release_file_details.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,10 +5,10 @@
55
from sentry.api.api_publish_status import ApiPublishStatus
66
from sentry.api.base import region_silo_endpoint
77
from sentry.api.bases.organization import OrganizationReleasesBaseEndpoint
8-
from sentry.api.endpoints.project_release_file_details import ReleaseFileDetailsMixin
98
from sentry.api.exceptions import ResourceDoesNotExist
109
from sentry.models.organization import Organization
1110
from sentry.models.release import Release
11+
from sentry.releases.endpoints.project_release_file_details import ReleaseFileDetailsMixin
1212

1313

1414
class ReleaseFileSerializer(serializers.Serializer):

0 commit comments

Comments
 (0)