I have migrated from ver 1.9 to 2.3
“Type Error occurred when creating object: Magento\\Eav\\Model\\Entity\\Attribute\\Source\\Config”
Try to look at the customer eav attribute with
select value for
frontend_input column in
eav_attribute table, make sure the
source_model column value is not null or empty or it fills with correct class. You can set value for
frontend_input column to
int if you wanna work on the
saved my day, thanks Feb 22, 2020 at 21:06
I love the suggestion of changing the
intfor debugging purposes. I have a custom M1 attribute that came to M2 with
NULL. Changed the
intand the page works. Now I know the source of the bug and can determine how I want to migrate that data / fix it.– PromIncMay 19, 2020 at 15:07
Yes, it work, replace select with int or add source_model for these attributes Jan 20, 2021 at 11:48
Go to the table eav_attribute and search for attribute "mailchimp_store_view" and deleted this row after taking backup of your table. it will fix your problem. i was also facing same issue. it worked like a charm. give it a try.
As noted by most, this seems to involve attributes that did not cleanly migrate / has migration data issues
In my case it was an customer address attribute called 'address_valid'
A sure fire way to debug this is to just debug with a breakpoint in PHPSTorm on
make a small temp edit to function definition
and step through until you hit the null one(s).
You can also go with a conditional (mine happen to the be first attribute calling that routine, so I had nothing to step through)
Look back in the trace log until you find the AbstratAttribute.php entry, and select.
Then check within the class data for the offending attribute data
Please run this three commands and check:
php bin/magento setup:upgrade php bin/magento setup:di:compile php bin/magento cache:flush
After a long debug and review migrated database I found the reason
During migration I found that some of custom attributes were not there in migrated DB ( I don't know, Why !).
Another important point is we should check the options for the select type attributes( options had not been migrated in my case).
These 2 can be the possible reasons for the error.
I was experiencing the same issue when trying to edit customers accounts and after checking the 'eav_attribute table' using Idham Choudry's answer here, i checked the table against a working Magento (2.3.4) and found that MailChimp had an erroneous attribute which had migrated over from Magento 1.9 but is now no longer needed.
After taking a backup of the database I simply deleted the 'mailchimp_store_view' attribute from the eav_attribute table and I can now edit customers again.
Finally i re-installed Mailchimp and everything is now working perfectly again.
Hope this helps anyone with the same problem
I had this same issue. It turned out to be some extra entries (not columns or source model) in the "eav_customer_attribute" table. Once I removed these entries the page loaded and worked fine.
I also found that this issue caused the customers address to be saved as a new entry on every order.
In my case it was a plug-in attribute.
In \www\vendor\magento\module-customer\Model\AttributeMetadataResolver.php around line 116 there is the public function getAttributesMeta.
Here add a bit of debug code to find the problematic attribute:
Refresh the page. You should see some attribute codes printed in top of the page before the error. Its the last one that gets printed before the error. In my case it was allowed_payment_methods.
Remove the attribute from the eav_attribute table and you should be good to go.