Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Magento 2.3.3 Admin issue #23

Closed
hidonet opened this issue Oct 23, 2019 · 11 comments
Closed

Magento 2.3.3 Admin issue #23

hidonet opened this issue Oct 23, 2019 · 11 comments

Comments

@hidonet
Copy link
Contributor

hidonet commented Oct 23, 2019

All admin links of this extension returning this error.

1 exception(s):
Exception #0 (InvalidArgumentException): Class argument is invalid: Magento\Framework\View\Element\UiComponent\Context

Exception #0 (InvalidArgumentException): Class argument is invalid: Magento\Framework\View\Element\UiComponent\Context

#1 Magento\Framework\Data\Argument\InterpreterInterface\Proxy->evaluate() called at [vendor/magento/framework/Data/Argument/Interpreter/Composite.php:61]
#2 Magento\Framework\Data\Argument\Interpreter\Composite->evaluate() called at [vendor/magento/module-ui/Config/Data.php:164]
#3 Magento\Ui\Config\Data->evaluateComponentArguments() called at [vendor/magento/module-ui/Config/Data.php:111]
#4 Magento\Ui\Config\Data->initData() called at [vendor/magento/module-ui/Config/Data.php:136]
#5 Magento\Ui\Config\Data->get() called at [vendor/magento/framework/View/Layout/Reader/UiComponent.php:100]
#6 Magento\Framework\View\Layout\Reader\UiComponent->interpret() called at [vendor/magento/framework/View/Layout/ReaderPool.php:105]
#7 Magento\Framework\View\Layout\ReaderPool->interpret() called at [vendor/magento/framework/View/Layout/Reader/Container.php:89]
#8 Magento\Framework\View\Layout\Reader\Container->interpret() called at [vendor/magento/framework/View/Layout/ReaderPool.php:105]
#9 Magento\Framework\View\Layout\ReaderPool->interpret() called at [vendor/magento/framework/View/Page/Config/Reader/Body.php:68]
#10 Magento\Framework\View\Page\Config\Reader\Body->interpret() called at [vendor/magento/framework/View/Layout/ReaderPool.php:105]
#11 Magento\Framework\View\Layout\ReaderPool->interpret() called at [vendor/magento/framework/View/Layout.php:325]
#12 Magento\Framework\View\Layout->generateElements() called at [generated/code/Magento/Framework/View/Layout/Interceptor.php:89]
#13 Magento\Framework\View\Layout\Interceptor->generateElements() called at [vendor/magento/framework/View/Layout/Builder.php:129]
#14 Magento\Framework\View\Layout\Builder->generateLayoutBlocks() called at [vendor/magento/framework/View/Page/Builder.php:55]
#15 Magento\Framework\View\Page\Builder->generateLayoutBlocks() called at [vendor/magento/framework/View/Layout/Builder.php:65]
#16 Magento\Framework\View\Layout\Builder->build() called at [vendor/magento/framework/View/Page/Config.php:224]
#17 Magento\Framework\View\Page\Config->build() called at [vendor/magento/framework/View/Page/Config.php:247]
#18 Magento\Framework\View\Page\Config->getTitle() called at [vendor/mageprince/module-faq/Controller/Adminhtml/FaqGroup/Index.php:61]
#19 Prince\Faq\Controller\Adminhtml\FaqGroup\Index->execute() called at [generated/code/Prince/Faq/Controller/Adminhtml/FaqGroup/Index/Interceptor.php:24]
#20 Prince\Faq\Controller\Adminhtml\FaqGroup\Index\Interceptor->execute() called at [vendor/magento/framework/App/Action/Action.php:108]
#21 Magento\Framework\App\Action\Action->dispatch() called at [vendor/magento/module-backend/App/AbstractAction.php:231]
#22 Magento\Backend\App\AbstractAction->dispatch() called at [vendor/magento/framework/Interception/Interceptor.php:58]
#23 Prince\Faq\Controller\Adminhtml\FaqGroup\Index\Interceptor->___callParent() called at [vendor/magento/framework/Interception/Interceptor.php:138]
#24 Prince\Faq\Controller\Adminhtml\FaqGroup\Index\Interceptor->Magento\Framework\Interception\{closure}() called at [app/code/WeltPixel/Backend/Plugin/Utility.php:76]
#25 WeltPixel\Backend\Plugin\Utility->aroundDispatch() called at [vendor/magento/framework/Interception/Interceptor.php:135]
#26 Prince\Faq\Controller\Adminhtml\FaqGroup\Index\Interceptor->Magento\Framework\Interception\{closure}() called at [vendor/magento/module-backend/App/Action/Plugin/Authentication.php:143]
#27 Magento\Backend\App\Action\Plugin\Authentication->aroundDispatch() called at [vendor/magento/framework/Interception/Interceptor.php:135]
#28 Prince\Faq\Controller\Adminhtml\FaqGroup\Index\Interceptor->Magento\Framework\Interception\{closure}() called at [vendor/magento/framework/Interception/Interceptor.php:153]
#29 Prince\Faq\Controller\Adminhtml\FaqGroup\Index\Interceptor->___callPlugins() called at [generated/code/Prince/Faq/Controller/Adminhtml/FaqGroup/Index/Interceptor.php:39]
#30 Prince\Faq\Controller\Adminhtml\FaqGroup\Index\Interceptor->dispatch() called at [vendor/magento/framework/App/FrontController.php:159]
#31 Magento\Framework\App\FrontController->processRequest() called at [vendor/magento/framework/App/FrontController.php:99]
#32 Magento\Framework\App\FrontController->dispatch() called at [vendor/magento/framework/Interception/Interceptor.php:58]
#33 Magento\Framework\App\FrontController\Interceptor->___callParent() called at [vendor/magento/framework/Interception/Interceptor.php:138]
#34 Magento\Framework\App\FrontController\Interceptor->Magento\Framework\Interception\{closure}() called at [vendor/magento/framework/Interception/Interceptor.php:153]
#35 Magento\Framework\App\FrontController\Interceptor->___callPlugins() called at [generated/code/Magento/Framework/App/FrontController/Interceptor.php:26]
#36 Magento\Framework\App\FrontController\Interceptor->dispatch() called at [vendor/magento/framework/App/Http.php:137]
#37 Magento\Framework\App\Http->launch() called at [vendor/magento/framework/App/Bootstrap.php:261]
#38 Magento\Framework\App\Bootstrap->run() called at [pub/index.php:40]
@lamda
Copy link

