Open ohader opened 1 year ago
I found these snippets:
Oh, I see what happened.
Before my change in https://github.com/vimeo/psalm/pull/9562, the type returned by resolveHandler()
was HandlerInterface|HandlerImplementation
HandlerImplementation being a subtype of HandlerInterface, it's now naturally combined as HandlerInterface
So there's two way to see the issue here:
HandlerImplementation
because one of its child declares a taint so using this interface is risky. This is technically true but Psalm rarely makes this kind of "a subtype may possibly declare this so I need to check them all"I think the second option is the best IMHO so I'll flag this as enhancement.
https://psalm.dev/r/818815f379
This seemed to be working with
vimeo/psalm:~5.8.0
, but change somehow on the way to~5.9.0
. https://github.com/vimeo/psalm/compare/5.8.0...5.9.0 →git bisect
points to commit dfd7ffc4598e03db1e15bac82908b36ddbe51455Does not work (
~5.9.0
, tested with5.x-dev
2bbfca6)Removing
implements HandlerInterface
works in~5.9.0