user entities not created in content dir on tome:export

Created on 15 December 2022, over 1 year ago
Updated 19 January 2023, over 1 year ago

Problem/Motivation

drush tome:export -y creates a content export missing users, that can not be installed with drush tome:install

Steps to reproduce

1. Open this project in gitpod
https://gitpod.io/#https://github.com/Realityloop/starterkit-drupal-foun...

2. Once the install process has completed, break terminal with CTRL/CMD+C

3. Change to the drupal directory
cd ../drupal

4. Enter DDEV ssh
ddev ssh

5. Optionally confirm Tome import works
drush tome:import -y

6. Update tome to 1.9
composer require 'drupal/tome:^1.9'

7. Clear cache for good measure
drush cr

8. Execute Tome Export after update
drush tome:export -y

Structure of generated meta/index.json

{
    "consumer.a72faba4-778b-4b9a-a867-cefeff170d1c": [
        "user.71ff0341-88b1-40c6-bf6a-1131b20cd36a"
    ]
}

9. Inspect drupal/content directory in the gitpod IDE's file explorer and see that there are no user entities

Only 1 file gets created in content dir, in my instance this was consumer.a72faba4-778b-4b9a-a867-cefeff170d1c.json

10. Execute Tome import and see that it will fail
drush tome:install -y

gitpod@DruxtFoundry-web:/var/www/html$ drush tome:install -y

 // You are about to DROP all tables in your local database and re-install Tome. Do you want to continue?: yes.         


In SiteProcess.php line 214:
                                                                                                                                                                            
  The command "/var/www/html/vendor/bin/drush tome:import --yes --uri=https://8080-realityloop-starterkitd-306rtquzkcv.ws-us79.gitpod.io --root=/var/www/html/web" failed.  
                                                                                                                                                                            
  Exit Code: 1(General error)                                                                                                                                               
                                                                                                                                                                            
  Working directory:                                                                                                                                                        
                                                                                                                                                                            
  Output:                                                                                                                                                                   
  ================                                                                                                                                                          
                                                                                                                                                                            
   [ERROR] Errors encountered when importing content:                                                                                                                       
                                                                                                                                                                            
   [ERROR] Error when running "'/var/www/html/vendor/bin/drush' 'tome:import-content'                                                                                       
           'consumer.a72faba4-778b-4b9a-a867-cefeff170d1c'":                                                                                                                
                                                                                                                                                                            
           In EntityReferenceFieldItemNormalizer.php line 90:                                                                                                               
                                                                                                                                                                            
             No "user" entity found with UUID "71ff0341-88b1-40c6-bf6a-1131b20cd36a" for field "0".                                                                         
                                                                                                                                                                            
                                                                                                                                                                            
                                                                                                                                                                            
                                                                                                                                                                            
                                                                                                                                                                            
                                                                                                                                                                            
  Error Output:                                                                                                                                                             
  ================                                                                                                                                                          
                                                                                                                                                                            

gitpod@DruxtFoundry-web:/var/www/html$ 

Proposed resolution

Remaining tasks

User interface changes

API changes

Data model changes

πŸ› Bug report
Status

Fixed

Version

1.9

Component

Code

Created by

πŸ‡¦πŸ‡ΊAustralia realityloop

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

No activities found.

Production build 0.69.0 2024