0

When building Magento, a lot seems to fail when expected to work. One computer may succeed in building, while another throws a few errors. This may be because of the difference in PHP, but the ones I have tested had some very similar setups (Ubuntu 16.04, PHP 7.2, same SQL version, all set up by me with the same processes)

Now when developing all my compilations succeed. But when pushing the composer file run the building steps on another PC, e.g. Pull > setup:upgrade > setup:di:compile.. the compilation often fails.

Most of these are pretty easily fixed and (maybe) a result of my project setup with modules. However, others are hard to debug as far as I can see.

Currently, I am getting the error cited below. (note the required type array, actual type array)

I am not sure how to proceed. Removing vendor directories or cleaning cache does not help. Where can I start debugging (as this seems to be a core-Magento error and the error does not tell me anything)? I am running a very similar project that has almost all the same dependencies which does compile.

09:43:57-hades@Hades:~/Workspace/magento$ php7.2 bin/magento setup:di:compile Compilation was started. Interception cache generation... 6/7 [========================>---] 85% 43 secs 488.0 MiBErrors during compilation: Magento\AsynchronousOperations\Ui\Component\Operation\DataProvider Incompatible argument type: Required type: array. Actual type: array; File: vendor/magento/module-asynchronous-operations/Ui/Component/Operation/DataProvider.php Total Errors Count: 1 
3
  • magento.stackexchange.com/a/297527/36463 Commented Apr 1, 2020 at 8:09
  • All the parameters in the file are described with @param Commented Apr 1, 2020 at 8:34
  • Turns out removing the vendor dir and running composer update works.. Does anyone have an explanation or easier way to remove stale classes? Commented Apr 1, 2020 at 8:47

0

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.