Closed (fixed)
Project:
Drupal.org security advisory coverage applications
Component:
module
Priority:
Normal
Category:
Task
Assigned:
Unassigned
Reporter:
Created:
29 Aug 2013 at 19:59 UTC
Updated:
19 Nov 2013 at 23:56 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #1
PA robot commentedThere are some errors reported by automated review tools, did you already check them? See http://pareview.sh/pareview/httpgitdrupalorgsandboxabdirisak2074287git
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 #2
abdirisak commentedFixed.
http://pareview.sh/pareview/httpgitdrupalorgsandboxabdirisak2074287git
Project page:
https://drupal.org/sandbox/abdirisak/2074287
Git repository:
git clone http://git.drupal.org/sandbox/abdirisak/2074287.git contentaccess_roles
Comment #3
asherry commentedYou'll need to add an .install file with hook_uninstall() to remove the variable_set's. Something like this -
The ->orig_type is probably unnecessary, but since you can change a content type's machine name it's something to think about. Theoretically if they changed the content type's machine name, and had already saved settings for your module, there will be multiple variables.
Or you can add a hook for when a content type machine name is updated.
Comment #4
abdirisak commentedHi Asherry,
Thanks for your review, .install file added.
Comment #5
abdirisak commentedComment #6
sanduciprian commentedYou got some code issues with the new .install file added
http://pareview.sh/pareview/httpgitdrupalorgsandboxabdirisak2074287git
Comment #7
abdirisak commentedFixed
http://pareview.sh/pareview/httpgitdrupalorgsandboxabdirisak2074287git
Comment #8
jay.chen commentedIf you define some custom hooks, you should create a MODULE_NAME.api.php file.
For your module, you should create two hook examples for the hook_contentaccess_roles_fields_info and hook_contentaccess_roles_fields_info_alter.
See the node.api.php file at https://api.drupal.org/api/drupal/modules!node!node.api.php/7 .
Comment #9
abdirisak commentedHi Jay.Chen,
Thanks for your review, .api.php file added.
http://pareview.sh/pareview/httpgitdrupalorgsandboxabdirisak2074287git
Comment #10
stockunlocks commentedAfter manually looking over the code, I attempted to review based on an install. However, I received an error after I enabled the module, saved and then ran the Drupal database update script.
Here's what I got:
FieldException: Attempt to create a field of unknown type <em class="placeholder">contentaccessroles</em>. in field_create_field() (line 110 of /Library/WebServer/Documents/stockunlocks/modules/field/field.crud.inc).I've included a screenshot below.
Interestingly, the FIELD TYPE "Contentaccess roles" (MACHINE NAME: "field_accessroles") is available when I access
/admin/structure/types/manage/article/fields. Following the instructions for setting up access didn't produce any errors. I used an existing role. Unfortunately, it doesn't seem to have an effect when I access content as an anonymous user (no roles enabled).I used the commit dated: Sat, 7 Sep 2013 11:33:59 +0000 (13:33 +0200)
If this can be corrected, I'll gladly come back and try it again.
Comment #11
abdirisak commentedHi darrellhenry,
Thanks a lot for your time, I tested this module (drupal-7.23) and when I enabled the module, saved and then ran the Drupal database update script, I didn't got any error, I don't know which drupal version do you using. But I didn't got any error after I tested (drupal-7.23).
When you creating new content, if you don't select any role(s), so this content you created will be visible to all users. If you need to show your content to users who have specific role(s), you must select one or more role(s), otherwise the content will be visible to all users.
For example, if you create new content and select "authenticated user", and then try to access content as an anonymous user, so you will get a message denying access.
This module is working correctly, can somebody review it, please?
Comment #12
stockunlocks commented... I'm running Drupal 7.22. When I get a chance, I'll set up for 7.23 and get back to you. Thanks.
p.s. If you want to get on the "priority review list" to move your project along, check this out: https://drupal.org/node/1975228
Comment #13
jay.chen commented1. Please update the git repo on the issue summary because the link doesn't work
git clone http://drupalcode.org/sandbox/abdirisak/2074287.git contentaccess_roles. It should be
git clone http://git.drupal.org/sandbox/abdirisak/2074287.git contentaccess_roles
2. When I created a new content type via admin UI, the content access roles settings is set to disabled. But when I enabled the blog or forum modules, the settings is set to enabled.
Suppose the settings should be always set to disabled by default, right?
3. I am running Drupal 7.23, and I did see the #10 error issue sometime but I didn't find when it happened.
Comment #14
stockunlocks commentedHi, just to let you know that I've updated to Drupal 7.23 and the same error, as in #10 above, appears immediately after I enable the module and click "Save configuration".
I'm using the latest snapshot:
Sat, 7 Sep 2013 11:33:59 +0000 (13:33 +0200)(same as above).It's the exact error as in the screen shot attached above, no need to add another one here.
Comment #15
abdirisak commentedHi,
Thanks for the review(s).
1. Updated git repository link.
2. Fixed, the settings will be always disabled by default.
3. I have enabled the module and didn't see any error, So I need to know when exactly this error happen to fix the #10 error issue.
@darrellhenry,
I think you get this error, because the module installation failed at some point and is not fully installed. Could you please try to disable, uninstall then reinstall the module and clear all caches?
Please install the latest commited by first disabling and uninstalling the module
git clone http://git.drupal.org/sandbox/abdirisak/2074287.git contentaccess_roles
Comment #16
kscheirerThe description doesn't make sense, how about "Make nodes visible only to users with specific roles" instead? Otherwise this looks like a useful module.
----
Top Shelf Modules - Crafted, Curated, Contributed.
Comment #17
abdirisak commentedThanks kscheirer for your review, I have just committed your suggestion and the description has been changed.
Comment #18
sanchiz commentedHi, i did visual review and saw not correct PHPDOC
115
must be correct or removed
On the 420 line too.
This is really good idea and I can not find module with similar functionality.
Another issue about access.
If we provide a menu link for node with access only to admin, we see this link always. Is there some sort of solution for this issue?
Similar situation with views, node appear always. Checking user permission only on node page view. Is there a way to fix it?
Overall, it looks very cool!
Comment #19
abdirisak commentedHi sanchiz,
Thanks for your review.
1. Corrected phpdoc comments.
2. This module controls the user's permission only on the node page view, but not on views or teaser.
The idea is to show node teasers/views on the front page while restricting full page view access to authorized users, or to encourage anonymous users to log in or to encourage authorized users to subscribe.
Comment #20
abdirisak commentedHi,
I waited almost 20 days and no one else raises any issues, so what's the next step I've to do?
Comment #21
kscheirerNo further action is required, but the best thing you can do is get a Review Bonus by reviewing other applications. That will get you to the top of the list of projects to get reviewed (and hopefully approved). Only manual reviews count, just using http://pareview.sh is not enough.
Or if you wait a month and no one else raises any issues, I will send this application to "fixed" myself, which grants you "git vetted user" status and the ability to promote your sandboxes to full projects (including this one).
Comment #21.0
kscheirerUpdated the git repository url
Comment #22
kscheirerIt's been a month without any problems reported, so I'm promoting this myself as per https://drupal.org/node/1125818.
Thanks for your contribution, abdirisak!
I updated your account to let you 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 get 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.
----
Top Shelf Modules - Crafted, Curated, Contributed.