Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Hi,
It would be cool to add drush support for generating (and re-generating) realnames. In particular, I need this for a current project for a migration.
Patch coming up..
Thanks
Comments
Comment #1
kpa CreditAttribution: kpa commentedPatch attached.
Comment #2
tkuldeep17 CreditAttribution: tkuldeep17 commentedHi kpa,
Good patch.. It is working fine. It can ported to module.
Comment #3
Thomas Bosviel CreditAttribution: Thomas Bosviel commentedIt works. Thanks!
Comment #4
hass CreditAttribution: hass commentedThere is at least one typo in a string. Loading all users at once can run into an out of memory. How do other modules handle this? Isn't there a batch mode in drush so we may run 5.000-10.000 updates only at once? The rest looks good to me.
Comment #5
kpa CreditAttribution: kpa commentedHi hass,
Rather than just saying "there is a typo", can you point out what the typo is please? I can't see any typos...
Also, loading all users at once should be fine for the majority of use-cases. You'd need to have a fairly large number of users for this to cause memory issues, though obviously that depends on number of fields, levels of caching, etc etc. max_execution_time over CLI is normally set to 0, so there aren't any timeout issues with this.
Thanks
Comment #6
hass CreditAttribution: hass commentedSorry, I was on mobile without dreditor
Not sooo many... I ran into a lot of memory issues in Linkchecker when I've mass-loaded. It should be quite easy to add a batch so we should better be safe than sorry. Try to test with 1.000.000 users.
Comment #7
alan-ps CreditAttribution: alan-ps commentedReally good thing. I've improved previous patch in accordance with the remarks above.