Review DeprecatedHookImplementation for removal
I maintainer di solito rispondono entro 1 giorno
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 2/5
- Tempo stimato
- 1-3 ore
- Idoneità per principianti
- 55/100
Direzione di ricerca
Read src/Rules/Deprecations/DeprecatedHookImplementation.php and tests/src/Rules/DeprecatedHookImplementationTest.php, then check rules.neon and extension.neon to confirm the rule is unregistered. The issue favors removing the rule and its test; done means both are removed and the remaining configuration and tests no longer refer to them. The alternative requires a concrete plan to generalize the rule.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
Background
src/Rules/Deprecations/DeprecatedHookImplementation.php was added in November 2023 but has never been registered in rules.neon or extension.neon. It silently does nothing for users of this package.
Problems
- Never registered — the rule is not wired into any neon config, so no one is getting its checks.
- Hardcoded and stale — the only specific deprecation it detects is
hook_field_widget_multivalue_form_alter(a Drupal 9→10 deprecation), hardcoded with a@todoacknowledging the approach is not extensible or intelligent. - Superseded — Drupal 10+ hook deprecations are better handled via the Hook attribute system, which is already covered by other rules in this project.
Proposed resolution
Either:
- Remove
src/Rules/Deprecations/DeprecatedHookImplementation.phpand its testtests/src/Rules/DeprecatedHookImplementationTest.php— the rule has never been active and the hardcoded hook it targets is an obsolete D9→D10 migration concern. - Or register and rewrite it using a data-driven approach if detecting deprecated procedural hook implementations is still a desired feature.
Given the narrow scope and the stale hardcoded logic, removal is the cleaner path unless there is a concrete plan to generalize it.
- Lingua principale
- PHP
- Stelle
- 208
- Fork
- 88
- Merge medio
- 2g 17h
- PR unite (30g)
- 15
Preparare l'ambiente
Questo progetto non fornisce container di sviluppo, Dockerfile né guida per i contributori, quindi l'ambiente è a tuo carico: parti dal suo README e consulta la nostra guida al primo contributo per i passaggi generali.
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 mglaman/phpstan-drupal
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 84/100
mglaman/phpstan-drupal#1078 ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 4/5 3-5 giorni Idoneità per principianti 55/100
mglaman/phpstan-drupal#1079 ·
I maintainer di solito rispondono entro 1 giorno
-
Report constraint plugins that break on Drupal 12 because they have no named-arguments constructorForse già presa @goba l’ha presa 1 giorno fa. Aperta
Difficoltà 4/5 3-5 giorni Idoneità per principianti 35/100
mglaman/phpstan-drupal#1075 ·
I maintainer di solito rispondono entro 1 giorno
-
Magic properties: original on entities, name on UserSession and password on User are not reported as deprecatedForse già presa @goba l’ha presa 1 giorno fa. Aperta
Difficoltà 3/5 1-2 giorni Idoneità per principianti 35/100
mglaman/phpstan-drupal#1074 ·
I maintainer di solito rispondono entro 1 giorno
-
enhancement
Difficoltà 5/5 Più di una settimana Idoneità per principianti 25/100
mglaman/phpstan-drupal#1051 ·
I maintainer di solito rispondono entro 1 giorno
Tutte le issue di mglaman/phpstan-drupal
Issue simili
-
sync-en
Difficoltà 1/5 1-3 ore Idoneità per principianti 75/100
I maintainer di solito rispondono entro 1 giorno
-
repo:cms
Difficoltà 2/5 1-3 ore Idoneità per principianti 84/100
craftcms/cms#20596 · 1 commento ·
I maintainer di solito rispondono entro 1 giorno
-
[Type] Bug
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 86/100
I maintainer di solito rispondono entro 4 giorni
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 73/100
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 76/100
Automattic/blocks-engine#5444 ·
I maintainer di solito rispondono entro 1 giorno