-
Notifications
You must be signed in to change notification settings - Fork 1.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[BUG]: Int32 overflow for Github object ids #2893
Comments
Upgrading the |
I can still repro this with 11.0.1 for deployment environments. I have one with an ID of octokit.net/Octokit/Models/Response/DeploymentEnvironment.cs Lines 28 to 31 in 615dee9
|
I would do a PR to fix it, but fixing it properly is a lottttttttt of breaking changes. |
I still getting the error on version await client.Issue.Comment.GetAllForIssue("myOrganization", "MyRepository", 195325) or await client.Issue.Comment.Create("myOrganization", "MyRepository", 195325, "Some Comment"); 500 - at System.Convert.ThrowInt32OverflowException()
at System.Convert.ToInt32(Int64 value)
at System.Convert.ChangeType(Object value, Type conversionType, IFormatProvider provider)
at Octokit.PocoJsonSerializerStrategy.DeserializeObject(Object value, Type type) in /_/Octokit/SimpleJson.cs:line 1437
at Octokit.Internal.SimpleJsonSerializer.GitHubSerializerStrategy.DeserializeObject(Object value, Type type) in /_/Octokit/Http/SimpleJsonSerializer.cs:line 205
at Octokit.PocoJsonSerializerStrategy.DeserializeObject(Object value, Type type) in /_/Octokit/SimpleJson.cs:line 1492
at Octokit.Internal.SimpleJsonSerializer.GitHubSerializerStrategy.DeserializeObject(Object value, Type type) in /_/Octokit/Http/SimpleJsonSerializer.cs:line 205
at Octokit.PocoJsonSerializerStrategy.DeserializeObject(Object value, Type type) in /_/Octokit/SimpleJson.cs:line 1519
at Octokit.Internal.SimpleJsonSerializer.GitHubSerializerStrategy.DeserializeObject(Object value, Type type) in /_/Octokit/Http/SimpleJsonSerializer.cs:line 205
at Octokit.SimpleJson.DeserializeObject(String json, Type type, IJsonSerializerStrategy jsonSerializerStrategy) in /_/Octokit/SimpleJson.cs:line 584
at Octokit.SimpleJson.DeserializeObject[T](String json, IJsonSerializerStrategy jsonSerializerStrategy) in /_/Octokit/SimpleJson.cs:line 596
at Octokit.Internal.SimpleJsonSerializer.Deserialize[T](String json) in /_/Octokit/Http/SimpleJsonSerializer.cs:line 22
at Octokit.Internal.JsonHttpPipeline.DeserializeResponse[T](IResponse response) in /_/Octokit/Http/JsonHttpPipeline.cs:line 44
at Octokit.Connection.Run[T](IRequest request, CancellationToken cancellationToken, Func`2 preprocessResponseBody) in /_/Octokit/Http/Connection.cs:line 752
at Octokit.ApiConnection.GetPage[TU](Uri uri, IDictionary`2 parameters, String accepts, ApiOptions options, Func`2 preprocessResponseBody)
at Octokit.ApiConnection.<>c__DisplayClass20_0`1.<<GetAll>b__0>d.MoveNext() in /_/Octokit/Http/ApiConnection.cs:line 240
--- End of stack trace from previous location ---
at Octokit.ApiPagination.GetAllPages[T](Func`1 getFirstPage, Uri uri) in /_/Octokit/Clients/ApiPagination.cs:line 23\
|
Also having the issue here with 11.0.1. We're calling And for dotnet/maui#18618 we get the exception But dotnet/maui#22580 and dotnet/maui#20012 work fine. |
Also I'm getting this issue in 11.0.1 Calling
|
bump. 👍🏼 |
What happened?
Running
Returns
System.OverflowException: 'Value was either too large or too small for an Int32.'
When attempting to parse the Github.id field in the response.
Versions
Octokit.nupkg 10.0.0 (.net)
Relevant log output
Code of Conduct
The text was updated successfully, but these errors were encountered: