MCPcopy
hub / github.com/PyGithub/PyGithub / disable_automerge

Method disable_automerge

github/PullRequest.py:915–937  ·  view source on GitHub ↗

:calls: `POST /graphql `_ with a mutation to disable pull request auto merge

(
        self,
        client_mutation_id: Opt[str] = NotSet,
    )

Source from the content-addressed store, hash-verified

913 return data
914
915 def disable_automerge(
916 self,
917 client_mutation_id: Opt[str] = NotSet,
918 ) -> dict[str, Any]:
919 """
920 :calls: `POST /graphql <https://docs.github.com/en/graphql>`_ with a mutation to disable pull request auto merge
921 <https://docs.github.com/en/graphql/reference/mutations#disablepullrequestautomerge>
922 """
923 assert is_optional(client_mutation_id, str), client_mutation_id
924
925 # Define the variables
926 variables = {
927 "pullRequestId": self.node_id,
928 "clientMutationId": client_mutation_id,
929 }
930
931 # Make the request
932 _, data = self._requester.graphql_named_mutation(
933 mutation_name="disablePullRequestAutoMerge",
934 mutation_input=NotSet.remove_unset_items(variables),
935 output_schema="actor { avatarUrl login resourcePath url } clientMutationId",
936 )
937 return data
938
939 def merge(
940 self,

Callers 4

testDisableAutomergeMethod · 0.80
testDefaultUrlMethod · 0.80
testOtherUrlMethod · 0.80
testOtherPortMethod · 0.80

Calls 3

is_optionalFunction · 0.90
remove_unset_itemsMethod · 0.80

Tested by

no test coverage detected