You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@avro.apache.org by "ASF subversion and git services (Jira)" <ji...@apache.org> on 2022/01/24 08:52:00 UTC

[jira] [Commented] (AVRO-3314) ArgumentOutOfRangeException thrown in AvroDecimal IConvertable.ToType

    [ https://issues.apache.org/jira/browse/AVRO-3314?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17480921#comment-17480921 ] 

ASF subversion and git services commented on AVRO-3314:
-------------------------------------------------------

Commit 8a06ea3107664bc0083883459e4d4839ab7dd6b4 in avro's branch refs/heads/master from Kyle Schoonover
[ https://gitbox.apache.org/repos/asf?p=avro.git;h=8a06ea3 ]

AVRO-3314 Updated exception thrown by IConvertable.ToType (#1467)

Co-authored-by: Kyle T. Schoonover <Ky...@nordstrom.com>

> ArgumentOutOfRangeException thrown in AvroDecimal IConvertable.ToType
> ---------------------------------------------------------------------
>
>                 Key: AVRO-3314
>                 URL: https://issues.apache.org/jira/browse/AVRO-3314
>             Project: Apache Avro
>          Issue Type: Improvement
>          Components: csharp
>    Affects Versions: 1.11.0
>            Reporter: Kyle Schoonover
>            Priority: Minor
>              Labels: pull-request-available
>          Time Spent: 0.5h
>  Remaining Estimate: 0h
>
> IConvertable.ToType is throwing an ArgumentOutOfRangeException, which is not the correct exception to throw since the arguments being passed are not what can cause the exception.  This should be changed to an ArithmeticException, specifically an OverflowException.
> For reference: [ArithmeticException Class (System) | Microsoft Docs|https://docs.microsoft.com/en-us/dotnet/api/system.arithmeticexception?view=net-6.0]



--
This message was sent by Atlassian Jira
(v8.20.1#820001)