Fix object-list filter preflight plan traversal and argument identification
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 4/5
- Tempo stimato
- 3-5 giorni
- Idoneità per principianti
- 52/100
- Tipo di issue
- Bug
- Chiarezza
- Abbastanza chiara
- Stato di attività
- Attiva
- Stack tecnologico
- fsharp, graphql
- Ambito
- api, backend-api-design
Direzione di ricerca
Inizia con il preflight della richiesta di filtro ObjectListFilter e l’attraversamento del piano eseguibile, quindi esamina la discussione della pull request collegata per il contesto. Traccia i piani di collection differiti, trasmessi, live e annidati e verifica la gestione dello stato di inclusione e l’identificazione dell’argomento nullable ObjectListFilter aggiunto dal middleware. Il lavoro è completato quando i filtri avvolti e annidati vengono sottoposti a coercizione, mentre gli argomenti di filtro esclusi o non correlati vengono accettati.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
Description
The object-list filter request preflight does not accurately follow the executable plan and can both miss invalid filters and reject valid requests.
The preflight should traverse deferred, streamed, live, and nested collection plans while only coercing the nullable ObjectListFilter argument added by the object-list filter middleware.
Source: https://github.com/fsprojects/FSharp.Data.GraphQL/pull/612#pullrequestreview-5253463363
Repro steps
-
Execute a query where an object-list filter is inside an
@defer,@stream, or@livewrapper, or inside a nested collection element plan. -
Observe that request-level filter coercion can be bypassed.
-
Execute a query containing an excluded subtree or an unrelated field with an argument such as
filter: String. -
Observe that the preflight can treat that argument as the middleware's object-list filter and reject an otherwise valid request.
Expected behavior
The preflight should:
- traverse
@defer,@stream, and@livewrappers transparently; - traverse collection element plans and nested filtered fields;
- skip nodes excluded by execution directives;
- coerce only fields whose definition contains the middleware-added nullable
ObjectListFilterargument.
Actual behavior
The traversal stops at wrappers and collection element plans, allowing wrapped or nested list filters to bypass request-level coercion. It also ignores inclusion state and identifies arguments by the name filter, which can incorrectly reject excluded subtrees or unrelated filter arguments.
Known workarounds
Avoid wrapping or nesting object-list-filtered fields and avoid unrelated arguments named filter. These are not practical general-purpose workarounds.
Related information
- Operating system: All
- Branch:
dev/ observed while reviewingtask-seq-field-streaming-fixes - .NET Runtime, CoreCLR or Mono Version: .NET 10
- Performance information, links to performance testing scripts: N/A
- Lingua principale
- F#
- Stelle
- 406
- Fork
- 74
- Merge medio
- 1g 8h
- PR unite (30g)
- 14
Guida per i contributori
Nessuna guida per i contributori indicizzata per questo repository
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.
Altre issue di fsprojects/FSharp.Data.GraphQL
-
Difficoltà 3/5 1-2 giorni Idoneità per principianti 45/100
-
fsprojects/FSharp.Data.GraphQL#573 · 1 reazione · 2 assegnatari ·
-
FR: Suave package Aperta
fsprojects/FSharp.Data.GraphQL#566 · 1 commento · 1 reazione · 2 assegnatari ·
-
Difficoltà 5/5 Più di una settimana Idoneità per principianti 30/100
-
Difficoltà 5/5 Più di una settimana Idoneità per principianti 25/100
Tutte le issue di fsprojects/FSharp.Data.GraphQL
Issue simili
-
bug priority:normal ready-for-dev
Difficoltà 2/5 1-3 ore Idoneità per principianti 88/100
OpenHands/extensions#626 · 1 commento ·
-
bug
Difficoltà 2/5 1-3 ore Idoneità per principianti 76/100
avniproject/avni-client#2135 ·
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 88/100
-
needs-triage
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
use-agent-os/agent-os#3276 ·