Should the ServiceContainer allow the app to overload default extension classes?
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 5/5
- Tempo stimato
- Più di una settimana
- Idoneità per principianti
- 25/100
Direzione di ricerca
Inizia leggendo i punti di ingresso di ServiceContainer e DefaultServiceLoader coinvolti nella selezione dell’istanza effettiva di Request, usando l’esempio EditableRequest per riprodurre il problema. Determina la precedenza prevista quando una classe fornita dall’applicazione estende una classe di servizio predefinita, quindi aggiungi una copertura che mostri il comportamento scelto e verifica che la Request in ingresso venga risolta correttamente.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
Specific example: My app deals with editing HTTP Requests, so I have a class called EditableRequest that extends Gt\Http\Request. Because of this, the EditableRequest class is instantiated and passed to the DefaultServiceLoader as the actual Request, rather than the actual request that's coming in.
This is obviously a flaw in the system, because it should be fine for the App's service loader to supply classes that extend already-existing classes.
The question is, what should the default behaviour be? If there's already a class defined in the default service loader, should we ignore loading any extras that simply extend the base classes? I think that would be safest.
- Lingua principale
- PHP
- Stelle
- 0
- Fork
- 0
- Metriche di merge delle PR
- Nessuna PR unita negli ultimi 30g
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.
Altre issue di phpgt/ServiceContainer
-
enhancement
Difficoltà 5/5 Più di una settimana Idoneità per principianti 25/100
phpgt/ServiceContainer#145 · 1 reazione ·
-
good first issue help wanted
Difficoltà 3/5 1-2 giorni Idoneità per principianti 25/100
phpgt/ServiceContainer#143 ·
Tutte le issue di phpgt/ServiceContainer
Issue simili
-
sync-en
Difficoltà 2/5 1-3 ore Idoneità per principianti 88/100
-
sync-en
Difficoltà 2/5 1-3 ore Idoneità per principianti 84/100
-
Перевод устарел
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
-
bug good first issue
Difficoltà 2/5 1-3 ore Idoneità per principianti 84/100
az-digital/az_quickstart#6047 ·
-
Error when saving email Apertabug needs-triage
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100