magento / magento/data-migration-tool

Custom product attribute groups empty when migrating from 1.9.2.2 to 2.4.3

Open
#888 5 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
PHP
Stars
339
Forks
195
PR merge metrics
No merged PRs in 30d

Description

When migrating from Magento 1.9.2.2 to 2.4.3 the custom product attribute group mapping does not work as expected.
This error causes the custom attribute groups to be empty after migration.

### Preconditions
* Source Magento 1.9.2.2
* Target: Magento 2.4.3-p1
* PHP 7.4
* A custom module Foo_Migration is used to map custom attributes, tables, etc.

### Steps to reproduce
1. Starting with Magento 1.9.2.2 having an attribute set with custom attribute groups with attributes assigned
2. Migrate data to Magento 2.4.3
3. The custom attribute group has no attributes assigned

### Expected result

After migration the custom product attribute group should have the same product attributes assigned as in source Magento.

### Actual result

The custom product attribute groups are empty.

### Additional notes

I found the problem here:
https://github.com/magento/data-migration-tool/blob/ea9cc9f21d3634dd3695fd88f9c869d9535cb6a6/src/Migration/Step/Eav/Data.php#L697
If I have a group "MyCustomGroup" in Source it get's compared with "Migration_MyCustomGroup". This will never be true as the source lacks of the Prefix. As the mapping is not set here it will not be executed later.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start in src/Migration/Step/Eav/Data.php around line 697 and compare the source custom group name with the prefixed target name during mapping. Reproduce the migration from Magento 1.9.2.2 to 2.4.3 with a custom attribute group, then verify that the migrated group contains the same product attributes as the source.

Written by the indexing model from the issue text.

Assessment

Tech stack
php
Domain
data-engineering
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Clearly specified
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.