1 | <?php |
||
10 | class Process |
||
11 | { |
||
12 | /** |
||
13 | * @var array |
||
14 | */ |
||
15 | private static $_inWork = []; |
||
16 | |||
17 | /** |
||
18 | * Run script name. |
||
19 | * |
||
20 | * @var string |
||
21 | */ |
||
22 | private $scriptName; |
||
23 | |||
24 | /** |
||
25 | * Bin folder path. |
||
26 | * |
||
27 | * @var string |
||
28 | */ |
||
29 | private $binPath; |
||
30 | |||
31 | /** |
||
32 | * Process constructor. |
||
33 | */ |
||
34 | public function __construct(string $scriptName, string $binPath) |
||
39 | |||
40 | /** |
||
41 | * Get parallel processes count. |
||
42 | */ |
||
43 | public function getParallelEnv(): int |
||
47 | |||
48 | /** |
||
49 | * Run process. If more then limit then wait and try run process on more time. |
||
50 | * |
||
51 | * @return \Symfony\Component\Process\Process |
||
52 | */ |
||
53 | public function run(string $handle, array $data) |
||
65 | |||
66 | /** |
||
67 | * In work processes. |
||
68 | */ |
||
69 | private function inWork() |
||
82 | |||
83 | /** |
||
84 | * Create cmd process and push to queue. |
||
85 | */ |
||
86 | private function push(string $handle, array $data): \Symfony\Component\Process\Process |
||
98 | } |
||
99 |
It seems like the type of the argument is not accepted by the function/method which you are calling.
In some cases, in particular if PHP’s automatic type-juggling kicks in this might be fine. In other cases, however this might be a bug.
We suggest to add an explicit type cast like in the following example: