Skip to content

Commit 1421c19

Browse files
committed
add changelog
1 parent 983cf3a commit 1421c19

File tree

2 files changed

+11
-0
lines changed

2 files changed

+11
-0
lines changed

user_guide_src/source/changelogs/v4.8.0.rst

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,7 @@ Interface Changes
4343
Method Signature Changes
4444
========================
4545

46+
- **CLI:** The ``Console::run()`` method now accepts an optional ``array $tokens`` parameter. This allows you to pass an array of command tokens directly to the console runner, which is useful for testing or programmatically running commands. If not provided, it will default to using the global ``$argv``.
4647
- **CodeIgniter:** The deprecated parameters in methods have been removed:
4748
- ``CodeIgniter\CodeIgniter::handleRequest()`` no longer accepts the deprecated ``$cacheConfig`` and ``$returnResponse`` parameters.
4849
- ``$cacheConfig`` is no longer used and is now hard deprecated. A deprecation notice will be triggered if this is passed to the method.
@@ -175,6 +176,7 @@ Commands
175176
This provides more flexibility in how you can pass options to commands.
176177
- ``CLI`` now supports parsing array options written multiple times (e.g., ``--option=value1 --option=value2``) into an array of values. This allows you to easily pass multiple values for the same option without needing to use a comma-separated string.
177178
When used with ``CLI::getOption()``, an array option will return its last value (for example, in this case, ``value2``). To retrieve all values for an array option, use ``CLI::getRawOption()``.
179+
- Likewise, the ``command()`` function now also supports the above enhancements for command-line option parsing when using the function to run commands from code.
178180

179181
Testing
180182
=======
@@ -266,7 +268,9 @@ Changes
266268
Deprecations
267269
************
268270

271+
- The ``Boot::initializeConsole()`` method is now deprecated and will be removed in a future release.
269272
- **CLI:** The ``CLI::parseCommandLine()`` method is now deprecated and will be removed in a future release. The ``CLI`` class now uses the new ``CommandLineParser`` class to handle command-line argument parsing.
273+
- **CLI:** Returning a non-integer exit code from a command is now deprecated and will trigger a deprecation notice. Command methods should return an integer exit code (e.g., ``0`` for success, non-zero for errors) to ensure proper behavior across all platforms.
270274
- **HTTP:** The ``CLIRequest::parseCommand()`` method is now deprecated and will be removed in a future release. The ``CLIRequest`` class now uses the new ``CommandLineParser`` class to handle command-line argument parsing.
271275
- **HTTP:** ``URI::setSilent()`` is now hard deprecated. This method was only previously marked as deprecated. It will now trigger a deprecation notice when used.
272276

user_guide_src/source/installation/upgrade_480.rst

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,13 @@ Mandatory File Changes
2020
Breaking Changes
2121
****************
2222

23+
Console Exit Codes
24+
==================
25+
26+
Previously, returning a non-integer value from a command run through ``spark`` would be treated as a successful execution (exit code ``0``).
27+
Starting with v4.8.0, this behavior is still supported but will trigger a deprecation notice. Commands should now return an integer exit code
28+
to ensure proper behavior across all platforms.
29+
2330
*********************
2431
Breaking Enhancements
2532
*********************

0 commit comments

Comments
 (0)