MCPcopy Create free account
hub / github.com/ezyang/ghstack / Root

Class Root

src/ghstack/github_fake.py:297–309  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

295
296
297class Root:
298 def repository(self, info: GraphQLResolveInfo, owner: str, name: str) -> Repository:
299 return github_state(info).repository(owner, name)
300
301 def node(self, info: GraphQLResolveInfo, id: GraphQLId) -> Node:
302 if id in github_state(info).repositories:
303 return github_state(info).repositories[id]
304 elif id in github_state(info).pull_requests:
305 return github_state(info).pull_requests[id]
306 elif id in github_state(info).issue_comments:
307 return github_state(info).issue_comments[id]
308 else:
309 raise RuntimeError("unknown id {}".format(id))
310
311
312with open(

Callers 1

__init__Method · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected