mirasvit / module-profiler

Magento 2 Profiler
https://mirasvit.com/
Open Software License 3.0
133 stars 36 forks source link

Problem with finding css #28

Open j0hn-mc-clane opened 6 years ago

j0hn-mc-clane commented 6 years ago

Lately I run into this already several times (never had it in the past):

` [mywebsite@web report]$ cat 205592336724 a:4:{i:0;s:384:"Warning: file_get_contents(/home/mywebsite/domains/mywebsite.nl/public_html/var/view_preprocessed/html/vendor/mirasvit/module-profiler/src/Profiler/view/base/web/css/module.css): failed to open stream: No such file or directory in /home/mywebsite/domains/mywebsite.nl/public_html/var/view_preprocessed/html/vendor/mirasvit/module-profiler/src/Profiler/view/base/templates/root.phtml on line 1";i:1;s:3667:"#0 [internal function]: Magento\Framework\App\ErrorHandler->handler(2, 'file_get_conten...', '/home/mywebsite/d...', 1, Array)

1 /home/mywebsite/domains/mywebsite.nl/public_html/var/view_preprocessed/html/vendor/mirasvit/module-profiler/src/Profiler/view/base/templates/root.phtml(1): file_get_contents('/home/mywebsite/d...')

2 /home/mywebsite/domains/mywebsite.nl/public_html/vendor/magento/framework/View/Result/Page.php(312): include('/home/mywebsite/d...')

3 /home/mywebsite/domains/mywebsite.nl/public_html/vendor/magento/framework/View/Result/Page.php(245): Magento\Framework\View\Result\Page->renderPage()

4 /home/mywebsite/domains/mywebsite.nl/public_html/vendor/magento/framework/View/Result/Layout.php(164): Magento\Framework\View\Result\Page->render(Object(Magento\Framework\App\Response\Http\Interceptor))

5 /home/mywebsite/domains/mywebsite.nl/public_html/vendor/magento/framework/Interception/Interceptor.php(74): Magento\Framework\View\Result\Layout->renderResult(Object(Magento\Framework\App\Response\Http\Interceptor))

6 /home/mywebsite/domains/mywebsite.nl/public_html/vendor/magento/framework/Interception/Chain/Chain.php(70): Magento\Framework\View\Result\Page\Interceptor->___callParent('renderResult', Array)

7 /home/mywebsite/domains/mywebsite.nl/public_html/vendor/magento/framework/Interception/Chain/Chain.php(63): Magento\Framework\Interception\Chain\Chain->invokeNext('Magento\Framewo...', 'renderResult', Object(Magento\Framework\View\Result\Page\Interceptor), Array, 'result-varnish-...')

8 /home/mywebsite/domains/mywebsite.nl/public_html/vendor/magento/module-page-cache/Model/Controller/Result/VarnishPlugin.php(74): Magento\Framework\Interception\Chain\Chain->Magento\Framework\Interception\Chain{closure}(Object(Magento\Framework\App\Response\Http\Interceptor))

9 /home/mywebsite/domains/mywebsite.nl/public_html/vendor/magento/framework/Interception/Chain/Chain.php(67): Magento\PageCache\Model\Controller\Result\VarnishPlugin->aroundRenderResult(Object(Magento\Framework\View\Result\Page\Interceptor), Object(Closure), Object(Magento\Framework\App\Response\Http\Interceptor))

10 /home/mywebsite/domains/mywebsite.nl/public_html/vendor/magento/framework/Interception/Interceptor.php(138): Magento\Framework\Interception\Chain\Chain->invokeNext('Magento\Framewo...', 'renderResult', Object(Magento\Framework\View\Result\Page\Interceptor), Array, 'result-builtin-...')

11 /home/mywebsite/domains/mywebsite.nl/public_html/vendor/magento/module-page-cache/Model/Controller/Result/BuiltinPlugin.php(67): Magento\Framework\View\Result\Page\Interceptor->Magento\Framework\Interception{closure}(Object(Magento\Framework\App\Response\Http\Interceptor))

12 /home/mywebsite/domains/mywebsite.nl/public_html/vendor/magento/framework/Interception/Interceptor.php(142): Magento\PageCache\Model\Controller\Result\BuiltinPlugin->aroundRenderResult(Object(Magento\Framework\View\Result\Page\Interceptor), Object(Closure), Object(Magento\Framework\App\Response\Http\Interceptor))

13 /home/mywebsite/domains/mywebsite.nl/public_html/var/generation/Magento/Framework/View/Result/Page/Interceptor.php(26): Magento\Framework\View\Result\Page\Interceptor->___callPlugins('renderResult', Array, Array)

14 /home/mywebsite/domains/mywebsite.nl/public_html/vendor/magento/framework/App/Http.php(139): Magento\Framework\View\Result\Page\Interceptor->renderResult(Object(Magento\Framework\App\Response\Http\Interceptor))

15 /home/mywebsite/domains/mywebsite.nl/public_html/vendor/magento/framework/App/Bootstrap.php(258): Magento\Framework\App\Http->launch()

16 /home/mywebsite/domains/mywebsite.nl/public_html/index.php(39): Magento\Framework\App\Bootstrap->run(Object(Magento\Framework\App\Http))

17 {main}";s:3:"url";s:24:"/profiler/profile/index/";s:11:"script_name";s:10:"/index.php";}[mywebsite@web report]$

`

HOSTED-POWER commented 6 years ago

We had it a few times as well! Fixed it sometimes by doing this:

mkdir -p ./var/view_preprocessed/html/vendor/mirasvit/module-profiler/src/Profiler/view/base/web/ cp -R ./vendor/mirasvit/module-profiler/src/Profiler/view/base/web/* ./var/view_preprocessed/html/vendor/mirasvit/module-profiler/src/Profiler/view/base/web/

Other cases even with this we got blank pages somehow.

wolfuma commented 6 years ago

Same issues here, fix puposed by HOSTED-POWER works sometimes, but result page its without design, only plain text.

M 2.2.2-3 with varnish trough appache on gcloud server

gerben86 commented 6 years ago

I also found this issue, I believe it's related to merging/bundling css. After I disabled bunding and merging it worked again...

Copying the file like HOSTED-POWER suggest also works.

I have M2.1.10 CE with Nginx