Skip to content

Get started calling GitLab#109468

Draft
jacquev6 wants to merge 5 commits intojacquev6/scm-platform-clientfrom
jacquev6/scm-platform-gitlab
Draft

Get started calling GitLab#109468
jacquev6 wants to merge 5 commits intojacquev6/scm-platform-clientfrom
jacquev6/scm-platform-gitlab

Conversation

@jacquev6
Copy link
Collaborator

@jacquev6 jacquev6 commented Feb 26, 2026

This is going to implement #108968 with a more "vertical" approach: instead of implementing a wide layer without being able to really test it, I'm going to implement each SCM platform method end-to-end: I should be able to test each one from the SCM RPC client down to GitLab and back.

As a result, this should not be merged as-is: it's based on #108123 which should not be merged. We'll need to rebase these changes onto #107360. And to make my life easier, I'm also pushing changes that don't belong in Sentry's code base, in commits with messages starting with "TMP".

I'm opening this draft so that @cmanallen can follow my progress.

@github-actions github-actions bot added the Scope: Backend Automatically applied to PRs that change backend components label Feb 26, 2026
@jacquev6
Copy link
Collaborator Author

@cmanallen we need to talk about 7dca827. I pushed it here because I'm not sure about my fix, but the actual fix belongs in #107360. I'll bring it up in stand-up tonight.

state="open",
base=PullRequestBranch(
ref=raw["target_branch"],
sha="", # @todo Fetch sha for target branch? But then risk rate-limits and inconsistencies (race conditions)?
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We'll have to make it nullable and make users look up the SHA using a different SCM function.

sha=raw["sha"],
),
merged=raw["merged_at"] is not None,
url="", # @todo Remove attribute?
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can be removed 👍

email=raw["author_email"],
date=datetime.datetime.fromisoformat(raw["created_at"]),
),
files=[], # @todo
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Probably should be made nullable and then have the null value signal that files need to be fetched on a subsequent request.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Scope: Backend Automatically applied to PRs that change backend components

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants