magento / magento/data-migration-tool

Incompatibility in data. Source document: eav_attribute. Field: backend_model. Error: Class Magento\Customer\Model\Customer\Attribute\Backend\Website is not mapped in record attribute_id=1

Open
#862 1 comment 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

### Preconditions
opensource-to-opensource magento 1.9.4.1 to magento 2.4.0
Enabled only

...

...

Migration\Step\Eav\Integrity
Migration\Step\Eav\Data
Migration\Step\Eav\Volume

...

1.
2.

### Steps to reproduce

php bin/magento migrate:data /pass_to_project/app/code/PD/Migration/etc/opensource-to-opensource/1.9.4.1/config.xml

### Expected result
No errors for standard attributes

1.

### Actual result
I've got a lot of errors for all magento standard attributes
[2021-01-04 18:28:41][ERROR]: Incompatibility in data. Source document: eav_attribute. Field: backend_model. Error: Class Magento\Customer\Model\Customer\Attribute\Backend\Website is not mapped in record attribute_id=1
[2021-01-04 18:28:41][ERROR]: Incompatibility in data. Source document: eav_attribute. Field: source_model. Error: Class Magento\Customer\Model\Customer\Attribute\Source\Website is not mapped in record attribute_id=1
[2021-01-04 18:28:41][ERROR]: Incompatibility in data. Source document: eav_attribute. Field: backend_model. Error: Class Magento\Customer\Model\Customer\Attribute\Backend\Store is not mapped in record attribute_id=2
[2021-01-04 18:28:41][ERROR]: Incompatibility in data. Source document: eav_attribute. Field: source_model. Error: Class Magento\Customer\Model\Customer\Attribute\Source\Store is not mapped in record attribute_id=2
[2021-01-04 18:28:41][ERROR]: Incompatibility in data. Source document: eav_attribute. Field: source_model. Error: Class Magento\Customer\Model\Customer\Attribute\Source\Group is not mapped in record attribute_id=10
...

1. [Screenshot, logs]

### Additional notes
As I can see, problem may be here \Migration\Reader\ClassMap::hasMap
change line if (is_string($className) && array_key_exists($className, $this->getMap())) {
to if (is_string($className) && in_array($className, $this->getMap())) {

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

The issue points to Migration\Reader\ClassMap::hasMap and the EAV step in the shown config.xml; start by tracing that check during php bin/magento migrate:data. Reproduce the stated Magento 1.9.4.1 to 2.4.0 migration and verify completion without unmapped standard-attribute errors.

Written by the indexing model from the issue text.

Assessment

Tech stack
php
Domain
database
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
38/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.