Skip to content

Boolean from response should include all successful 2XX response codes#1791

Open
PatBanks wants to merge 3 commits intooctokit:mainfrom
PatBanks:boolean-from-response-should-include-200-response-code
Open

Boolean from response should include all successful 2XX response codes#1791
PatBanks wants to merge 3 commits intooctokit:mainfrom
PatBanks:boolean-from-response-should-include-200-response-code

Conversation

@PatBanks
Copy link

@PatBanks PatBanks commented Dec 19, 2025

Resolves #1790


Before the change?

  • Workflow dispatch events started returning 200 rather than 204. boolean_from_response does not consider the entire successful response http code range.

After the change?

  • boolean_from_response now considers any 2XX response code as valid

Pull request checklist

  • Tests for the changes have been added (for bug fixes / features)
  • Docs have been reviewed and added / updated if needed (for bug fixes / features)

Does this introduce a breaking change?

  • I do not believe this introduces a breaking change. The output type of the method does not change.

@github-actions
Copy link

👋 Hi! Thank you for this contribution! Just to let you know, our GitHub SDK team does a round of issue and PR reviews twice a week, every Monday and Friday! We have a process in place for prioritizing and responding to your input. Because you are a part of this community please feel free to comment, add to, or pick up any issues/PRs that are labeled with Status: Up for grabs. You & others like you are the reason all of this works! So thank you & happy coding! 🚀

@PatBanks PatBanks changed the title Boolean from response should include 200 response code Boolean from response should include all successful 2XX response codes Dec 19, 2025
even if the response is a 205, it would still signify the server successfully completed the request... so unexpected reponse codes maybe could be a redirect instead.
@enescakir
Copy link

It returns HTTP 200 with a body, so it's not a boolean anymore. It should return the body as well.

#1789

@PatBanks
Copy link
Author

PatBanks commented Dec 19, 2025

It returns HTTP 200 with a body, so it's not a boolean anymore. It should return the body as well.

#1789

I agree, but is that a breaking change to octokit that would require a major bump? I assumed so. I could reduce this down to just adding the 200 🤷 or if that's wrong I can just close this

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: 🆕 Triage

Development

Successfully merging this pull request may close these issues.

[BUG]: Workflow dispatch events are now suddenly returning 200 for success from the API

3 participants