Closed (fixed)
Project:
Drupal.org security advisory coverage applications
Component:
module
Priority:
Normal
Category:
Task
Assigned:
Unassigned
Issue tags:
Reporter:
Created:
8 Mar 2015 at 14:22 UTC
Updated:
18 Apr 2015 at 10:14 UTC
Jump to comment: Most recent
Comments
Comment #1
drupalove commentedComment #2
PA robot commentedThere are some errors reported by automated review tools, did you already check them? See http://pareview.sh/pareview/httpgitdrupalorgsandboxdrupalove2448299git
We 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 #3
drupalove commentedHave fixed the errors/warnings reported by the smart automated test.
Comment #4
guptas89 commentedHello ,
I tried to clone this module on my local machine. It prompt me to enter your Drupal.org passowrd.
Issue:
siddharth@siddharth:~$ git clone --branch 7.x-1.x drupalove@git.drupal.org:sandbox/drupalove/2448299.git hierarchical_select_access
Cloning into 'hierarchical_select_access'...
drupalove@git.drupal.org's password:
Permission denied, please try again.
Please make sure you have given correct git repository link. Instructions:
You can find the correct git clone command for your sandbox by clicking on the Version control tab, removing the checkbox in front of "Maintainer", and clicking Show. You can then copy-paste the git clone command from the codeblock below "Setting up repository for the first time".
Reference : https://www.drupal.org/node/1011698.
Comment #5
guptas89 commentedHi
I have go through the module repository. Following are my insight:
hierarchical_select_access.install
Remove drupal_install_schema('hierarchical_select_access'); as in Drupal7 you do not need to explicitly call drupal_install_schema(). @see: https://www.drupal.org/update/modules/6/7
hierarchical_select_access.module
- It is recommended to declare global variable on top inside a function.
global $user; should be on first line in function hierarchical_select_access_form_node_form_alter(&$form, &$form_state) {
- You can use PHP empty() function instead of hierarchical_select_access_is_array_empty(array $arr) to reduce the extra loop iteration.
Comment #6
guptas89 commentedComment #7
drupalove commentedComment #8
drupalove commented@guptas89 thanks very much for your review and the instructions which are very helpful.
I've now made all the changes you suggested.
Comment #9
stefan.r commentedAutomated Review
Review of the 7.x-1.x branch (commit 6eac8e7):
No automated test cases were found, did you consider writing Simpletests or PHPUnit tests? This is not a requirement but encouraged for professional software development.
Manual Review
'module',
'hidden',
'has_children',
'customized',
'options',
'expanded',
'hidden',
'parent_depth_limit', <--- don't hardcode these, other modules may add further link data.
<--- we don't know that the first value is the hierarchical select submit callback necessarily! Check for it specifically (unset any callbacks that start with "hs_").
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 #10
stefan.r commentedComment #11
drupalove commented@stefan.r thanks very much for the detailed review.
I have made all the changes except #11 and #12.
Sine the purpose of the module is to prevent access for certain selected roles, I prefer the user chooses/ticks who should not see the widget rather than ticking everything for them which can be confusing. What do you think?
To set its custom submit callback, the hs_menu module uses array_unshift() which prepends the submit function to the beginning of the array:
array_unshift($form['#submit'], 'hs_menu_node_form_submit');The hs_menu adds only one submit function which saves from looping and searching for hs_ items.
Also, none of the hs modules add any validation function to the node form.
Do you agree ?
Thanks for your time and support.
Kind regards,
Yousif
Comment #12
drupalove commentedComment #13
stefan.r commentedHi Yousif, I will try to look at this tomorrow. In the mean time, consider getting a PAReview bonus so one of the admins can promote this project once it's ready!
Comment #14
drupalove commentedComment #15
drupalove commentedAdded links to my manual reviews.
Thanks again @stefan.r for your support.
Comment #16
stefan.r commentedOK this looks ready to me, just a few small points:
Comment #17
stefan.r commentedComment #18
drupalove commentedHi @stefan.r, I very much appreciate that you took the time to review this module twice.
I've made the four changes, please check and set to RTBC if everything is okay.
Comment #19
stefan.r commentedComment #20
drupalove commentedComment #21
klausiRemoving review bonus tag, you have not done all manual review, you just posted the output of an automated review tool. Make sure to read through the source code of the other projects, as requested on the review bonus page
Comment #22
drupalove commentedComment #23
klausimanual review:
But otherwise looks good to me, so ...
Thanks for your contribution, drupalove!
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.
Comment #24
drupalove commentedThanks @Klausi, @stefan.r and @guptas89 for your time and input. It has been a great experience and very useful for my learning which will continue.