Skip to content

Remember stub files and their errors in result cache #5826

@dktapps

Description

@dktapps

Feature request

While debugging #5825 , I'm discovering a range of interesting problems, mostly due to Windows' slow I/O.

I found it interesting that StubValidator doesn't use the result cache at all, because validating stubs takes nearly 25% of the pre-analysis step time (under xdebug that's about 1 second out of 4; at normal runtime it would be closer to 300ms).

This might seem insignificant, but I find it odd that stubs aren't remembered by the result cache like normal files.

I'm looking to save all the pre-analyse time I can find here, because this pre-analyse lag is a pretty huge annoyance for using PHPStan on Windows (particularly when integrated with PHPStorm, because it takes quite some time to respond - 300ms is a pretty significant amount of time in that case).

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions