From 1da600a343e41c284277c71cbf81ccb651de5252 Mon Sep 17 00:00:00 2001 From: sshekdar-VMware <87147229+sshekdar-VMware@users.noreply.github.com> Date: Sun, 10 Oct 2021 21:44:03 -0700 Subject: [PATCH] Fix: #1671 Convert Python Bool to API Parameter for Authenticated User Notifications (#2001) The parameters 'all' and 'participating' for AuthenticatedUser.get_notifications() should be lower case strings, not textual forms of a boolean. Fixes: #1671 --- github/AuthenticatedUser.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/github/AuthenticatedUser.py b/github/AuthenticatedUser.py index 9f9993d56a..19dfe4e442 100644 --- a/github/AuthenticatedUser.py +++ b/github/AuthenticatedUser.py @@ -973,9 +973,11 @@ def get_notifications( params = dict() if all is not github.GithubObject.NotSet: - params["all"] = all + # convert True, False to true, false for api parameters + params["all"] = "true" if all else "false" if participating is not github.GithubObject.NotSet: - params["participating"] = participating + # convert True, False to true, false for api parameters + params["participating"] = "true" if participating else "false" if since is not github.GithubObject.NotSet: params["since"] = since.strftime("%Y-%m-%dT%H:%M:%SZ") if before is not github.GithubObject.NotSet: