More precise typing for MainClass.get_user() (#1575)

Use typing.overload for MainClass.get_user() since it can return two
disparate types. Correct the docstring for it, as well as locking down
Sphinx to <3 due to built docs issue and drive-by link correction.

Fixes #1550
This commit is contained in:
Steve Kowalik
2020-06-24 16:21:18 +10:00
committed by GitHub
parent f0f6ec83dd
commit 3668f866e3
5 changed files with 11 additions and 8 deletions
+3 -1
View File
@@ -126,6 +126,7 @@ class ProjectColumn(github.GithubObject.CompletableGithubObject):
:param note: string
:param content_id: integer
:param content_type: string
:rtype :class:`github.ProjectCard.ProjectCard`:
"""
if isinstance(note, str):
@@ -150,6 +151,7 @@ class ProjectColumn(github.GithubObject.CompletableGithubObject):
"""
:calls: `POST POST /projects/columns/:column_id/moves <https://developer.github.com/v3/projects/columns/#move-a-project-column>`_
:param position: string
:rtype: bool
"""
assert isinstance(position, str), position
@@ -164,7 +166,7 @@ class ProjectColumn(github.GithubObject.CompletableGithubObject):
def delete(self):
"""
:calls: `DELETE /projects/columns/:column_id <https://developer.github.com/v3/projects/columns/#delete-a-project-column`_
:calls: `DELETE /projects/columns/:column_id <https://developer.github.com/v3/projects/columns/#delete-a-project-column>`_
:rtype: bool
"""
status, _, _ = self._requester.requestJson(