lamda commented Oct 31, 2019

Does anyone have any pointers on how to solve this?

@lamda
Copy link

lamda commented Oct 31, 2019

If you delete the following block from the UI Component xml file, things appear to be working normally for me:

<argument name="context" xsi:type="configurableObject"> <argument name="class" xsi:type="string">Magento\Framework\View\Element\UiComponent\Context</argument> <argument name="namespace" xsi:type="string">prince_faq_index</argument> </argument>

@hidonet
Copy link
Contributor Author

hidonet commented Nov 1, 2019

@lamda yes. it's worked for me too. Thanks.

@hidonet hidonet closed this as completed Nov 1, 2019
@mrtuvn
Copy link

mrtuvn commented Nov 19, 2019

delete is not good way. Add di.xml for whitelist class instead

@lamda
Copy link

lamda commented Nov 19, 2019

Could you explain what you mean by that? Why is not good? And any pointers on how one could add that to di.xml?

@shinesoftware
Copy link

Why do we need to delete these rows? What is changed in the last version of Magento?

@ilnytskyi
Copy link

Or just implement Magento\Framework\Data\OptionSourceInterface for that Context class

@rustavellyne
Copy link

just add to app/etc/di.xml
<item name="2" xsi:type="string">Magento\Framework\View\Element\UiComponent\ContextInterface</item>

 <type name="Magento\Framework\View\Element\UiComponent\Argument\Interpreter\ConfigurableObject">
        <arguments>
            <argument name="classWhitelist" xsi:type="array">
                <item name="0" xsi:type="string">Magento\Framework\Data\OptionSourceInterface</item>
                <item name="1" xsi:type="string">Magento\Framework\View\Element\UiComponent\DataProvider\DataProviderInterface</item>
                <item name="2" xsi:type="string">Magento\Framework\View\Element\UiComponent\ContextInterface</item>
            </argument>
        </arguments>
    </type>

@DylanHopman
Copy link

@lamda got the right fix for it. You can find the file in your module -> etc/view/adminhtml/ui_component

@jithutj
Copy link

jithutj commented May 20, 2021

just add to app/etc/di.xml
<item name="2" xsi:type="string">Magento\Framework\View\Element\UiComponent\ContextInterface</item>

 <type name="Magento\Framework\View\Element\UiComponent\Argument\Interpreter\ConfigurableObject">
        <arguments>
            <argument name="classWhitelist" xsi:type="array">
                <item name="0" xsi:type="string">Magento\Framework\Data\OptionSourceInterface</item>
                <item name="1" xsi:type="string">Magento\Framework\View\Element\UiComponent\DataProvider\DataProviderInterface</item>
                <item name="2" xsi:type="string">Magento\Framework\View\Element\UiComponent\ContextInterface</item>
            </argument>
        </arguments>
    </type>

Thank You its working!!!

@virtualLast
Copy link

I added this to an over ride di.xml file and its resolved the issue. I wasnt sure if app/etc/di.xml would be over ridden in future core magento updates. Can someone explain a little about what the above is doing?

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

No branches or pull requests

9 participants