You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{:error,{Cldr.UnknownCurrencyError,"The currency \"AAA\" is invalid"}}
This violates the typespec for Ecto.Type.cast: cast(term()) :: {:ok, term()} | {:error, keyword()} | :error, and causes an exception when used in Ecto.Changeset.cast
Please see this demo repo for a demonstration of the issue.
Incidentally, it appears that the load functions also violate the error typespec from Ecto.Type.
The text was updated successfully, but these errors were encountered:
When casting an invalid currency, the both ecto types return an error tuple with another tuple as the second element.
money_sql/test/money_ecto_test.exs
Line 72 in bbc4f69
This violates the typespec for
Ecto.Type.cast
:cast(term()) :: {:ok, term()} | {:error, keyword()} | :error
, and causes an exception when used inEcto.Changeset.cast
Please see this demo repo for a demonstration of the issue.
Incidentally, it appears that the
load
functions also violate the error typespec from Ecto.Type.The text was updated successfully, but these errors were encountered: