From 6935b7625a86011af7e4dce89ce351799f95cae5 Mon Sep 17 00:00:00 2001 From: Greg Gilbert Date: Tue, 15 Feb 2022 13:25:59 -0500 Subject: [PATCH 1/3] Allow more deployment statuses per Github docs --- src/github3/repos/deployment.py | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/src/github3/repos/deployment.py b/src/github3/repos/deployment.py index 798da5c2..a8ec5254 100644 --- a/src/github3/repos/deployment.py +++ b/src/github3/repos/deployment.py @@ -77,7 +77,8 @@ def create_status(self, state, target_url=None, description=None): :param str state: (required), The state of the status. Can be one of - ``pending``, ``success``, ``error``, or ``failure``. + ``pending``, ``success``, ``error``, ``inactive``, + ``in_progress``, ``queued``, or ``failure``. :param str target_url: The target URL to associate with this status. This URL should contain output to keep the user updated while the @@ -92,7 +93,15 @@ def create_status(self, state, target_url=None, description=None): """ json = None - if state in ("pending", "success", "error", "failure"): + if state in ( + "pending", + "success", + "error", + "inactive", + "in_progress", + "queued", + "failure", + ): data = { "state": state, "target_url": target_url, From f4314e8f3da9ac92be7ee38567f16d018efc99be Mon Sep 17 00:00:00 2001 From: Greg Gilbert Date: Tue, 15 Feb 2022 14:27:10 -0500 Subject: [PATCH 2/3] Bump release notes, add self to authors --- AUTHORS.rst | 2 ++ docs/source/release-notes/3.2.0.rst | 16 ++++++++++++++++ docs/source/release-notes/index.rst | 1 + 3 files changed, 19 insertions(+) create mode 100644 docs/source/release-notes/3.2.0.rst diff --git a/AUTHORS.rst b/AUTHORS.rst index 46733406..93f8fd8e 100644 --- a/AUTHORS.rst +++ b/AUTHORS.rst @@ -210,3 +210,5 @@ Contributors - Thomas Lam (@lamcw) - David Glick (@davisagli) + +- Greg Gilbert (@greggilbert) \ No newline at end of file diff --git a/docs/source/release-notes/3.2.0.rst b/docs/source/release-notes/3.2.0.rst new file mode 100644 index 00000000..9e88a51d --- /dev/null +++ b/docs/source/release-notes/3.2.0.rst @@ -0,0 +1,16 @@ +3.2.0: 2022-xx-xx +----------------- + +Dependency Change +````````````````` + + +Features Added +`````````````` + +- Added more allowed statuses to Deployments for + :meth:`github3.repos.deployment.Deployment.create_status()` + + +Bug Fixes +````````` diff --git a/docs/source/release-notes/index.rst b/docs/source/release-notes/index.rst index 4c84eb56..fb031f69 100644 --- a/docs/source/release-notes/index.rst +++ b/docs/source/release-notes/index.rst @@ -9,6 +9,7 @@ here with the newest releases first. ================== .. toctree:: + 3.2.0 3.1.0 3.0.0 From 40b9f2e037ae6dc71b9385f03ecd7890718fd35e Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Tue, 15 Feb 2022 19:47:24 +0000 Subject: [PATCH 3/3] [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci --- AUTHORS.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/AUTHORS.rst b/AUTHORS.rst index 93f8fd8e..aa8a20b9 100644 --- a/AUTHORS.rst +++ b/AUTHORS.rst @@ -211,4 +211,4 @@ Contributors - David Glick (@davisagli) -- Greg Gilbert (@greggilbert) \ No newline at end of file +- Greg Gilbert (@greggilbert)