Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
163 commits
Select commit Hold shift + click to select a range
ca0ca4d
docs: add changelog and upgrade for v4.7.5 (#10381)
paulbalandan Jul 7, 2026
f42352a
docs: update release docs and remove legacy release scripts (#10382)
paulbalandan Jul 7, 2026
bafa1b6
chore: remove legacy docbot and apibot scripts (#10383)
paulbalandan Jul 7, 2026
d43762f
chore(deps-dev): update boundwize/structarmed requirement (#10386)
dependabot[bot] Jul 7, 2026
192c22f
chore: enable RemoveDuplicatedReturnSelfDocblockRector (#10389)
samsonasik Jul 8, 2026
4a7d144
fix: safely interpolate logger context values (#10384)
michalsn Jul 8, 2026
d99d257
chore: automate CHANGELOG.md generation for releases (#10390)
paulbalandan Jul 8, 2026
1533c85
chore: add script to audit changelog labels on merged PRs (#10391)
paulbalandan Jul 8, 2026
cd312f3
refactor(HTTP): split setCURLOptions into category helper methods to …
gr8man Jul 8, 2026
76b040a
chore: automate "Config" and "All Changes" sections of the upgrade gu…
paulbalandan Jul 8, 2026
dca192e
chore: add "Verify Release" workflow to automate post-release checks …
paulbalandan Jul 8, 2026
f9c71a7
chore: add script to sync release branches (#10394)
paulbalandan Jul 8, 2026
8b8c9e4
refactor: use `array-key` as the benevolent union of `int|string` in …
paulbalandan Jul 9, 2026
90b2e54
fix: resolve global state pollution causing random-order test failure…
gr8man Jul 9, 2026
5b46a44
chore(deps-dev): update rector/rector requirement (#10398)
dependabot[bot] Jul 9, 2026
0c101bd
chore(deps): bump actions/labeler in / (#10399)
dependabot[bot] Jul 10, 2026
7d07ce2
test: fix Session tests execution in random order (#10370)
gr8man Jul 11, 2026
8c164d0
chore(deps-dev): bump the composer-dependencies group across 1 direct…
dependabot[bot] Jul 13, 2026
b635434
chore(deps-dev): update boundwize/structarmed requirement (#10408)
dependabot[bot] Jul 14, 2026
e5719b5
fix: omit empty CSP headers (#10412)
michalsn Jul 17, 2026
95e25ec
fix: resolve service registry pollution in CSRFTest (#10373)
gr8man Jul 18, 2026
b030c75
chore(deps): bump actions/setup-node in / (#10409)
dependabot[bot] Jul 18, 2026
7505c73
test: fix cache test race conditions (#10413)
michalsn Jul 18, 2026
d1b316e
chore: clarify branch rebase workflow (#10416)
michalsn Jul 19, 2026
9ac583d
chore(deps-dev): update boundwize/structarmed requirement (#10419)
dependabot[bot] Jul 20, 2026
d23e5d7
chore(deps): bump actions/checkout in / (#10420)
dependabot[bot] Jul 21, 2026
ea14a55
chore(deps): bump actions/labeler in / (#10424)
dependabot[bot] Jul 22, 2026
3086d65
chore(deps-dev): update boundwize/structarmed requirement (#10426)
dependabot[bot] Jul 22, 2026
7063535
chore(deps): bump actions/setup-python in / (#10421)
dependabot[bot] Jul 22, 2026
aa7f6bb
fix: remove destructive setServerArray([]) in FiltersTest::setUp to p…
gr8man Jul 22, 2026
2a30043
fix: resolve TypeError in CLIRequest::parseCommand when argv is missi…
gr8man Jul 22, 2026
99ef7c8
fix: resolve race conditions in Redis TTL and prevent cache test stat…
gr8man Jul 22, 2026
c542e41
test: Increase Email test coverage and enable component in random tes…
gr8man Jul 22, 2026
bfa7a49
refactor: Enable Rector Code Quality set (#10429)
samsonasik Jul 25, 2026
fc43123
chore: add instructions for coding agents and Copilot review (#10428)
michalsn Jul 28, 2026
977c8d7
chore(deps-dev): bump the composer-dependencies group with 2 updates …
dependabot[bot] Jul 28, 2026
55f9876
chore: update PHPStan baseline and Rector config (#10431)
michalsn Jul 29, 2026
f3829fe
chore: Make use of ^0.15 for structarmed dependency (#10433)
samsonasik Jul 29, 2026
299033f
fix: handle null results in get_dir_file_info() (#10407)
gr8man Jul 31, 2026
0d1d224
test: cover GDHandler save failures and unsupported image types (#10414)
gr8man Jul 31, 2026
ba6c224
chore(deps-dev): update rector/rector requirement (#10437)
dependabot[bot] Aug 7, 2026
520fec9
chore(deps-dev): update rector/rector requirement from 2.5.9 to 2.6.1…
dependabot[bot] Aug 11, 2026
39e6884
refactor: fix uses of `empty()` calls (#10439)
paulbalandan Aug 11, 2026
29d26fe
refactor: fix `method.alreadyNarrowedType` errors (#10440)
paulbalandan Aug 12, 2026
f9f18fb
refactor: cleanup the Images library (#10441)
paulbalandan Aug 12, 2026
f4ad14b
refactor: add generics to `Entity` and `DataCaster` casts (#10442)
paulbalandan Aug 12, 2026
6430554
fix: skip unreadable `.env` in `Boot::loadDotEnv` for separate-proces…
gr8man Aug 12, 2026
4e13c9e
refactor: fix `ternary.shortNotAllowed` errors (#10445)
paulbalandan Aug 12, 2026
c42ffa8
docs: warn against untrusted paths in UploadedFile move()/store() (#1…
michalsn Aug 12, 2026
f0c1f2c
refactor: fix `missingType.property` errors (#10447)
paulbalandan Aug 13, 2026
a42d0bc
refactor: fix `return.type` errors (#10448)
paulbalandan Aug 13, 2026
7fe8e64
refactor: add generics to `Forge`, `BaseBuilder` and `BasePreparedQue…
paulbalandan Aug 13, 2026
22a237c
refactor: fix `nullCoalesce.property` errors (#10450)
paulbalandan Aug 13, 2026
9e990b5
refactor: add precise return type to `CodeIgniter::getPerformanceStat…
soccerlover29 Aug 14, 2026
e57247f
refactor: fix `property.nonObject` errors (#10451)
paulbalandan Aug 14, 2026
ef04fcf
refactor: sidestep PhpStorm warning on `@method` docblock in `Model` …
gr8man Aug 14, 2026
e3a8f37
refactor: fix phpstan errors in `IncomingRequestTest` (#10452)
paulbalandan Aug 14, 2026
d608eaf
refactor: fix phpstan errors in `Helpers` (#10459)
paulbalandan Aug 16, 2026
2ac2615
refactor: fix phpstan errors in `Router` (#10460)
paulbalandan Aug 16, 2026
cf54b82
refactor: clear out phpstan errors in `Validation` source and tests (…
paulbalandan Aug 16, 2026
69796fc
refactor: clear out phpstan errors in `HTTP` source and tests (#10462)
paulbalandan Aug 17, 2026
2f6f61a
refactor: fix phpstan errors in `BaseBuilder` (#10466)
paulbalandan Aug 18, 2026
befd997
style: apply latest changes of `binary_operator_spaces` fixer (#10468)
paulbalandan Aug 19, 2026
7d9f7f4
refactor: add precise parameter types to Router test fixtures (#10464)
soccerlover29 Aug 19, 2026
fda6e25
Bump StructArmed to ^0.16 (#10472)
samsonasik Aug 21, 2026
6df2fe3
refactor: fix phpstan errors in `Forge` (#10470)
paulbalandan Aug 23, 2026
9ec5138
chore: Bump Rector to 2.6.3, clean up deprecated rules, and re-run it…
samsonasik Aug 23, 2026
22a7e4e
refactor: fix phpstan errors in `Result` (#10473)
paulbalandan Aug 23, 2026
9a4acaa
refactor: fix phpstan errors in `Connection` (#10475)
paulbalandan Aug 23, 2026
68883ae
refactor: fix phpstan errors in `PreparedQuery` and `Utils` (#10476)
paulbalandan Aug 24, 2026
d9ee179
refactor: fix phpstan errors in `Config`, `Database`, `Query`, `Migra…
paulbalandan Aug 24, 2026
92008b3
refactor: fix phpstan errors in `Debug` (#10478)
paulbalandan Aug 24, 2026
67d42a9
refactor: fix phpstan errors in `Test` (#10479)
paulbalandan Aug 24, 2026
590d8eb
refactor: widen `Response` body and `Formatter` data typing to `mixed…
paulbalandan Aug 24, 2026
e650a71
refactor: fix remaining errors in `Helpers`' tests (#10481)
paulbalandan Aug 25, 2026
af6a478
refactor: fix phpstan errors in `Config` (#10482)
paulbalandan Aug 25, 2026
18804c5
refactor: fix phpstan errors in `Commands` (#10483)
paulbalandan Aug 25, 2026
eeb3c08
refactor: fix phpstan errors in `View` (#10484)
paulbalandan Aug 25, 2026
0a7b317
refactor: fix phpstan errors in `Filters` (#10485)
paulbalandan Aug 25, 2026
e4b057e
refactor: fix phpstan errors in `Encryption` (#10486)
paulbalandan Aug 25, 2026
6b8e12a
refactor: fix iterable types in `Email` (#10487)
paulbalandan Aug 25, 2026
f794bc9
refactor: fix iterable types in `Router` tests (#10488)
paulbalandan Aug 25, 2026
2cb29b7
fix: return 403 for Honeypot bot detection (#10490)
michalsn Aug 28, 2026
0eda3a5
style: fix native type ordering in lambda functions (#10491)
paulbalandan Aug 28, 2026
b7bffb1
refactor: fix remaining phpstan errors in `Database` (#10492)
paulbalandan Aug 28, 2026
5c2ff00
refactor: fix phpstan errors in `I18n` (#10493)
paulbalandan Aug 28, 2026
0b4e591
refactor: fix phpstan errors in `DataConverter` (#10494)
paulbalandan Aug 28, 2026
a101018
refactor: fix phpstan errors in `AutoReview` (#10495)
paulbalandan Aug 28, 2026
0700913
refactor: fix missing parameter types (#10496)
paulbalandan Aug 28, 2026
62d489d
refactor: fix remaining missing iterable types (#10497)
paulbalandan Aug 28, 2026
58fed05
refactor: fix remaining not found methods (#10498)
paulbalandan Aug 28, 2026
9421bd4
refactor: fix the remaining fixable `assign.propertyType` and `phpdoc…
paulbalandan Aug 28, 2026
4a2fef4
chore: set coverage: none on setup-php on structarmed workflow (#10503)
samsonasik Aug 29, 2026
02ef667
refactor: fix remaining `argument.type` and `method.childParameterTyp…
paulbalandan Aug 30, 2026
a826e69
refactor: replace anonymous class with bound closure in `PropertiesTr…
paulbalandan Aug 30, 2026
9b71bf7
docs: fix UPLOAD_ERR_XXX typo in UploadedFile docblocks (#10511)
mdalikadar Sep 1, 2026
70c99eb
chore(deps-dev): update rector/rector requirement from 2.6.3 to 2.6.4…
dependabot[bot] Sep 1, 2026
f6533e9
refactor: bound phpstan's analysed PHP versions (#10505)
paulbalandan Sep 3, 2026
b7321d3
fix: pass prompt text to readline in `CLI::prompt()` so backspace doe…
paulbalandan Sep 3, 2026
322c33a
chore(deps-dev): update rector/rector requirement (#10518)
dependabot[bot] Sep 3, 2026
c32a6e5
chore: Bump structarmed to ^0.17 and enable CodeQuality preset (#10520)
samsonasik Sep 4, 2026
17b02c4
fix(Cookie): validate raw cookie values (#10516)
gr8man Sep 4, 2026
bc580a7
docs: clarify Entity array casts (#10515)
michalsn Sep 4, 2026
e7aa212
refactor: Enable MustHaveReturnTypeFunctionRule StructArmed rule on s…
samsonasik Sep 4, 2026
745eaa3
chore: Move phpstan.dist.neon order in rector.php config to avoid tmp…
samsonasik Sep 5, 2026
a2c1f54
fix: prevent gatherOutput from being called twice when controller ret…
gr8man Sep 5, 2026
b8866f2
test(Session): add unit tests for FileHandler (#10435)
gr8man Sep 5, 2026
6dd1c5f
fix: Memcached `decrement()` gives the wrong sign on a missing key (#…
mdalikadar Sep 5, 2026
33db2c6
fix: correct file permissions and chmod target in File and UploadedFi…
gr8man Sep 5, 2026
860b5ec
refactor: fix minor type inaccuracies found via PHPStan bleeding edge…
paulbalandan Sep 5, 2026
cc882d6
fix: strip the table prefix correctly when rebuilding a SQLite3 table…
karlgray Sep 5, 2026
501706c
chore(deps-dev): update rector/rector requirement (#10530)
dependabot[bot] Sep 7, 2026
94036f1
fix: write the prompt to STDOUT before readline() on Windows (#10534)
michalsn Sep 10, 2026
2155a89
chore: replace PRLint with Carson's pr-title-linter (#10529)
paulbalandan Sep 12, 2026
d47c2dc
fix(Cookie): validate cookie path and domain attributes (#10527)
gr8man Sep 12, 2026
538c762
chore: Backport structarmed.php from 4.8 to develop and use baseline …
samsonasik Sep 12, 2026
43e3adf
chore: Skip structarmed-baseline.php on rector config (#10548)
samsonasik Sep 12, 2026
6ab6c65
chore: bump Carson to v1.4.2 and re-check PR titles on push (#10553)
paulbalandan Sep 13, 2026
959cc32
chore: replace labeler workflows with Carson's `auto-labeler` and `co…
paulbalandan Sep 13, 2026
64375f1
docs: correct what `make:migration --session` reads from `Config\Sess…
paulbalandan Sep 13, 2026
55c9ec0
chore: replace signed-commit check with Carson's `signed-commits` (#1…
paulbalandan Sep 13, 2026
de66f3f
chore: label PRs by title type with Carson's `auto-labeler` (#10557)
paulbalandan Sep 13, 2026
48bdc64
refactor: fix return type covariance of `FileCollection::getIterator(…
paulbalandan Sep 14, 2026
01fd6ee
fix(I18n): compute correct date in `Time::today()`, `yesterday()`, an…
gr8man Sep 14, 2026
39a0d2f
fix: return an empty string when `readline()` reaches end-of-file (#1…
paulbalandan Sep 15, 2026
896c7b6
fix: reject unsupported database drivers in `make:migration --session…
paulbalandan Sep 15, 2026
192887f
chore(deps): bump NexusPHP/carson in / (#10565)
dependabot[bot] Sep 16, 2026
167259b
chore(deps-dev): update rector/rector requirement (#10566)
dependabot[bot] Sep 17, 2026
13a35f7
chore: print random-test failure details as collapsible groups on CI …
paulbalandan Sep 17, 2026
edf4380
fix: reset `is_windows()` mock state in `CIUnitTestCase::tearDown()` …
gr8man Sep 18, 2026
014c45c
fix(Cache): set secure directory (0755) and file (0644) permissions i…
gr8man Sep 18, 2026
404dcf5
fix: stop `FileLocatorCached` from restoring a deleted cache on shutd…
paulbalandan Sep 18, 2026
605624d
fix: preserve sub-second precision in BaseModel datetime timestamps (…
wakqasahmed Sep 19, 2026
744e717
test: keep CommandsTest out of app/Commands so parallel runs do not r…
paulbalandan Sep 19, 2026
42d75a9
chore: replace Mergeable with Carson's welcome, template-enforcer, an…
paulbalandan Sep 20, 2026
c21d575
fix(Debug): treat zero time as valid timer start (#10569)
gr8man Sep 20, 2026
81af068
chore: enforce no merge commits in PRs (#10576)
paulbalandan Sep 22, 2026
514b9f4
chore: enforce PR bodies follow the PR template (#10577)
paulbalandan Sep 22, 2026
c9efbbc
chore: bump structarmed to ^0.18 (#10582)
samsonasik Sep 24, 2026
3bb0f3b
chore: fix phpstan notice on latest 2.2.15 (#10584)
samsonasik Sep 25, 2026
d734e61
fix: reject non-digit characters in `valid_cc_number()` (#10580)
gr8man Sep 27, 2026
0785bf5
chore: auto-close stale "waiting for info" items with Carson's `no-re…
paulbalandan Sep 27, 2026
28bb14c
refactor: tighten docblock return types in Result, CLIRequest, url_he…
paulbalandan Sep 27, 2026
fba4362
fix: throw Postgre query errors with warnings disabled (#10573)
wakqasahmed Sep 27, 2026
4a5f2fa
chore: run Carson only in the main repository (#10595)
michalsn Oct 1, 2026
6274001
docs: clarify escaping with Parser filters (#10594)
michalsn Oct 1, 2026
64c4fec
docs: clarify shared page cache behavior (#10593)
michalsn Oct 1, 2026
94e9a16
chore: keep manual enhancement labels and accept two-digit versions i…
paulbalandan Oct 1, 2026
9d671be
refactor: pass the session TTL to `Redis::set()` as an options array …
paulbalandan Oct 6, 2026
092c8f3
chore: bump Rector to 2.7.0 and clean up duplicated registered rules …
samsonasik Oct 6, 2026
99c3f24
fix: prevent infinite loop in `word_wrap()` with a character limit be…
mdalikadar Oct 8, 2026
b86f337
fix: resolve schema-qualified table names in `getFieldData()` and `pr…
paulbalandan Oct 9, 2026
483c57f
fix: cast Postgre batch subquery values so `updateBatch()` and `delet…
paulbalandan Oct 9, 2026
d5de58f
fix: cast OCI8 batch subquery values so `updateBatch()` and `deleteBa…
paulbalandan Oct 9, 2026
12a9bb5
fix: avoid undefined `STDERR` and `STDIN` outside the CLI (#10605)
paulbalandan Oct 9, 2026
641ee5b
Merge commit from fork
michalsn Oct 9, 2026
9f3374f
Merge commit from fork
michalsn Oct 9, 2026
85917a7
test: declare the throwing Parser filter closure as returning `never`…
paulbalandan Oct 9, 2026
cf96701
Merge commit from fork
michalsn Oct 9, 2026
e3d201b
Merge commit from fork
michalsn Oct 9, 2026
515876c
Merge commit from fork
michalsn Oct 9, 2026
788d6f5
Merge commit from fork
michalsn Oct 9, 2026
43372fc
Prep for 4.7.5 release (#10608)
paulbalandan Oct 9, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
2 changes: 2 additions & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ utils/ export-ignore
.php-cs-fixer.no-header.php export-ignore
.php-cs-fixer.tests.php export-ignore
.php-cs-fixer.user-guide.php export-ignore
structarmed-baseline.php export-ignore
structarmed.php export-ignore
phpmetrics.json export-ignore
phpstan-baseline.php export-ignore
Expand All @@ -32,6 +33,7 @@ psalm-baseline.xml export-ignore
psalm.xml export-ignore
psalm_autoload.php export-ignore
rector.php export-ignore
AGENTS.md export-ignore

# source user guide
user_guide_src/ export-ignore
Expand Down
125 changes: 125 additions & 0 deletions .github/carson.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,125 @@
# https://github.com/NexusPHP/carson/blob/1.x/SUBSCRIBERS.md

version: 1
subscribers:
- auto-labeler
- conflicts-notifier
- no-merge-commits
- no-response-closer
- pr-title-linter
- signed-commits
- template-enforcer
- welcome
settings:
auto-labeler:
sync_labels: true
sync_exempt:
- enhancement
rules:
- label: '4.8' # @todo change value whenever the next minor version is changed
base_branch: ['^4\.8$']
- label: github_actions
files: ['.github/workflows/*']
- label: documentation
files:
all: ['user_guide_src/source/**']
- label: testing
files:
all: ['tests/**']
- label: bug
title: ['^fix(\([^)]*\))?: ']
- label: enhancement
title: ['^perf(\([^)]*\))?: ']
- label: refactor
title: ['^refactor(\([^)]*\))?: ']
conflicts-notifier:
label: stale
message: |-
:wave: Hi, @{{user}}!

We detected conflicts in your PR against the base branch :speak_no_evil:
You may want to sync :arrows_counterclockwise: your branch with upstream!

Ref: [Syncing Your Branch](https://github.com/codeigniter4/CodeIgniter4/blob/develop/contributing/workflow.md#updating-your-branch)
no-merge-commits:
name: 'Carson / no-merge-commits'
treat_merge_commits_as: failure
exempt_branches:
- head: '^develop$'
base: '^master$'
- head: '^4\.\d+$'
base: '^develop$'
no-response-closer:
rules:
- label: needs template
only: issues
days_until_close: 2
close_message: |-
Closing this issue: the description still does not follow the bug report template after {{days_until_close}} days.

Please open a new issue using the [bug report form](https://github.com/codeigniter4/CodeIgniter4/issues/new?assignees=&labels=bug&projects=&template=bug_report.yml&title=Bug%3A+). For feature requests or support questions, please use the [forums](https://forum.codeigniter.com/forum-30.html).
- label: waiting for info
days_until_close: 14
unlabel_on_response: true
close_message: |-
Closing this {{type}}: there has been no response for {{days_until_close}} days after more information was requested.

If you can provide the requested details, leave a comment and a maintainer can reopen it.
pr-title-linter:
name: 'Carson / pr-title-linter'
rules:
- pattern: '^(?:(?:\[\d+\.\d+\] )?(?:feat|fix|chore|docs|perf|refactor|style|test|config|revert)(?:\([\-.@:`a-zA-Z0-9]+\))?!?: \S.+\S|Prep for \d+\.\d+\.\d+ release|\d+\.\d+\.\d+ (?:Ready|Merge) code)$'
description: 'PR title must include the type (feat, fix, chore, docs, perf, refactor, style, test, config, revert) of the commit per Conventional Commits specification. See https://www.conventionalcommits.org/en/v1.0.0/ for the discussion.'
level: error
signed-commits:
name: 'Carson / signed-commits'
treat_unsigned_as: failure
template-enforcer:
label: needs template
exempt_roles: [admin, maintain, write, triage]
message: |-
Hi there, @{{user}}! :wave:

It looks like this {{type}} does not follow our template:

{{violations}}

Please update the description to follow the template. The `{{label}}` label will be removed automatically once it does.
issues:
rules:
- pattern: '### PHP Version[\s\S]*### CodeIgniter4 Version'
description: 'Use the [bug report form](https://github.com/codeigniter4/CodeIgniter4/issues/new?assignees=&labels=bug&projects=&template=bug_report.yml&title=Bug%3A+), which asks for your PHP and CodeIgniter4 versions. For a feature request or support question, please use the [forums](https://forum.codeigniter.com/forum-30.html).'
pull_requests:
rules:
- pattern: '\*\*Description\*\*'
description: 'Keep the **Description** heading from the [pull request template](https://github.com/codeigniter4/CodeIgniter4/blob/develop/.github/PULL_REQUEST_TEMPLATE.md) and explain what you have changed, and why.'
- pattern: '\*\*Checklist:?\*\*'
description: 'Keep the **Checklist** from the pull request template and tick the items that apply. See [what we expect in a pull request](https://github.com/codeigniter4/CodeIgniter4/blob/develop/contributing/pull_request.md).'
- pattern: 'Explain what you have changed, and why\.'
description: 'Replace the placeholder text under **Description** with your own explanation.'
mode: forbid
welcome:
first_time:
pull_request: |-
Hi there, @{{user}}! :wave:

Thank you for sending this PR!

We expect the following in all Pull Requests (PRs).
- PRs must be sent to the [appropriate branch](https://github.com/codeigniter4/CodeIgniter4/blob/develop/contributing/pull_request.md#branching)
- All git commits must be [GPG-signed](https://github.com/codeigniter4/CodeIgniter4/blob/develop/contributing/pull_request.md#signing)
- Must follow our [style guide](https://github.com/codeigniter4/CodeIgniter4/blob/develop/contributing/pull_request.md#php-style)
- Be [commented](https://github.com/codeigniter4/CodeIgniter4/blob/develop/contributing/pull_request.md#comments) in the PHP source file
- Be documented in the [user guide](https://github.com/codeigniter4/CodeIgniter4/blob/develop/contributing/pull_request.md#user-guide)
- Be [unit tested](https://github.com/codeigniter4/CodeIgniter4/blob/develop/contributing/pull_request.md#unit-testing)
- Pass all checks in GitHub Actions

> [!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
issue: false
returning: false
30 changes: 30 additions & 0 deletions .github/copilot-instructions.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
# Copilot Code Review Instructions

Repository-wide conventions, the target-branch compatibility policy, coding
standards, and FrankenPHP Worker Mode requirements are defined in the root
`AGENTS.md`. Apply that policy in every review; this file covers review
behavior only.

## Review priorities

Prioritize actionable findings involving:

- incorrect behavior or an unhandled edge case;
- backward compatibility;
- security, input validation, and context-appropriate output escaping;
- request-specific state leaking through globals, static properties, or
shared services, including under Worker Mode where one process serves
many requests;
- differences between supported database drivers (MySQLi, PostgreSQL,
SQLite3, SQLSRV, OCI8);
- missing regression tests, user-guide changes, changelog entries, or
upgrade instructions.

## Review behavior

- Determine the PR base branch and apply the compatibility policy from
`AGENTS.md`. If the base branch cannot be determined, assume `develop`
and state that assumption.
- Do not report formatting-only issues already enforced by PHP-CS-Fixer.
- Every finding should identify a concrete failure scenario and the
affected code.
19 changes: 19 additions & 0 deletions .github/instructions/database.instructions.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
---
applyTo: "system/Database/**/*.php,tests/system/Database/**/*.php"
---

# Database layer

- Consider all supported drivers: MySQLi, PostgreSQL, SQLite3, SQLSRV, and
OCI8.
- Check identifier quoting, value binding, `NULL` behavior, transactions,
affected rows, return types, and platform-specific SQL.
- Do not implement driver-independent behavior in only one driver.
- When changing a base database class, inspect driver overrides and their
method signatures.
- Keep driver-independent tests separate from tests that require a live
database.
- Use the `DatabaseLive` PHPUnit group only when a real database connection is
required.
- Prefer focused tests for the affected base class and drivers. Leave the full
multi-driver matrix to GitHub Actions.
23 changes: 23 additions & 0 deletions .github/instructions/framework-core.instructions.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
---
applyTo: "system/**/*.php"
---

# Framework core

- Assume public and protected symbols are extension points used by third-party
applications unless they are clearly marked internal.
- Apply the target-branch compatibility policy from the root `AGENTS.md`
before changing any extension point.
- Before changing a signature or behavior, inspect parent classes, implemented
interfaces, traits, service factories, configuration, and corresponding
tests.
- Keep file paths, class names, and namespaces aligned under `CodeIgniter\`.
- Preserve existing extension and dependency-injection points.
- Consider long-running worker environments. Do not retain request-specific
state in static properties, globals, or shared services after a request
finishes.
- Avoid introducing a framework-wide abstraction to solve a single local
problem.
- On `develop`, keep exceptions and observable side effects compatible. On a
`4.*` target, change them only as an explicit, narrow, documented breaking
enhancement with a migration path.
21 changes: 21 additions & 0 deletions .github/instructions/tests.instructions.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
---
applyTo: "tests/**/*.php"
---

# PHPUnit tests

- Mirror the corresponding `system/` component and local test conventions
where practical.
- Add the appropriate PHPUnit `Group` attribute described in
`tests/README.md`.
- Prefer `assertSame()` and dedicated assertions over loose or generic
assertions.
- Cover the regression or behavior through a public API where possible.
Avoid testing private implementation details.
- Restore services, factories, environment variables, superglobals, handlers,
locale, time-related state, and other global state modified by a test.
- Tests must not depend on execution order or state left by another test.
- Do not replace a meaningful assertion with a weaker assertion to make a test
pass.
- After changing behavior, run the smallest relevant test file or component.
Do not run the complete test suite by default.
27 changes: 27 additions & 0 deletions .github/instructions/user-guide.instructions.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
---
applyTo: "user_guide_src/**/*.rst"
---

# User guide

- Preserve the existing reStructuredText structure, terminology, directives,
anchors, and surrounding writing style.
- Keep PHP examples compatible with PHP 8.2 and verify signatures and behavior
against the current framework code.
- Distinguish new behavior from existing behavior and document defaults
precisely.
- Determine the PR target branch before describing compatibility:
`develop` follows the patch-release policy, while `4.*` follows the
minor-release policy in the root `AGENTS.md`.
- Behavior changes, enhancements, deprecations, and important bug fixes may
require a changelog entry.
- Changes requiring users to modify code or configuration may require an
upgrading-guide entry.
- For an intentional compatibility break targeting `4.*`, document the old
behavior, new behavior, affected users, reason for the change, and the
smallest migration in both the minor changelog and upgrading guide.
- Keep code examples minimal but complete enough to run in a normal
CodeIgniter application.
- Leave the complete Sphinx build and documentation validation to GitHub
Actions unless the task specifically requires local documentation
validation.
38 changes: 38 additions & 0 deletions .github/instructions/worker-mode.instructions.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
---
applyTo: "system/Boot.php,system/CodeIgniter.php,system/Commands/Worker/**,system/Config/BaseService.php,system/Config/Factories.php,system/Config/Factory.php,system/Config/Services.php,system/Database/Config.php,system/Database/BaseConnection.php,system/Database/ConnectionInterface.php,system/Database/*/Connection.php,system/Events/Events.php,system/Session/**,system/Cache/**,system/HTTP/**,system/Filters/**,system/Router/**,system/Security/**,system/Debug/Toolbar.php,system/Debug/Toolbar/**,app/Config/WorkerMode.php,tests/system/Commands/Worker/**,user_guide_src/source/installation/worker_mode.rst"
---

# FrankenPHP Worker Mode

Use `system/Commands/Worker/Views/frankenphp-worker.php.tpl` as the canonical
Worker Mode entry point. `worker:install` publishes this template to
`public/frankenphp-worker.php`.

When changing bootstrap or request-lifecycle code, trace all three Worker Mode
phases:

1. One-time process bootstrap through `Boot::bootWorker()`.
2. Per-request preparation: reconnect database and cache connections, reset
the `CodeIgniter` instance, and replace all request superglobals before
calling `$app->run()`.
3. Post-request cleanup: close the session, clean up unfinished database
transactions, reset factories and non-persistent services, clean up event
listeners and performance logs, and reset the debug toolbar.

- Preserve the phase ordering unless the change explicitly proves a different
order is safe.
- Check every new mutable static property, singleton, shared service, event
listener, connection, handler, or global for cross-request state leakage.
- Do not preserve a service across requests merely for performance. Persistent
services must be safe to reuse and must not retain request, response, user,
route, security token, locale, or error state.
- Ensure exceptions and early exits cannot skip cleanup needed before the next
request.
- For state-isolation fixes, prefer a regression test that exercises two
sequential requests or reset cycles in the same process and proves the
second request cannot observe the first request's state.
- If the template contract changes, update focused assertions in
`tests/system/Commands/Worker/WorkerCommandsTest.php`.
- If existing installations need the new generated entry point, update the
changelog and upgrading guide and instruct users to run
`php spark worker:install --force`.
23 changes: 0 additions & 23 deletions .github/labeler.yml

This file was deleted.

69 changes: 0 additions & 69 deletions .github/mergeable.yml

This file was deleted.

Loading
Loading