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
Database Adapter and Versions (postgrex, myxql, etc)
0.19.1
Current behavior
This is related to the issue #4514 and the merged PR #4516.
I wanted to further discuss three things:
Missing case: when the type is {:map, _} the schemaless changeset is not converted.
The nested schemaless changeset is converted to an atoms key map (instead of a strings key map).
We're not checking if the changeset is actually a schemaless changeset.
Expected behavior
{:map, _} types should be handled as well.
A map with string keys should be returned, as that's what is most likely expected by code working with these schemas. The Ecto field type says it's a map with string keys. The data should be consistent with the type. It shouldn't be a strings map in some cases and an atoms map in others.
Should we check?
I'd like to propose to alter apply_changes/1 like this:
Elixir version
1.16.3
Database and Version
13.16
Ecto Versions
3.12.3
Database Adapter and Versions (postgrex, myxql, etc)
0.19.1
Current behavior
This is related to the issue #4514 and the merged PR #4516.
I wanted to further discuss three things:
{:map, _}
the schemaless changeset is not converted.Expected behavior
{:map, _}
types should be handled as well.I'd like to propose to alter
apply_changes/1
like this:The text was updated successfully, but these errors were encountered: