Failure Adding Multiple Roles to Existing User via CSV Import (Update Mode)

I am attempting to import user data into a Frappe-based system to assign multiple Role Profiles to existing users using the built-in Data Import tool.

I am utilizing the Minimal Data Duplication method, which is generally recommended for handling multi-value fields in CSV imports.

  1. Data Setup
  • Goal: To update an existing user (user@example.com) to have two roles: User and Approver.

  • Import Mode: Update Existing Records.

  • CSV Snippet (using semicolon ; delimiter):

    Code snippet

    Email;First Name;Created By;Enabled;Middle Name;Last Name;Username;Country;Language;Time Zone;User Category;Gender;Birth Date;I am looking for a job;Phone;City;User Type;Role Profile
    user@example.com;Joko;admin@gm.com;1;;Santoso;joko;Indonesia;en;Asia/Jakarta;Employee;Male;25/08/1990;0;;Bandung;System User;User
    user@example.com;;;;;;;;;;;;;;;;;Approver
    
    

    *(Note: All user detail columns are explicitly empty on the second row, except for the Email and Role Profile.)
    *

3. Core Questions

  1. Is the Minimal Data Duplication method (where only Email and Role Profile are filled on subsequent rows) the correct and supported way to add additional roles to an existing User document in a Frappe-based system?

  2. If this method is correct, why is the importer reading the value for the Email column (which is the primary key and is filled) as None when processing the second row?

  3. Are there any non-detail fields (other than Email and Role Profile), such as Username, that are mandatory even in the duplication/update rows for the system to successfully locate the existing user document and prevent the User None not found error?

Any guidance on the most effective and robust way to import multiple roles for existing users via the CSV Importer would be highly appreciated.