Skip to content

Send initiating view share_with_team_uid in shared session InitPayload - #15631

Merged
IsaiahWitzke merged 4 commits into
masterfrom
factory/session-share-team-uid
Aug 28, 2026
Merged

Send initiating view share_with_team_uid in shared session InitPayload#15631
IsaiahWitzke merged 4 commits into
masterfrom
factory/session-share-team-uid

Conversation

@warp-agent-staging

@warp-agent-staging warp-agent-staging Bot commented Aug 28, 2026

Copy link
Copy Markdown
Contributor

Description

Resolve the initiating selected view's TeamScope into sharer InitPayload.share_with_team_uid so session create can grant the initial team guest ACL to that team. The field does not change session ownership.

Client Option<String> already preserves presence:

  • None (personal/unscoped views): proto field omitted; server uses legacy default-team fallback
  • Some(uid) (team-scoped views): proto field present; server authorizes that team
  • Some("") is not sent by this client; if present, warp-server authorizes empty and fails rather than falling back

Linked Issue

Protocol pin

warpdotdev/session-sharing-protocol#76 is squash-merged. This PR pins session-sharing-protocol to fcd0fea35ab9f782043c8ec74fd81bce187ded9f on main.

Also depends on warp-server and session-sharing-server landing so create actually uses the payload team.

Testing

  • cargo test -p warp --lib -- test_share_with_team_uid_for_init_payload
  • cargo metadata --locked
  • I have manually tested my changes locally with ./script/run

Screenshots / Videos

End-to-end visual proof of a session started from a non-default team is blocked until warp-server and SSS land together. This environment has no computer-use/GUI, and a live share against current production/staging servers would still hit the old create path.

Strongest valid proof available now: unit tests that a team-scoped view puts the selected team UID on InitPayload.share_with_team_uid and a personal view omits it. ACL persistence is covered on warp-server by TestCreateSharedSessionUsesAuthorizedNonLowestTeamGuest.

Agent Mode

  • Warp Agent Mode - This PR was created via Warp's AI Agent Mode

CHANGELOG-NONE

Resolve the selected view's TeamScope into InitPayload.team_uid so
session create can grant the initial team guest ACL to that team.
Personal and unscoped views omit the field.
@warp-agent-staging

Copy link
Copy Markdown
Contributor Author

This PR was generated with Warp.

Comment @warp-factory on this PR to send it follow-up work.

View run View conversation View on Slack

The field is the team granted initial viewer access from the initiating
view. It does not change session ownership. Pin session-sharing-protocol
to the matching protocol commit.
@warp-agent-staging warp-agent-staging Bot changed the title Send initiating view team_uid in shared session InitPayload Send initiating view share_with_team_uid in shared session InitPayload Aug 28, 2026
The protocol pin update also rewrote iana-time-zone's selected
windows-core from 0.62.2 to 0.61.2. Restore the prior selection;
only the session-sharing-protocol rev should change.
IsaiahWitzke pushed a commit to warpdotdev/session-sharing-protocol that referenced this pull request Aug 28, 2026
## Summary
Add optional `share_with_team_uid` on sharer `InitPayload` so session
create can grant the initial team guest ACL to the initiating view's
team. The field does not change session ownership; `firebase_uid`
remains the owner identity. If omitted, the server preserves legacy
behavior by selecting the owner's default team for initial viewer
access.

Related to warpdotdev/warp-server#16262

## Changes
- Optional `InitPayload.share_with_team_uid` with backward-compatible
serde (`default`, omit `None`)
- Serde coverage for missing, `None`, and `Some` payloads
- Field comment: omission is legacy default-team fallback, not "no team
share"

## Rust API compatibility
Wire format is backward compatible. Adding a public field is a Rust
source break for `InitPayload { ... }` literals.

Known constructors:
- This crate's tests
- `warp` sharer `Network`
(warpdotdev/warp#15631) — the only production
constructor; updated in lockstep
- `session-sharing-server` deserializes the payload; it does not
construct the struct
- Viewer `InitPayload` is a different type and is unchanged
- `warp-internal` mirrors the warp constructor and picks up #15631 via
repo-sync after that PR lands

Do not bump other protocol pins until warp#15631 (or the matching
internal sync) includes `share_with_team_uid`. No crate version/API
workaround; lockstep is the intended landing.

## Verification
- `cargo test --lib`:
`init_payload_deserializes_missing_share_with_team_uid_as_none`,
`init_payload_omits_none_share_with_team_uid_and_round_trips_some`

<!-- warp:pr-description-artifacts start -->
<!-- warp:pr-description-artifacts end -->

---------

Co-authored-by: warp-agent-staging[bot] <240773466+warp-agent-staging[bot]@users.noreply.github.com>
Protocol #76 squash-merged as fcd0fea35ab9f782043c8ec74fd81bce187ded9f.
Keep iana-time-zone on windows-core 0.62.2.
@IsaiahWitzke
IsaiahWitzke enabled auto-merge (squash) August 28, 2026 17:24
@IsaiahWitzke
IsaiahWitzke merged commit f9adce6 into master Aug 28, 2026
66 of 71 checks passed
@IsaiahWitzke
IsaiahWitzke deleted the factory/session-share-team-uid branch August 28, 2026 21:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant