-
Notifications
You must be signed in to change notification settings - Fork 197
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
Merge of EAV Structure of Magento 1 with Magento 2 > Product Information lost caused by missing merge. #832
Comments
I ran into the same problem (I think from the description). The issue seems to be https://github.com/magento/data-migration-tool/blob/7191f7c1e02256527b88de80a3d7ab86d403d3dd/src/Migration/Step/Eav/Data.php#L312: The ATTRIBUTE_SETS_NONE_DEFAULT flag removes the first attribute set from receiving the M2 default attributes. |
@OldPlanets I removed that line but I'm now getting the following error at the EAV migration step:
Any idea why this is happening? The migration ran fine beforehand with the exception of the missing product and product category data. I'm running this against a clean installation of Magento 2.3.5, right after running |
Running with the I dug into this a bit and confirmed that it wasn't related to the attribute set IDs like mentioned in another thread, and it wasn't because the data hadn't been migrated. After going back and forth with it for a little bit, I realized that I could change the name of a category or product in the admin panel, and that entity would then display its new name. This led me to check what the difference was between the migrated row and the newly created one. I noticed that the newly created row was not in I'm not sure why, but it looks like these default attributes had their update eav_attribute a set a.backend_type = 'varchar' where a.backend_type = 'text' and a.attribute_id in (
select distinct b.attribute_id from catalog_*_entity_varchar b
); ... and then run This behavior was observed when migrating from Magento Commerce 1.14.4.5 to 2.3.5. I also noticed it occurred with some custom customer attributes as well. I'm trying to determine whether this is a bug with Magento, the data migration tool, or specifically our installation. I'll submit a PR if it turns out to be related to the migration tool. |
For the record: |
Getting the same issue as @kanevbg. I was going to make a separate issue for it. Can someone point to where the mapping of the attribute codes is defined? I assume there's just a missing mapping, but it could also just be a bug in copying the attribute values. Found this that could possibly be similar for the countryofmanufacturer attribtue
|
A database level check to see the data for easy testing
|
I've narrowed it down to the PostProcessing step. When a migration is done without that step the manufacturer data is present on the M2 instance. Then running just that step, the manufacturer data is lost. Might be something weird like the manufacturer in this particular instance is on the default attribute set and is getting skipped or something and cleaned up as "leftover" eav data or something... I'll keep digging |
Ok so the manufacturer and color attribute values are lost for some reason. The eav_entity_attribute table (which links attributes with attribute sets) is missing the manufacturer attribute for some reason. It's not obvious why that's being skipped. There's no mention of manufacturer in all of the config mapping files or anything. As it is not added, it shows up in the leftover attribute cleanup and the values are then removed. A quick fix is to remove the catalog_product_entity_int table from the leftover cleanup, but the underlying issue of the manufacturer not being added from the M1 default attribute set to the M2 default attribute set remains in question still. (This is just in my case)
I used that query to figure out what attributes were being lost and get a good understanding of why. Not too sure where to go from here, other than removing the leftover attribute cleaning, which doesn't seem like the right solution though. |
Same issue here with Magento 1.9.4.5 to 2.4.1 The fun thing is that the migration worked fine prior to 2.4.1 but that doesn't match with all the reports I found. Maybe this is also related to #812 |
I faced the same issue. The entries in the This is actually the name, which is given by Magento by default. But as soon as a third party module adds a product attribute to the well known group 'General' from Magento 1, the group |
@norgeindian maybe this PR can fix your use case? |
@norgeindian Please post back your experience with the PR. |
@kanevbg , sorry, as Firegento fixed their issue with the wrong adding of the attribute group pretty fast, I did not try it with the PR. But can say for sure, that the migration of custom attributes in the "General" group work fine, when the groupname is not changed. |
@PivitParkour94 , after fixing my issue with the General attribute group, I also ran into your issue with
Let's take a look why at the reasons why both cases don't work: 1. Handling as Default Destination Attributes
Let's come to the second possibility: 2. Handling as Custom Source Attributes
Like I said in the beginning. After the EAV-Step there are no entries at all for these attributes in |
@norgeindian We ended up just commenting out the |
Today I followed @norgeindian with his fix for the firegento/firegento-magesetup2 (Fix attribute group) and checked the values for attribute group with attribute_group_code=product-details in the table eav_attribute_group. The attribute_group_name was initially 'General' as described. I changed it back to 'Product Details' and ran the migration again. Except for the attributes color and manufacturer (as mentioned above) all seems to be in order now for the attributes in the 'General' group of Magento 1. Thank you very much for the hint. |
@norgeindian your comment regarding the 'color' and 'manufacturer' attributes led me to a solution which I think is going to work in my case. A fresh install of M2.3.5 comes both 'color' and 'manufacturer' product attributes, but of all the product attributes are created on install, these are the only two which are not assigned to the default attribute set. As @norgeindian noted above in case 1, attributes which exist in M2, but which do not belong to an attribute set, are skipped and not imported. My solution to this problem, is before the migration, go into the freshly installed M2 and add both the 'color' and 'manufacturer' attributes to the 'Default' attribute set (any group you want). Then do the migration and the 'color' and 'manufacturer' attributes are migrated as you'd expect. I've no idea what would happen if you try migrating from an M1 store with multiple attributes sets, where the 'color' and 'manufacturer' attributes are assigned to more than one set. You might recreating the necessary attribute sets, but really I have no idea. |
Preconditions
Steps to reproduce
Expected result
Actual result
Additional notes
This is shop breaking behavior since all product information regarding the not merged attributes is lost.
The text was updated successfully, but these errors were encountered: