I have moved one magento 2 website from one server to another, after configuration, I got below error on category pages:
1 exception(s):
Exception #0 (Exception): Recoverable Error: Argument 1 passed to Mageplaza\Core\Helper\AbstractData::__construct() must be an instance of Magento\Framework\App\Helper\Context, instance of Magento\Framework\ObjectManager\ObjectManager given, called in /SOME_PATH/vendor/magento/framework/ObjectManager/Factory/AbstractFactory.php on line 93 and defined in /SOME_PATH/app/code/Mageplaza/Core/Helper/AbstractData.php on line 56
Exception #0 (Exception): Recoverable Error: Argument 1 passed to Mageplaza\Core\Helper\AbstractData::__construct() must be an instance of Magento\Framework\App\Helper\Context, instance of Magento\Framework\ObjectManager\ObjectManager given, called in /SOME_PATH/vendor/magento/framework/ObjectManager/Factory/AbstractFactory.php on line 93 and defined in /SOME_PATH/app/code/Mageplaza/Core/Helper/AbstractData.php on line 56
I have tried below things to resolve above:
Reindexing
Re-save category pages from backend
Created new category, and found its page working fine.
It seems there is a problem with database where old category urls need to be reindexed/rewritten or processed some way.
Can anyone help me to resolve this or any guide how I can troubleshoot this further?
Any help is appreciated!
Thanks
Deleting var/di directory resolves the problem. I didn't need to run any CLI command nor I need to do any cache clear stuff!
Related
I'm new to MVTec Halcon Deep Learning, I labelled my images and exported a hdict. file with MVTec Deep Learning Tool, then I tried to change some code of "classify_pill_defects_deep_learning_1_preprocess" Halcon example code, when it reached "preprocess_dl_dataset (DLDataset, DataDirectory, DLPreprocessParam, GenParam, DLDatasetFileName)" , there's error that display :
Unhandled program exception:
User defined exception ('throw') (HDevelop error code: 21001)
while calling 'throw' in procedure 'gen_dl_samples' line: 169.
User data:
['For image_id 1 the key \'image_label_id\' is missing. Missing keys can be ignored using the GenParam ignore_missing_labels.']
it says missing labels? but I checked that all images are labelled accordingly. Additionally, is ignoring missing keys ok? if yes how?
Thanks in advance !
I tried to understand how the code works but I'm new to it and the resources on internet is not that much. I'm expecting to know how to change the code and train my own deep learning model.
Good morning. Sorry to my bad English. Now I have encountered one problem. I have succeeded in executing a function with one parameter, but in case of several parameters, I failed. here is what I tried.
rundll32.exe "C:\Program Files\Windows Photo Viewer\PhotoViewer.dll", ImageView_FullScreen C:\Users\ADMIN\Documents\a.jpg // succeeded;
but I noticed that the exported function is imageview_fullscreenW, and the syntax requires 4 parameters. The 3rd parameter is the full path to the image and the other parameters are just ignored.
rundll32.exe "C:\Program Files\Windows Photo Viewer\PhotoViewer.dll", ImageView_FullScreenW 0 0 C:\Users\ADMIN\Documents\a.jpg 0 // failed;
So what's wrong with this? I am struggling with this problem for two hours! I will be really thankful if anyone finds an answer! thanks in advance.
After updating from laravel 5.3 to 5.4, I encountered an error in vendor. The error is:
Symfony\Component\Debug\Exception\FatalThrowableError: Call to undefined method Illuminate\Session\Store::set() in /var/www/ostadbank.com/vendor/laravel/framework/src/Illuminate/Support/Manager.php:137
But when I go to my error is:
fatal error exception in Manager.php line 137:call to undefined method Illuminate\session\store::set()
I go to manager.php line 137 and I see the line below:
public function __call($method, $parameters) { return $this->driver()->$method(...$parameters); }
I am not sure where to start to modify.
See the screenshots below:
I solve it, for more information read this: https://laravel.com/docs/5.4/upgrade
All calls to the ->set() method should be changed to ->put(). Typically, Laravel applications would never call the set method since it has never been documented within the Laravel documentation. However, it is included here out of caution.
I just started getting this error on a script that hasn't changed. Updating to boto3==1.4.3 had no effect. Doesn't look like throttling, does it? Not sure where to go with this one, any suggestions would be much appreciated.
File "/Library/Python/2.7/site-packages/botocore/client.py", line 251, in _api_call
return self._make_api_call(operation_name, kwargs)
File "/Library/Python/2.7/site-packages/botocore/client.py", line 537, in _make_api_call
raise ClientError(parsed_response, operation_name)
botocore.exceptions.ClientError: An error occurred (Unavailable)
when calling the DescribeSecurityGroups operation (reached max retries: 4):
Tags could not be retrieved.
Edited to add: As noted in comment below, this is coming from a seemingly innocuous call to describe_security_groups().
Another update: OK, this was transient and is no longer happening. Le sigh. Maybe some timeout due to network issues or something. I'll leave it up on SO for now, in case someone sees this and has a flash of insight.
I just tried to run the unit test of the blog for the yii framework. But I got such error and i am not able to resolve the problem. Please feel free to share with me. Thank you in advance. And I got such error.
Do i need to set up the test database for the phpunit. If so how should i have to do it.
C:\wamp\www\yii\demos\blog\protected\tests>phpunit --verbose unit\CommentTest
C:\wamp\www\yii\demos\blog\protected\tests/../config/test.phpPHPUnit 3.6.10 by S
ebastian Bergmann.
Configuration read from C:\wamp\www\yii\demos\blog\protected\tests\phpunit.xml
EE
Time: 0 seconds, Memory: 7.75Mb
There were 2 errors:
1) CommentTest::testFindRecentComments
CDbException: The table "{{post}}" for active record class "Post" cannot be foun
d in the database.
C:\wamp\www\yii\framework\db\ar\CActiveRecord.php:2264
C:\wamp\www\yii\framework\db\ar\CActiveRecord.php:379
C:\wamp\www\yii\framework\test\CDbFixtureManager.php:301
C:\wamp\www\yii\framework\test\CDbTestCase.php:118
C:\wamp\bin\php\php5.3.9\phpunit:46
2) CommentTest::testApprove
CException: Table 'tbl_post' does not exist.
C:\wamp\www\yii\framework\test\CDbFixtureManager.php:254
C:\wamp\www\yii\framework\test\CDbFixtureManager.php:145
C:\wamp\www\yii\framework\test\CDbFixtureManager.php:305
C:\wamp\www\yii\framework\test\CDbTestCase.php:118
C:\wamp\bin\php\php5.3.9\phpunit:46
FAILURES!
Tests: 2, Assertions: 0, Errors: 2.
Acutally, I found the solution to this problem. It means that it doesn't find the table in the database. So, I executed this schema.mysql.sql file which was under the directory blog/protected/data. And everything worked fine –