Skip to content

fix(core): resolve PHPStan iterable type errors (#8732) - #9803

Closed
Chucho-Kun wants to merge 1 commit into
codeigniter4:developfrom
Chucho-Kun:fix/issue-8732-basemodel-types
Closed

fix(core): resolve PHPStan iterable type errors (#8732)#9803
Chucho-Kun wants to merge 1 commit into
codeigniter4:developfrom
Chucho-Kun:fix/issue-8732-basemodel-types

Conversation

@Chucho-Kun

@Chucho-KunChucho-Kun commented Nov 19, 2025

Copy link
Copy Markdown

Description
PHPStan errors were eliminated by reducing the baseline to 1200 errors as part of my contribution to the good first issue label
The modifications is in the branch fix/issue-8732-basemodel-types and were validated with the following command

composer phpstan:check -- --memory-limit=512M

@mergeable

mergeableBot commented Nov 19, 2025

Copy link
Copy Markdown

Hi there, Chucho-Kun! 👋

Thank you for sending this PR!

We expect the following in all Pull Requests (PRs).

Important

We expect all code changes or bug-fixes to be accompanied by one or more tests added to our test suite to prove the code works.

If pull requests do not comply with the above, they will likely be closed. Since we are a team of volunteers, we don't have any more time to work
on the framework than you do. Please make it as painless for your contributions to be included as possible.

See https://github.com/codeigniter4/CodeIgniter4/blob/develop/contributing/pull_request.md

Sincerely, the mergeable bot 🤖

@Chucho-KunChucho-Kun changed the title Fix PHPStan iterable type errors in BaseModel, CLI, LocalizationFinder, AutoRouteCollector and ModulesFix PHPStan iterable type errors in BaseModel, CLI, LocalizationFinder, AutoRouteCollector and Modules #8732Nov 19, 2025
@Chucho-KunChucho-Kun changed the title Fix PHPStan iterable type errors in BaseModel, CLI, LocalizationFinder, AutoRouteCollector and Modules #8732fix(core): resolve PHPStan iterable type errors (#8732)Nov 19, 2025
@michalsn

Copy link
Copy Markdown
Member

Thank you. Please omit any modifications related to Kint, since it was already updated in #9802.

@Chucho-Kun
Chucho-Kunforce-pushed the fix/issue-8732-basemodel-types branch from 07b45af to e887557CompareNovember 19, 2025 23:28
@neznaika0

Copy link
Copy Markdown
Contributor

For the BasicModel, I recently closed PR. We could not agree on the rules of phpDoc - phpstan or simple types.

I stopped correcting the typing.

@github-actionsgithub-actionsBot added the stale Pull requests with conflicts label Feb 1, 2026
@github-actions

Copy link
Copy Markdown

👋 Hi, @Chucho-Kun!

We detected conflicts in your PR against the base branch 🙊
You may want to sync 🔄 your branch with upstream!

Ref: Syncing Your Branch

@paulbalandan

Copy link
Copy Markdown
Member

Thanks for picking up #8732, @Chucho-Kun. Trimming the missingType.iterableValue baseline is exactly the kind of incremental cleanup we want, and the effort here is appreciated.

Unfortunately, most of this PR has been overtaken by changes that have already landed on develop, and a few of the proposed annotations would walk back to looser types than what we now ship.

Given that this has been open for ~6 months with no movement, I'm constrained to close this PR for now. Happy for you to open a refreshed PR taking a smaller slice at the baseline. Thanks again for the contribution.

Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

stalePull requests with conflicts

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants

@Chucho-Kun@michalsn@neznaika0@paulbalandan