microsoftgraph / microsoftgraph/msgraph-sdk-java
@microsoft.graph.sharedChanged annotation not set on folders in delta query with deltashowsharingchanges
Nessuno ha ancora preso questa issue.
- Lingua principale
- Java
- Stelle
- 444
- Fork
- 154
- Merge medio
- 18h 28m
- PR unite (30g)
- 4
Descrizione
Description
When using the delta query API with Prefer: deltashowremovedasdeleted, deltatraversepermissiongaps, deltashowsharingchanges headers, the @microsoft.graph.sharedChanged OData annotation is only set on files, never on folders — even when folders appear in the delta response with a shared facet.
This is an API behavior issue, not SDK-specific, but we're filing here as the docs repo has issues disabled.
Steps to reproduce
-
Get a latest delta token:
GET /drives/{drive-id}/root/delta?token=latest Headers: Prefer: deltashowremovedasdeleted, deltatraversepermissiongaps, deltashowsharingchanges -
Share a file located inside a folder hierarchy (e.g.,
root/folder/sub-folder/sample.jpg) with a specific user. -
Query delta with the token from step 1:
GET /drives/{drive-id}/root/delta?token={token} Headers: Prefer: deltashowremovedasdeleted, deltatraversepermissiongaps, deltashowsharingchanges
Actual result
The response contains 4 items. Only the file has @microsoft.graph.sharedChanged, the parent folders do not:
FOLDER root — @microsoft.graph.sharedChanged: NOT PRESENT
FOLDER folder — @microsoft.graph.sharedChanged: NOT PRESENT, shared: {scope: users}
FOLDER sub-folder — @microsoft.graph.sharedChanged: NOT PRESENT
FILE sample.jpg — @microsoft.graph.sharedChanged: true, shared: {scope: users}
Expected result
Per the documentation:
"all items that appear in the delta query response due to permission changes have the @microsoft.graph.sharedChanged: True OData annotation"
Parent folders that appear as hierarchy context (not due to their own permission change) should either:
- Have
@microsoft.graph.sharedChangedset when they are directly shared, OR - Be excluded from the response when they are only hierarchy context
Currently, folders never receive the annotation regardless of whether they were directly shared or appear as parent hierarchy. This makes it impossible to distinguish parent folder noise from real folder permission changes.
Additional testing
Tested all header combinations against the same delta token:
| Headers | Result |
|---|---|
| deltashowremovedasdeleted, deltatraversepermissiongaps, deltashowsharingchanges | 4 items, annotation only on file |
| Same + hierarchicalsharing | Identical 4 items |
| Same + deltaExcludeParent: true | Identical 4 items |
| Only deltashowsharingchanges | Identical 4 items |
| No Prefer headers | 0 items |
Environment
- API version: v1.0
- Authentication: Application permissions (client credentials)
- Service: SharePoint Online
Guida per i contributori
Apri la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Direzione di ricerca
Non è identificato alcun file del repository né alcun test; iniziare dall’endpoint documentato /drives/{drive-id}/root/delta e dagli header Prefer elencati, usando la sequenza di token fornita per riprodurre la risposta di quattro elementi. Il lavoro è completato quando il comportamento del servizio o la relativa documentazione distingue chiaramente le cartelle condivise direttamente dalle cartelle presenti solo nella gerarchia, con il comportamento previsto delle annotazioni verificato.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Valutazione
- Ambito
- api, cloud
- Tipo di issue
- Bug
- Difficoltà
- 5/5
- Tempo stimato
- Più di una settimana
- Stato di attività
- Tranquilla
- Chiarezza
- Abbastanza chiara
- Idoneità per principianti
- 25/100