Teams bridge fetches each channel's description from Graph and never uses it
Maintainers usually reply within 1 day
Nobody has claimed this yet.
Assessment
- Difficulty
- 1/5
- Estimated time
- Under an hour
- Newbie friendliness
- 85/100
Research direction
Open bridges/collaboration/teams/graph.py and find the $select in TeamsGraphClient.get_channel; confirm nothing in bridges/collaboration/teams/adapter.py or elsewhere in the bridge reads channel.get("description"). Then remove description from the $select list, keeping the comment about email/summary/layoutType intact, and check the Microsoft Teams docs page that lists Channel.ReadBasic.All scopes so the documented field list matches. Done means the per-channel request asks for four fields and the Teams bridge tests still pass.
Written by the indexing model from the issue text.
Description
Summary
The Teams bridge asks Microsoft Graph for each channel's description and never uses it. It is fetched on every per-channel read and discarded.
Verified at switch-v0.32.1.
Detail
TeamsGraphClient.get_channel selects five fields (bridges/collaboration/teams/graph.py):
params={"$select": "id,displayName,description,membershipType,layoutType"},
The callers keep three of them — displayName into _channel_names, membershipType via _channel_type_of, layoutType into _channel_layouts (adapter.py, around the two _channel_layouts[channel_id] = ... assignments). description is read from Graph and dropped: there is no channel.get("description") anywhere in the bridge.
The $select is deliberate and well commented — it exists to avoid Graph populating the expensive email and summary fields, and because layoutType is only returned by the per-channel read. description looks like it was included for symmetry rather than for a consumer.
Why it is worth fixing
Small, but it is customer-visible in the wrong way: the Microsoft Teams page documents Channel.ReadBasic.All by telling an administrator what Switch reads from a channel. An admin reviewing the grant, or a privacy reviewer reading that page, is entitled to expect the list to be complete. Right now the honest list is four fields, one of which Switch has no use for.
Fetching and discarding a free-text field that users write into is unnecessary collection, and it makes the documentation either incomplete or awkward.
Suggested fix
Drop description from the $select, so what Switch reads matches what it uses — and what the page says.
- Dominant language
- Python
- Stars
- 4.5k
- Forks
- 348
- Avg merge
- 1d 17h
- Merged PRs (30d)
- 287
Getting set up
- No Dockerfile or Docker Compose file
- Has a pull request template
- Read the contributing guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from sandbox-quantum/switch
-
Console writes URL credentials to the local log, though AGENTS.md says secrets never reach diskOpen
Difficulty 1/5 Under an hour Newbie friendliness 86/100
sandbox-quantum/switch#2163 ·
Maintainers usually reply within 1 day
-
Difficulty 1/5 Under an hour Newbie friendliness 85/100
sandbox-quantum/switch#2159 · 1 comment ·
Maintainers usually reply within 1 day
-
Difficulty 1/5 Under an hour Newbie friendliness 85/100
sandbox-quantum/switch#2157 ·
Maintainers usually reply within 1 day
-
Get-Switch-Console link points at a path that only resolves via a redirectPossibly taken @Darshan3690 claimed this 3 days ago. Open
Difficulty 1/5 Under an hour Newbie friendliness 85/100
sandbox-quantum/switch#1998 · 2 comments ·
Maintainers usually reply within 1 day
-
A session's age is not surfaced, so you cannot tell how old an agent's context isPossibly taken A pull request linked to this issue is open or already merged. Openenhancement
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
sandbox-quantum/switch#1993 ·
Maintainers usually reply within 1 day
All issues in sandbox-quantum/switch
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
mohanraj00/entelos#200 ·
Maintainers usually reply within 1 day
-
Difficulty 1/5 Under an hour Newbie friendliness 68/100
-
sweep
Difficulty 2/5 1-3 hours Newbie friendliness 85/100
bketelsen/truenas-mcp#77 ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 74/100
openedx/xblock-lti-consumer#765 ·
Maintainers usually reply within 1 day
-
bug pydanty:is-working
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
pydantic/pydantic-ai#13939 ·
Maintainers usually reply within 1 day