Skip to content

Conversation

kkmuffme
Copy link
Contributor

@kkmuffme kkmuffme commented May 14, 2025

Fix #11437

Afaik with this PR the preloadClasses="true" config option https://psalm.dev/docs/running_psalm/configuration/#stubs

In case classes to be tested use parent classes or interfaces defined in a stub file, this stub should be configured with attribute preloadClasses="true"

can be deprecated, since it's not necessary anymore. It was already unnecessary for "extends" (parent classes) from stubs since #2191 was fixed in 39f7296?w=1 and with this PR it's unnecessary for traits and interfaces too.
I didn't remove/deprecate it as part of this PR, as there might be other use cases I'm not aware of and removing (or at first marking that option deprecated) is trivial.

EDIT: eventually removing that preloadClasses would also fix/get rid of #11436

@kkmuffme kkmuffme force-pushed the fix-2191-for-traits branch from ee6a07e to 46f6525 Compare May 15, 2025 22:10
@kkmuffme kkmuffme marked this pull request as ready for review May 15, 2025 22:18
@kkmuffme
Copy link
Contributor Author

The complexity error was an issue of that method before my changes already. Do you want me to suppress it or update the baseline? (since there are tons of Circle CI "Override" errors that are unrelated, I didn't do that, since I though you might want to do that yourself on master branch directly @danog )

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant