Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

fix:mr.cancel_merge_when_pipeline_succeeds()#2350

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
nejch merged 1 commit intomainfromjlvillal/cancel_merge
Oct 31, 2022

Conversation

JohnVillalovos
Copy link
Member

  • Call was incorrectly using aPUT method when should have used aPOST method.
  • Changed return type to adict as GitLab only returns {'status': 'success'} on success. Since the function didn't work previously, this should not impact anyone.
  • Updated the test fixturemerge_request to add ability to create a pipeline.
  • Added functional test formr.cancel_merge_when_pipeline_succeeds()

Fixes:#2349

@codecov-commenter
Copy link

codecov-commenter commentedOct 30, 2022
edited
Loading

Codecov Report

Merging#2350 (19ee535) intomain (f04e8ba) willincrease coverage by0.09%.
The diff coverage is100.00%.

@@            Coverage Diff             @@##             main    #2350      +/-   ##==========================================+ Coverage   95.78%   95.88%   +0.09%==========================================  Files          79       79                Lines        5249     5248       -1     ==========================================+ Hits         5028     5032       +4+ Misses        221      216       -5
FlagCoverage Δ
api_func_v483.47% <100.00%> (+0.09%)⬆️
cli_func_v482.73% <33.33%> (+0.01%)⬆️
unit87.76% <33.33%> (+0.01%)⬆️

Flags with carried forward coverage won't be shown.Click here to find out more.

Impacted FilesCoverage Δ
gitlab/v4/objects/merge_requests.py88.88% <100.00%> (+3.37%)⬆️

Copy link
Member

@nejchnejch left a comment

Choose a reason for hiding this comment

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

Thanks@JohnVillalovos nice catch with the response gotcha! I think we just need to update the docstring as well.

Interesting,GitlabMROnBuildSuccessError also sounds a bit weird to me now here, could be there are some historical reasons for discrepancies here.

Copy link
Member

@nejchnejch left a comment

Choose a reason for hiding this comment

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

Thanks@JohnVillalovos for the quick fix and@lmilbaum for the review, let's tackle the follow-up separately :)

lmilbaum and JohnVillalovos reacted with thumbs up emoji
  * Call was incorrectly using a `PUT` method when should have used a    `POST` method.  * Changed return type to a `dict` as GitLab only returns    {'status': 'success'} on success. Since the function didn't work    previously, this should not impact anyone.  * Updated the test fixture `merge_request` to add ability to create    a pipeline.  * Added functional test for `mr.cancel_merge_when_pipeline_succeeds()`Fixes:#2349
@nejchnejchforce-pushed thejlvillal/cancel_merge branch from19ee535 tocd31cdaCompareOctober 31, 2022 10:12
@nejchnejchenabled auto-merge (squash)October 31, 2022 10:16
@nejchnejch merged commitbd82d74 intomainOct 31, 2022
@nejchnejch deleted the jlvillal/cancel_merge branchOctober 31, 2022 10:24
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment
Reviewers

@lmilbaumlmilbaumlmilbaum approved these changes

@nejchnejchnejch approved these changes

Assignees
No one assigned
Labels
None yet
Projects
None yet
Milestone
No milestone
Development

Successfully merging this pull request may close these issues.

project-merge-request cancel-merge-when-pipeline-succeeds fails withgitlab.exceptions.GitlabMROnBuildSuccessError: 404: 404 Not Found
4 participants
@JohnVillalovos@codecov-commenter@lmilbaum@nejch

[8]ページ先頭

©2009-2025 Movatter.jp