Skip to content
This repository has been archived by the owner on May 28, 2024. It is now read-only.

DI compile giving error in Weprovide pdf module #6

Open
ram10rajtechM opened this issue May 15, 2018 · 5 comments
Open

DI compile giving error in Weprovide pdf module #6

ram10rajtechM opened this issue May 15, 2018 · 5 comments

Comments

@ram10rajtechM
Copy link

Hi Team,

I've integrated the module working fine.
While running the di:compile i'm getting some error.

Please check and let me know.

Error:

14% 1 sec 52.0 MiBPHP Fatal error: Declaration of WeProvide\Dompdf\Controller\Result\Dompdf::render(WeProvide\Dompdf\Controller\Result\HttpResponseInterface $response) must be compatible with Magento\Framework\Controller\AbstractResult::render(Magento\Framework\App\ResponseInterface $response) in /var/www/html/tempm/vendor/weprovide/magento2-module-dompdf/Controller/Result/Dompdf.php on line 116

Fatal error: Declaration of WeProvide\Dompdf\Controller\Result\Dompdf::render(WeProvide\Dompdf\Controller\Result\HttpResponseInterface $response) must be compatible with Magento\Framework\Controller\AbstractResult::render(Magento\Framework\App\ResponseInterface $response) in /var/www/html/tempm/vendor/weprovide/magento2-module-dompdf/Controller/Result/Dompdf.php on line 116

image

@ram10rajtechM ram10rajtechM changed the title DI compile creating issue in this module DI compile giving error in Weprovide pdf May 15, 2018
@ram10rajtechM ram10rajtechM changed the title DI compile giving error in Weprovide pdf DI compile giving error in Weprovide pdf module May 15, 2018
@performadigital
Copy link

This occurs when not using Magento 2.2 after this commit: a4b0e92

You can fix it by going to Line 89 in Dompdf.php and changing it to:

protected function render(ResponseInterface $response)

@msliman
Copy link

msliman commented May 31, 2018

@performadigital I changed line 89 as you mentioned in your last reply, but I got this error while running di:compile

[RuntimeException]
Class Dompdf\Dompdf does not exist

@performadigital
Copy link

performadigital commented Jun 7, 2018

@msliman It sounds like you haven't run the composer install which requires the Dompdf library.

Using composer run:

composer require dompdf/dompdf

Then run the upgrade and compile commands.

@BS00540411
Copy link

@performadigital Thanks for a solution it works.

@BS00540411
Copy link

Is there any patch available for this fix.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants