cancel
Showing results for 
Search instead for 
Did you mean: 

Media_url issue after extension installation

SOLVED

Media_url issue after extension installation

Hi 

 

I am seriously stuck. I installed a new extension of Bss_reIndex and after that I got this error in console. I have tried to do deploy content, upgrade and compile all in production mode and still unable to figure out this issue. Have recovered backups and tried 4-5 times and ended up having this same issue again and again. 

 

 

GET http://127.0.0.1/3footwearbackup/index/%7B%7BMEDIA_URL%7D%7Dstyles.css 404 (Not Found)

 

If I change the mode to developer then it shows me this exception

 

1 exception(s):
Exception #0 (Magento\Framework\Config\Dom\ValidationException): Element 'body': This element is not expected. Expected is one of ( attribute, block, referenceBlock, referenceContainer, container, move, uiComponent ).
Line: 728


Exception #0 (Magento\Framework\Config\Dom\ValidationException): Element 'body': This element is not expected. Expected is one of ( attribute, block, referenceBlock, referenceContainer, container, move, uiComponent ).
Line: 728

#0 C:\Users\shuma\Desktop\Projects\3footwear\3footwearJune\vendor\magento\framework\Config\Dom.php(115): Magento\Framework\Config\Dom->_initDom('<layout xmlns:x...')
#1 C:\Users\shuma\Desktop\Projects\3footwear\3footwearJune\vendor\magento\framework\ObjectManager\Factory\AbstractFactory.php(111): Magento\Framework\Config\Dom->__construct('<layout xmlns:x...', Object(Magento\Framework\App\Arguments\ValidationState), Array, NULL, 'C:/Users/shuma/...', '%message%\nLine:...')
#2 C:\Users\shuma\Desktop\Projects\3footwear\3footwearJune\vendor\magento\framework\ObjectManager\Factory\Dynamic\Developer.php(66): Magento\Framework\ObjectManager\Factory\AbstractFactory->createObject('Magento\\Framewo...', Array)
#3 C:\Users\shuma\Desktop\Projects\3footwear\3footwearJune\vendor\magento\framework\ObjectManager\ObjectManager.php(56): Magento\Framework\ObjectManager\Factory\Dynamic\Developer->create('Magento\\Framewo...', Array)
#4 C:\Users\shuma\Desktop\Projects\3footwear\3footwearJune\vendor\magento\framework\Config\DomFactory.php(42): Magento\Framework\ObjectManager\ObjectManager->create('Magento\\Framewo...', Array)
#5 C:\Users\shuma\Desktop\Projects\3footwear\3footwearJune\vendor\magento\framework\View\Model\Layout\Update\Validator.php(141): Magento\Framework\Config\DomFactory->createDom(Array)
#6 C:\Users\shuma\Desktop\Projects\3footwear\3footwearJune\vendor\magento\framework\View\Model\Layout\Merge.php(461): Magento\Framework\View\Model\Layout\Update\Validator->isValid('<layout xmlns:x...', 'layout_merged', false)
#7 C:\Users\shuma\Desktop\Projects\3footwear\3footwearJune\vendor\magento\framework\View\Model\Layout\Merge.php(442): Magento\Framework\View\Model\Layout\Merge->_validateMergedLayout('LAYOUT_frontend...', '<body>\n   <refe...')
#8 C:\Users\shuma\Desktop\Projects\3footwear\3footwearJune\generated\code\Magento\Framework\View\Model\Layout\Merge\Interceptor.php(193): Magento\Framework\View\Model\Layout\Merge->load(Array)
#9 C:\Users\shuma\Desktop\Projects\3footwear\3footwearJune\vendor\magento\framework\View\Layout\Builder.php(86): Magento\Framework\View\Model\Layout\Merge\Interceptor->load()
#10 C:\Users\shuma\Desktop\Projects\3footwear\3footwearJune\vendor\magento\framework\View\Layout\Builder.php(63): Magento\Framework\View\Layout\Builder->loadLayoutUpdates()
#11 C:\Users\shuma\Desktop\Projects\3footwear\3footwearJune\vendor\magento\framework\View\Layout.php(254): Magento\Framework\View\Layout\Builder->build()
#12 C:\Users\shuma\Desktop\Projects\3footwear\3footwearJune\vendor\magento\framework\View\Layout.php(875): Magento\Framework\View\Layout->build()
#13 C:\Users\shuma\Desktop\Projects\3footwear\3footwearJune\generated\code\Magento\Framework\View\Layout\Interceptor.php(414): Magento\Framework\View\Layout->getBlock('page_content_he...')
#14 C:\Users\shuma\Desktop\Projects\3footwear\3footwearJune\vendor\magento\module-cms\Helper\Page.php(171): Magento\Framework\View\Layout\Interceptor->getBlock('page_content_he...')
#15 C:\Users\shuma\Desktop\Projects\3footwear\3footwearJune\vendor\magento\module-cms\Controller\Index\Index.php(43): Magento\Cms\Helper\Page->prepareResultPage(Object(Magento\Cms\Controller\Index\Index\Interceptor), 'homepage_elly2')
#16 C:\Users\shuma\Desktop\Projects\3footwear\3footwearJune\generated\code\Magento\Cms\Controller\Index\Index\Interceptor.php(24): Magento\Cms\Controller\Index\Index->execute(NULL)
#17 C:\Users\shuma\Desktop\Projects\3footwear\3footwearJune\vendor\magento\framework\App\Action\Action.php(107): Magento\Cms\Controller\Index\Index\Interceptor->execute()
#18 C:\Users\shuma\Desktop\Projects\3footwear\3footwearJune\vendor\magento\framework\Interception\Interceptor.php(58): Magento\Framework\App\Action\Action->dispatch(Object(Magento\Framework\App\Request\Http))
#19 C:\Users\shuma\Desktop\Projects\3footwear\3footwearJune\vendor\magento\framework\Interception\Interceptor.php(138): Magento\Cms\Controller\Index\Index\Interceptor->___callParent('dispatch', Array)
#20 C:\Users\shuma\Desktop\Projects\3footwear\3footwearJune\vendor\magento\framework\Interception\Interceptor.php(153): Magento\Cms\Controller\Index\Index\Interceptor->Magento\Framework\Interception\{closure}(Object(Magento\Framework\App\Request\Http))
#21 C:\Users\shuma\Desktop\Projects\3footwear\3footwearJune\generated\code\Magento\Cms\Controller\Index\Index\Interceptor.php(39): Magento\Cms\Controller\Index\Index\Interceptor->___callPlugins('dispatch', Array, Array)
#22 C:\Users\shuma\Desktop\Projects\3footwear\3footwearJune\vendor\magento\framework\App\FrontController.php(55): Magento\Cms\Controller\Index\Index\Interceptor->dispatch(Object(Magento\Framework\App\Request\Http))
#23 C:\Users\shuma\Desktop\Projects\3footwear\3footwearJune\vendor\magento\framework\Interception\Interceptor.php(58): Magento\Framework\App\FrontController->dispatch(Object(Magento\Framework\App\Request\Http))
#24 C:\Users\shuma\Desktop\Projects\3footwear\3footwearJune\vendor\magento\framework\Interception\Interceptor.php(138): Magento\Framework\App\FrontController\Interceptor->___callParent('dispatch', Array)
#25 C:\Users\shuma\Desktop\Projects\3footwear\3footwearJune\vendor\magento\module-store\App\FrontController\Plugin\RequestPreprocessor.php(94): Magento\Framework\App\FrontController\Interceptor->Magento\Framework\Interception\{closure}(Object(Magento\Framework\App\Request\Http))
#26 C:\Users\shuma\Desktop\Projects\3footwear\3footwearJune\vendor\magento\framework\Interception\Interceptor.php(135): Magento\Store\App\FrontController\Plugin\RequestPreprocessor->aroundDispatch(Object(Magento\Framework\App\FrontController\Interceptor), Object(Closure), Object(Magento\Framework\App\Request\Http))
#27 C:\Users\shuma\Desktop\Projects\3footwear\3footwearJune\vendor\magento\module-page-cache\Model\App\FrontController\BuiltinPlugin.php(73): Magento\Framework\App\FrontController\Interceptor->Magento\Framework\Interception\{closure}(Object(Magento\Framework\App\Request\Http))
#28 C:\Users\shuma\Desktop\Projects\3footwear\3footwearJune\vendor\magento\framework\Interception\Interceptor.php(135): Magento\PageCache\Model\App\FrontController\BuiltinPlugin->aroundDispatch(Object(Magento\Framework\App\FrontController\Interceptor), Object(Closure), Object(Magento\Framework\App\Request\Http))
#29 C:\Users\shuma\Desktop\Projects\3footwear\3footwearJune\vendor\magento\framework\Interception\Interceptor.php(153): Magento\Framework\App\FrontController\Interceptor->Magento\Framework\Interception\{closure}(Object(Magento\Framework\App\Request\Http))
#30 C:\Users\shuma\Desktop\Projects\3footwear\3footwearJune\generated\code\Magento\Framework\App\FrontController\Interceptor.php(26): Magento\Framework\App\FrontController\Interceptor->___callPlugins('dispatch', Array, NULL)
#31 C:\Users\shuma\Desktop\Projects\3footwear\3footwearJune\vendor\magento\framework\App\Http.php(135): Magento\Framework\App\FrontController\Interceptor->dispatch(Object(Magento\Framework\App\Request\Http))
#32 C:\Users\shuma\Desktop\Projects\3footwear\3footwearJune\generated\code\Magento\Framework\App\Http\Interceptor.php(24): Magento\Framework\App\Http->launch()
#33 C:\Users\shuma\Desktop\Projects\3footwear\3footwearJune\vendor\magento\framework\App\Bootstrap.php(256): Magento\Framework\App\Http\Interceptor->launch()
#34 C:\Users\shuma\Desktop\Projects\3footwear\3footwearJune\index.php(81): Magento\Framework\App\Bootstrap->run(Object(Magento\Framework\App\Http\Interceptor))
#35 {main}

What do I do? I am completely stuck. 

 

1 ACCEPTED SOLUTION

Accepted Solutions

Re: Media_url issue after extension installation

I finally fixed the issue. Checked php_log and it says memory allocated issue so I increased memory_limit and it worked.

View solution in original post

11 REPLIES 11

Re: Media_url issue after extension installation

Hi @shumailakhan

 

have you tried after un-installing that extension ? is it worked ?

 

 try to uninstall that extension first , then remove your var/generation and generated directory from the magento 2 .

 

Then do upgrade , compile and content:deploy again !

 

Then try it will works 

if issue solved,Click Kudos & Accept as Solution

Re: Media_url issue after extension installation

Hey!

 

Thanks for the idea but I have tried this as well in vein. One of my local instance is not even working without extension. I am guessing it has something to do with apache permissions maybe? but unable to figure out. Can you direct me somewhere?

Re: Media_url issue after extension installation

Hi @shumailakhan

 

Yes that is what i wanted to confirm - error is a different not depended on that extension !

 

Looks like this is known error , below i am sharing few links which helps you to resolve this issue !

 

https://github.com/magento/magento2/issues/11116

 

https://github.com/magento/magento2/issues/11312

 

https://magento.stackexchange.com/questions/225538/exception-error-element-body-this-element-is-not-...

 

