You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit e2788b6
Browse filesBrowse the repository at this point in the historyBrowse files
Reproduce the result cache keeping an error from a rule built on collected data
Rules that read collected data run in AnalyserResultFinalizer, and the result
cache is written before that, so their errors are never in the cached error
map. That map is what restore() sweeps when a new file appears - the recovery
for an error that could record no dependency, because the symbol it is about
did not exist yet. A file whose only error comes from collected data is never
in that sweep, so it keeps the error after the symbol arrives, while a run
from a cleared cache reports nothing.
src/Caller.php calls an unqualified function that falls back to a pure global
one, so its only error comes from a CollectedDataNode rule. src/PlainCaller.php
has an ordinary error and is there to prove the sweep ran at all. Creating
src/nsfns.php defines both missing symbols at once: the ordinary error goes
away, the collector-backed one does not.
The test fails: the cached run reports one error and exits 1, a run with a
cleared cache reports none.
Amp-Thread-ID: https://ampcode.com/threads/T-01a19219-5899-7222-8fa0-6cb7e6fb7182
0 commit comments