Repository navigation
Conversation
models_soup held the Soup wire models and also the conversions from the call, channels, crm and email domain models into them, so the DTO crate depended on four domain crates and its closure was 99 workspace crates. Each domain crate now owns its conversion in a soup module (From impls, plus call::soup::soup_call_record_for_user for the viewer-relative call record). The email conversions are hand-written instead of doppleganger derives, field for field. models_soup drops call, channels, crm, email and doppleganger, and its closure falls to 17 crates (models_search 104 -> 22). Wire shapes are unchanged: no Soup type was edited. MACRO-4973
|
Important Review skippedAuto incremental reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the
|
…p-conversions # Conflicts: # Cargo.lock
…unchanged MACRO-4973
|
Folded into the single reorg PR #10111 (one PR for the whole reorganization). Its commits are there; closing this one. |
Why
Part of the repository reorganization (plan item N10).
models_soupis thecrate of Soup wire models, but it also held the conversions from the
call,channels,crmandemaildomain models into those wire models.That made a DTO crate depend on four domain crates. Its closure was 99
workspace crates, and
models_searchreached 104 through it.MACRO-4973
How it works
soupmodule:channels::soup(behind its existinglistfeature) turns the oldnew_from_*constructors intoFrom/TryFromimpls.crm::soupandemail::souphold theFromimpls.call::soup::soup_call_record_for_userreplacesSoupCallRecord::from_record_for_user, because it needs the viewer. Itstests move with it, with placeholder emails changed to
example.com.dopplegangerbackwardderives on the Souptypes. They are now hand-written
Fromimpls, field for field, becausethe derive has to sit on the Soup type and so needs the email crate.
SoupMessageSender::from_message_senderstays inmodels_soupand takesthe bot's name and avatar instead of
channels::BotSenderProfile. Itparses through
channel_sender(the cratechannelsre-exports it from)instead of
channels.soup::domain::serviceuses the newFromimpls and function.No Soup type changed, so serde and utoipa output are identical.
models_soupmodels_searchsearch_servicesoup,ai_tools,graphql_soupand others are unchanged, because theydepend on the domain crates directly.