Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 5e582b7

Browse filesBrowse files
committed
[Process] remove deprecated features
1 parent f309c09 commit 5e582b7
Copy full SHA for 5e582b7

File tree

8 files changed

+31
-849
lines changed
Filter options

8 files changed

+31
-849
lines changed

‎src/Symfony/Component/Process/CHANGELOG.md

Copy file name to clipboardExpand all lines: src/Symfony/Component/Process/CHANGELOG.md
+15Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,21 @@
11
CHANGELOG
22
=========
33

4+
4.0.0
5+
-----
6+
7+
* support for passing `proc_open()` options has been removed
8+
* added a second `array $env = array()` argument to the `start()` method of
9+
the `Process` class
10+
* the `areEnvironmentVariablesInherited()`, `getOptions()`, `setOptions()`,
11+
`getEnhanceWindowsCompatibility()`, `getEnhanceSigchildCompatibility()`,
12+
`setEnhanceSigchildCompatibility()`, and `setEnhanceWindowsCompatibility()`
13+
methods of the `Process` class have been removed
14+
* environment variables will always be inherited
15+
* the `ProcessUtils::escapeArgument()` method has been removed
16+
* the `inheritEnvironmentVariables()` and `setOption()` options of the
17+
`ProcessBuilder` class have been removed
18+
419
3.4.0
520
-----
621

‎src/Symfony/Component/Process/PhpProcess.php

Copy file name to clipboardExpand all lines: src/Symfony/Component/Process/PhpProcess.php
+3-8Lines changed: 3 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -31,9 +31,8 @@ class PhpProcess extends Process
3131
* @param string|null $cwd The working directory or null to use the working dir of the current PHP process
3232
* @param array|null $env The environment variables or null to use the same environment as the current PHP process
3333
* @param int $timeout The timeout in seconds
34-
* @param array $options An array of options for proc_open
3534
*/
36-
public function __construct($script, $cwd = null, array $env = null, $timeout = 60, array $options = null)
35+
public function __construct($script, $cwd = null, array $env = null, $timeout = 60)
3736
{
3837
$executableFinder = new PhpExecutableFinder();
3938
if (false === $php = $executableFinder->find(false)) {
@@ -48,11 +47,8 @@ public function __construct($script, $cwd = null, array $env = null, $timeout =
4847
$php[] = $file;
4948
$script = null;
5049
}
51-
if (null !== $options) {
52-
@trigger_error(sprintf('The $options parameter of the %s constructor is deprecated since version 3.3 and will be removed in 4.0.', __CLASS__), E_USER_DEPRECATED);
53-
}
5450

55-
parent::__construct($php, $cwd, $env, $script, $timeout, $options);
51+
parent::__construct($php, $cwd, $env, $script, $timeout);
5652
}
5753

5854
/**
@@ -66,12 +62,11 @@ public function setPhpBinary($php)
6662
/**
6763
* {@inheritdoc}
6864
*/
69-
public function start(callable $callback = null/*, array $env = array()*/)
65+
public function start(callable $callback = null, array $env = array())
7066
{
7167
if (null === $this->getCommandLine()) {
7268
throw new RuntimeException('Unable to find the PHP executable.');
7369
}
74-
$env = 1 < func_num_args() ? func_get_arg(1) : null;
7570

7671
parent::start($callback, $env);
7772
}

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.