Sort of following up from https://discord.com/channels/919193495116337154/1255535200318914660 I would like to reframe the issue in the subject.
Currently, the unmarshalling of classes derived from SQLAlchemy base class ignores non Mapped fields, resulting in incomplete data being passed to Controllers.
This is counterintuitive as the non Mapped fields can be used normally, outside of Litestar unmarshalling, and unmarshalling of, say, dataclasses happens for all the fields.
This is regardless of the type of the non mapped field.
The current behaviour impedes the usage of a single class for all the marshalling and unmarshalling in cases where the API exposes database entities but needs to treat certain data differently (like in relationship management, see previous topic linked above).
In my opinion this is not related to deserialization of relationships, which can still be not supported but could be managed by DTOs and proper code. This would actually enable to handle deserialization of relationships without having to resort to companion dataclasses and copy operations.
Thoughts?