Description
Replicate User extends Replicate module to manage the cloning of user entities. The requirements for this module has been discussed here.
When you clone a user entity, the username needs to be updated to be unique. As the decision on how to update the username can be different per website, the replication of users is not managed by the Replicate module which is only an API (not taking any functional decision).
Replicate User provides a simple UI to let administrator to configure how the user entity is replicated. Username, password and email (mail & init) fields replication can be configured.
This module doesn't provide any UI to replicate users. Please have a look to Replicate UI to get an administrative interface to replicate entities.
Useful links
Project page is available here.
Pareview result is available here. (2 warnings about undefined variables are false positive as the purpose of these 2 lines are to test if these variables are defined)
git clone --branch 7.x-1.x http://git.drupal.org/sandbox/vtriclot/2452305.git replicate_user
Previous project application (been promoted as a single project due to the size of codebase)
Maintainers of this module are typhonius and vbouchet
Reviews
| Comment | File | Size | Author |
|---|
Comments
Comment #1
vbouchetComment #2
vbouchetComment #3
vbouchetComment #4
PA robot commentedWe are currently quite busy with all the project applications and we prefer projects with a review bonus. Please help reviewing and put yourself on the high priority list, then we will take a look at your project right away :-)
Also, you should get your friends, colleagues or other community members involved to review this application. Let them go through the review checklist and post a comment that sets this issue to "needs work" (they found some problems with the project) or "reviewed & tested by the community" (they found no major flaws).
I'm a robot and this is an automated message from Project Applications Scraper.
Comment #5
kunalkursija commentedHi vbouchet,
1) Your Git clone URL is imporper. i think it should be this.
2) Pareview is generating some errors.
Kindly correct them.
Comment #6
adammaloneComment #7
adammaloneI've fixed the git URL. Pareview errors are false positives as Vincent explained in the OP.
Comment #8
vbouchetComment #9
vbouchetComment #10
camprandall commentedReviewing.
Comment #11
camprandall commentedI attempted to review this, but with Replicate User, Replicate and Replicate UI turned on, I don't get a Replicate tab on the user so I can't test. Is there more to this?
Comment #12
adammaloneI think we might need to add the following patch @vbouchet.
Comment #13
adammaloneComment #14
vbouchetAs per this comment, this will be managed by replicate_ui directly. Replicate user module is only providing an admin interface to configure the replication. Replicate ui takes care if the replication interface itself.
Comment #15
vincenzo gambino commentedHi vbouchet,
nice module, why don't you apply the patch provided y tephonius in comment #3?
Pareview.sh show some CodeSniffer errors http://pareview.sh/pareview/httpgitdrupalorgsandboxvtriclot2452305git
Manual Review
Individual user account
[Yes: Follows] the guidelines for individual user accounts.
No duplication
[Yes: Does not cause] module duplication and/or fragmentation.
Extend Replication Module
Master Branch
[Yes: Follows] the guidelines for master branch.
Licensing
[Yes: Follows] the licensing requirements.
3rd party assets/code
[Yes: Follows] the guidelines for 3rd party assets/code.
README.txt/README.md
[Yes: Follows] the the guidelines for in-project documentation.
Code long/complex enough for review
[Yes: Follows] the guidelines for project length and complexity.
Secure code
I haven't done any security review
Coding style & Drupal API usage
Please fix all of the code style issues reported by pareview.sh
FILE: /var/www/drupal-7-pareview/pareview_temp/replicate_user.module
----------------------------------------------------------------------
FOUND 0 ERRORS AND 2 WARNINGS AFFECTING 2 LINES
----------------------------------------------------------------------
78 | WARNING | Variable $username is undefined.
162 | WARNING | Variable $mail is undefined.
----------------------------------------------------------------------
This review uses the Project Application Review Template.
Comment #16
vincenzo gambino commentedComment #17
adammaloneOops, my bad - I completely forgot that - @vbouchet is right!
Comment #18
adammaloneComment #19
vbouchetHi Vincenzo,
As explained in comment #14, UI is provided by replicate_ui module.
Regarding the code sniffer errors, as explained in the ticket summary, it's false positive.
Thanks,
Comment #20
vgriffin commentedThis is a useful module. I will certainly use it to build test accounts with similar names, fake email addresses, and identical roles. Because it uses entity replication, custom fields are automatically included in the replication.
Manual Review
The starred items (*) are fairly big issues and warrant going back to Needs Work. Items marked with a plus sign (+) are important and should be addressed before a stable project release. The rest of the comments in the code walkthrough are recommendations.
If added, please don't remove the security tag, we keep that for statistics and to show examples of security problems.
This review uses the Project Application Review Template.
Comment #21
vbouchetHi vgriffin,
Thank you for your feedbacks and sorry for the delay.
I fixed the critical point by disabling the checkbox and setting the default_value to 1. By default, a rule is now applied to the email field during the replication process. If you really don't want it (for testing purpose), you still can disable it with
dush vset replicate_user_mail 0.I also updated the README.txt to follow standards.
Can you give me more details about your second point, I didn't get it.
What do you mean by "does not working" regarding the Replicate UI. It's only supposed to extend Replicate features and where are not doing anything related to UI here so I don't see the relation.
As none of these points seem critical, I will change the status to Needs review, feel free to change it back to Needs work if needed.
Thanks,
Comment #22
ayesh commentedThanks for submitting the application.
I will do a manual review tonight but I read the code in git viewer - really well-written.
A few points, which all of them are minor:
- When linking to modules, use https.
- in the admin for, instead of doing a #default_value = 1, you can use variable_get()'s second parameter to return 1 as the default value. That way, submitting the form does not overwrite any previously-set variables.
Comment #23
vbouchetHi Ayesh,
- I changed the link in hook_help() to use https instead.
- Both username and email address must be unique (username because of the user's table structure, email because it's used for password retrieval - as noticed by vgriffin). I'm using variable_get during the replication process so advanced people can avoid username or email modification by changing values via drush vset. I would prefer to keep this default_value forced to 1 for now and would change it if I receive issues in the future.
Thanks,
Comment #24
vbouchetComment #25
klausimanual review:
Otherwise looks RTBC to me. Removing review bonus tag, you can add it again if you have done another 3 reviews of other projects.
Assigning to Naveen as he might have time to take a final look at this.
Comment #26
naveenvalechaReview of the 7.x-1.x branch (commit f2dba31):
This automated report was generated with PAReview.sh, your friendly project application review script. You can also use the online version to check your project. You have to get a review bonus to get a review from me.
Manual Review :
Comment #27
naveenvalechaThanks for your contribution, vbouchet!
I updated your account so you can promote this to a full project and also create new projects as either a sandbox or a "full" project.
Here are some recommended readings to help with excellent maintainership:
You can find lots more contributors chatting on IRC in #drupal-contribute. So, come hang out and stay involved!
Thanks, also, for your patience with the review process. Anyone is welcome to participate in the review process. Please consider reviewing other projects that are pending review. I encourage you to learn more about that process and join the group of reviewers.
Thanks to the dedicated reviewer(s) as well.