Skip to content

Error in data structure: entity values are mixed #109

@mattiaguatta

Description

@mattiaguatta

hello, have this error when try to import with sample code, Error in data structure: entity values are mixed

why??




use Magento\Framework\App\Bootstrap;
require_once(__DIR__.'/../../app/bootstrap.php');
$bootstrap = Bootstrap::create(BP, $_SERVER);
$objectManager = \Magento\Framework\App\ObjectManager::getInstance(); 
$obj = $bootstrap->getObjectManager();

$state = $obj->get('Magento\Framework\App\State');
$state->setAreaCode('frontend');

$importerModel = $objectManager->create('FireGento\FastSimpleImport\Model\Importer');

$productsArray[] = array(
        
                    'sku' => 'firegento-test',
                    'attribute_set_code' => 'Default',
                    'product_type' => 'simple',
                    'product_websites' => 'base',
                    'name' => 'FireGento Test Product',
                    'price' => '14',
                );
                
                
try {
    $importerModel->processImport($productsArray);
} catch (\Exception $e) {
    echo $e->getMessage();
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions