Skip to content
This repository was archived by the owner on Jun 13, 2025. It is now read-only.
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 8 additions & 5 deletions graphql_api/types/commit/commit.py
Original file line number Diff line number Diff line change
Expand Up @@ -393,16 +393,19 @@ def resolve_coverage_components(commit: Commit, info, filters=None) -> List[Comp


@commit_bundle_analysis_bindable.field("bundleAnalysisCompareWithParent")
@sync_to_async
@sentry_sdk.trace
def resolve_commit_bundle_analysis_compare_with_parent(
async def resolve_commit_bundle_analysis_compare_with_parent(
commit: Commit, info: GraphQLResolveInfo
) -> Union[BundleAnalysisComparison, Any]:
base_commit = Commit.objects.filter(commitid=commit.parent_commit_id).first()
if not base_commit:
if not commit.parent_commit_id:
return MissingBaseCommit()
base_commit = await CommitLoader.loader(info, commit.repository_id).load(
commit.parent_commit_id
)

bundle_analysis_comparison = load_bundle_analysis_comparison(base_commit, commit)
bundle_analysis_comparison = await sync_to_async(load_bundle_analysis_comparison)(
base_commit, commit
)

# Store the created SQLite DB path in info.context
# when the request is fully handled, have the file deleted
Expand Down