@@ -19,8 +19,13 @@ existing implementation before introducing a new abstraction or convention.
1919## Target branch and compatibility policy
2020
2121Compatibility is judged against the pull request's base branch, not the
22- contributor's source or feature branch. When the base branch is unknown,
23- apply the stricter ` develop ` policy.
22+ contributor's source or feature branch. When the base branch is not stated,
23+ take the cues from the title prefix and the labels. A ` feat: ` prefix and the
24+ ` enhancement ` , ` new feature ` , ` breaking change ` , or ` 4.x ` labels point to the
25+ next minor branch. A ` fix: ` , ` refactor: ` , or ` docs: ` prefix and the ` bug ` or
26+ ` refactor ` labels can go either way, since the next minor branch also takes
27+ fixes to its own unreleased code, so look at what the change touches. When no
28+ cue settles it, apply the stricter ` develop ` policy.
2429
2530### Base branch ` develop `
2631
@@ -50,6 +55,16 @@ complete the documented deprecation lifecycle.
5055- Every accepted break needs tests for the new behavior, a minor-version
5156 changelog entry, and migration instructions in the upgrading guide.
5257
58+ ### Unreleased API
59+
60+ A symbol first added on the base branch after its latest tagged release is
61+ unreleased. Nothing outside the repository can depend on it yet, so changing,
62+ renaming, or removing it is not a compatibility break: it needs no
63+ deprecation, no upgrading-guide entry, and no changelog line beyond the one
64+ describing the final shape. Check the version tags or the changelog of the
65+ unreleased version before reporting a break on such a symbol. The
66+ compatibility policy applies to what the latest tagged release ships.
67+
5368### All base branches
5469
5570- Production code must run on PHP 8.2. Do not require a newer PHP version,
@@ -83,7 +98,15 @@ complete the documented deprecation lifecycle.
8398- Add PHPDoc only when it contributes information that native types cannot
8499 express. Do not duplicate a parent or interface docblock.
85100- Never suppress a static-analysis error or update a baseline to make a
86- check pass.
101+ check pass. The accepted exceptions are:
102+ - a false positive, when the usage is judged correct;
103+ - a suppression needed to assert a runtime behavior in a test;
104+ - a call to a function mocked in ` system/Test/Mock/MockCommon.php ` , such
105+ as ` is_cli(false) ` , which PHPStan reports as ` arguments.count ` .
106+
107+ Regenerate the baseline with ` composer phpstan:baseline ` , never by editing
108+ the ` .neon ` files, and add a test file that calls ` is_cli() ` with an
109+ argument to the ` RemoveExtraParametersRector ` skip list in ` rector.php ` .
87110
88111## FrankenPHP Worker Mode
89112
0 commit comments