Add optional team_uid to sharer InitPayload - #75
Conversation
Shared-session create needs the initiating view team so warp-server can grant the initial team viewer guest instead of falling back to the user's lowest team ID. The field is serde-defaulted so older clients remain compatible.
|
This PR was generated with Warp. Comment |
|
@warp-agent-staging[bot] I'm starting a first review of this pull request. You can view the conversation on Warp. I completed the review and no human review was requested for this pull request. Comment Powered by Oz |
There was a problem hiding this comment.
Overview
This PR extends InitPayload with an optional team_uid and adds serde coverage for missing, present, and round-tripped values.
Concerns
- The new field documentation says empty values are treated as unset, but the serde implementation currently preserves an empty string as
Some("").
Verdict
Found: 0 critical, 1 important, 0 suggestions
Request changes
Comment /warp-agent-review on this pull request to retrigger a review (up to 3 times on the same pull request).
Powered by Oz
| pub source_type: SessionSourceType, | ||
|
|
||
| /// The initiating view's team UID. Used as the initial team viewer guest | ||
| /// when creating the shared session. Absent or empty is treated as unset. |
There was a problem hiding this comment.
Option<String> with #[serde(default)] deserializes "" as Some(""); add a custom deserializer with coverage for the empty-string case or remove the empty-string guarantee.



Summary
Adds optional
team_uidto sharerInitPayloadso session create can carry the initiating view team. Older clients omit the field and deserialize it as unset.Fixes warpdotdev/warp-server#16262.
Requester: Isaiah (Slack ID U09M0TE5RV1)
Origin: https://warpdev.slack.com/archives/C0BREN45G2D/p1787882708393869
Changes
InitPayload.team_uidwith#[serde(default)]Verification
cargo testin session-sharing-protocol: 3 tests passed