500 Internal Server Error While Attempting to Create Private Repository #40491
Unanswered
kdelorey
asked this question in
API and Webhooks
Replies: 2 comments 1 reply
-
Hi there @kdelorey and welcome to our community! Thank you for asking a great question 🙂 To get started, introduce yourself in our official introduction thread |
Beta Was this translation helpful? Give feedback.
0 replies
-
@kdelorey do you have solution for that? |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Select Topic Area
Bug
Body
While playing around with the GitHub Terraform provider, I discovered that attempts to create a private GitHub repository results in a 500 Internal Server Error. Note this isn't specific Terraform, just how I discovered the issue.
If try to make the same request Terraform attempts to do in any HTTP client (eg.
curl
) the same result occurs. For example, aPOST
tohttps://api.github.com/user/repos
with the following body results in the error:After experimenting with it for a little while, it seems you can change the
"private": true
boolean value into a string like"private": "true"
, and the API successfully create a private repo. However according to the API documentation,private
is expected to be aboolean
type, with a provided example of it being a boolean too. So I don't think its appropriate to file an issue with the TF provider project, as it is making the request correctly as I understand it.I should also note that changes to the
visibility
property, including removing it completely, has no effect when making the request. The API doesn't actually expect this property to be present when making an user repository, but the TF provider puts it in the request regardless.Beta Was this translation helpful? Give feedback.
All reactions