Hope it helps 

if issue solved,Click Kudos & Accept as Solution

Re: Media_url issue after extension installation

Hi,

I just rolled back to a last backup and now I think the issue is due to extension because that's the only change I did. 

I installed this extension https://marketplace.magento.com/bsscommerce-reindex-data.html

 

have you used this one? I am total stuck and as much as I used to love magento so disappointed this time.

Re: Media_url issue after extension installation

Hi @shumailakhan

 

Yes , i have used this extension - infact i have just checked with my default demo of 2.2.4 with installing this extension and it works perfect at our end !

 

I am able to do re-indexing from the backend 

 

in your case it might be conflicting with some other extension !

if issue solved,Click Kudos & Accept as Solution

Re: Media_url issue after extension installation

How do I debug the conflict as after disabling the extension it gives only black screen, zero error on console.

Re: Media_url issue after extension installation

I finally fixed the issue. Checked php_log and it says memory allocated issue so I increased memory_limit and it worked.

Re: Media_url issue after extension installation

Hi @shumailakhan

 

Glad to know that you have resolved your issue , Yes for magento 2 memory allocation required at least 1024 MB to 2048MB

 

Also sometimes issue with max_execution_time as well , so it required 18000 !

 

Anyways thanks for sharing , happy to  help and keep helping Smiley Happy

if issue solved,Click Kudos & Accept as Solution

Re: Media_url issue after extension installation

Thanks for the help @Manthan Dave .

Can you please also look into one of my other issue related to product import and export?