AIML: Artificial Intelligent Markup Language.

AIML Parser is a module which parses aiml tags and stores them in the database.

Project Page:AIML Parser

GIT Repository: git clone --branch 7.x-1.x https://git.drupal.org/sandbox/vipul.patil7888/2562355.git aiml_parser
cd aiml_parser

Basic Functionality Test Case: Upload the science.aiml file which is provided here and check whether it gets uploaded.
Manual reviews of other projects: from 13th november
https://www.drupal.org/node/2826713#comment-11775579
https://www.drupal.org/node/2826644#comment-11777241
https://www.drupal.org/node/2826538#comment-11777438

Manual reviews of other projects:
https://www.drupal.org/node/2425965#comment-11057771
https://www.drupal.org/node/2646234#comment-11062407
https://www.drupal.org/node/2696141#comment-11064407

Automated reviews of other projects:
https://www.drupal.org/node/2429473#comment-11060221

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

vipul.patil7888 created an issue. See original summary.

vipul.patil7888’s picture

Status: Closed (won't fix) » Needs review
saurabh.tripathi.cs’s picture

FileSize
1.76 KB
PA robot’s picture

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.

vipul.patil7888’s picture

Issue summary: View changes
vipul.patil7888’s picture

Issue summary: View changes
shaktik’s picture

Hi,

Problem/Motivation

1. I reviewed your module but it seems hook_help() is not there. Please add hook_help().

2. After enabling the module, the following Notice popped up at the top of the Module List:

Notice: Notice: Undefined index: label in entity_views_field_definition() (line 191 of /Applications/XAMPP/xamppfiles/htdocs/demo-live/sites/all/modules/entity/views/entity.views.inc).

3. You need to update description.
http://cgit.drupalcode.org/sandbox-vipul.patil7888-2562355/tree/aiml_par...

$form['aiml_file'] = array(
    '#type' => 'managed_file',
    '#title' => '',
    '#description' => t('Upload File'),
    '#upload_location' => 'public://aiml_files',
    '#attributes' => array('multiple' => 'multiple'),
    "#upload_validators"  => array("file_validate_extensions" => array("aiml")),
  );
like this
$form['aiml_file'] = array(
    '#type' => 'managed_file',
    '#title' => '',
    '#description' => t('Upload a file, allowed extensions: aiml'),
    '#upload_location' => 'public://aiml_files',
    '#attributes' => array('multiple' => 'multiple'),
    "#upload_validators"  => array("file_validate_extensions" => array("aiml")),
  );

Thanks
Shakti

shaktik’s picture

vipul.patil7888’s picture

Hi shaktik,

Thanks for reviewing my module.

1)Added hook_help().
2)I tried to reproduce this issue by enabling the module but did not get this notice. This issue is not related to the aiml_parser module.
3)Changed the description of upload button from "t('Upload File')" to "t('Upload a file, allowed extensions: aiml')".

All the fixes have been committed to sandbox.

Thanks,
Vipul

vipul.patil7888’s picture

Issue summary: View changes
Issue tags: +PAreview: review bonus
klausi’s picture

Issue summary: View changes
Issue tags: -PAreview: review bonus

Removing review bonus tag, you have not done any manual reviews, you just posted the output of an automated tool. Make sure to read through the source code of the project.

gaja_daran’s picture

Status: Needs review » Needs work

Hi vipul,

function aiml_parser_menu() {

  $items['admin/structure/aiml_parser'] = array(
    'title' => 'AIML Parser',
    'description' => 'A parser for converting AIML tags to XML and upload them to database.',
    'page callback' => 'drupal_get_form',
    'page arguments' => array('aiml_parser_form'),
    'access arguments' => array('custom permission'),
    'type' => MENU_NORMAL_ITEM,
  );
  return $items;
}

You have mentioned access arguments is custom permission. But, don't have a hook_permission. Your menu link only works for admin. You can't give other user roles to access this link

vipul.patil7888’s picture

Issue summary: View changes
vipul.patil7888’s picture

Issue summary: View changes
muthukumar sri’s picture

FileSize
104.16 KB

Hi vipul,

Please fix the some basic issues suggested by paraview (http://pareview.sh/pareview/httpsgitdrupalorgsandboxvipulpatil7888256235...) are below:

FILE: /var/www/drupal-7-pareview/pareview_temp/aiml_parser.module
---------------------------------------------------------------------------
FOUND 0 ERRORS AND 1 WARNING AFFECTING 1 LINE
---------------------------------------------------------------------------
9 | WARNING | Format should be "* Implements hook_foo().", "* Implements
| | hook_foo_BAR_ID_bar() for xyz_bar().",, "* Implements
| | hook_foo_BAR_ID_bar() for xyz-bar.html.twig.", or "*
| | Implements hook_foo_BAR_ID_bar() for xyz-bar.tpl.php.".
---------------------------------------------------------------------------

vipul.patil7888’s picture

Issue summary: View changes
vipul.patil7888’s picture

Issue summary: View changes
vipul.patil7888’s picture

Issue summary: View changes
vipul.patil7888’s picture

Hi @gaja_daran,

Thanks for reviewing this module. I have removed the access arguments for custom permission as it should be accessible to admin user only.

Thanks,
Vipul

vipul.patil7888’s picture

Hi @muthukumar sri,

Thanks for reviewing this module. I have corrected the comment format as mentioned by you in your comment above.

Thanks,
Vipul

vipul.patil7888’s picture

Status: Needs work » Needs review
Issue tags: +PAreview: review bonus
pramod_patil’s picture

Status: Needs review » Needs work

Hi Vipul,

I see that there is no permission defined in hook_menu. Write hook_permission() to define your module specific permissions and use it in hook_menu.
There might be a situation where someone want to give permission to a specific user role for AIML parsing. In such situation, hook_permission is required.

pramod_patil’s picture

Assigned: Unassigned » pramod_patil
vipul.patil7888’s picture

pramod_patil’s picture

Issue tags: -PAreview: review bonus
PA robot’s picture

Status: Needs work » Closed (duplicate)
Multiple Applications
It appears that there have been multiple project applications opened under your username:

Project 1: https://www.drupal.org/node/2716437

Project 2: https://www.drupal.org/node/2687395

As successful completion of the project application process results in the applicant being granted the 'Create Full Projects' permission, there is no need to take multiple applications through the process. Once the first application has been successfully approved, then the applicant can promote other projects without review. Because of this, posting multiple applications is not necessary, and results in additional workload for reviewers ... which in turn results in longer wait times for everyone in the queue. With this in mind, your secondary applications have been marked as 'closed(duplicate)', with only one application left open (chosen at random).

If you prefer that we proceed through this review process with a different application than the one which was left open, then feel free to close the 'open' application as a duplicate, and re-open one of the project applications which had been closed.

I'm a robot and this is an automated message from Project Applications Scraper.

klausi’s picture

Status: Closed (duplicate) » Needs work
vipul.patil7888’s picture

Hi Klausi,

Yes https://www.drupal.org/node/2716437 was created bymistake. I have commented this in https://www.drupal.org/node/2716437 issue. Thanks for pointing out.

Thanks,
Vipul

vipul.patil7888’s picture

Status: Needs work » Needs review
asiby’s picture

The file containing the php classe AimlParserReadAiml is named ReadAiml.inc.

In the spirit of adhering to PHP standards, wouldn't it better to name a class file like ClassName.class.*? The same apply to aiml_parser.info.inc also. I think that if the name does not have to follow some Drupal conventions, then it should be at least having ClassName in the class file name.

asiby’s picture

Manual Review

Individual user account
Yes: Follows the guidelines for individual user accounts.
No duplication
Yes: Does not cause module duplication and/or fragmentation.
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 guidelines for in-project documentation and/or the README Template.
Code long/complex enough for review
Yes: Follows the guidelines for project length and complexity.
Secure code
Yes: Meets the security requirements.
Coding style & Drupal API usage
  1. (*) After installing this module on a fresh Drupal 7.43, the configure link of the module does not appear and the menu item at admin/structure/aiml_parse also does not appear at all (even for user 1) regardless of the permission configurations. Basically, I cannot use it.
  2. In hook_help(), the $output variable on line #15 is overriding the one on line #14 instead of being concatenated to it. Line #5 should be $output .= '<p>' ...
  3. In the file ReadAiml.inc, the assignment at line #52 should be deleted ($pat_temp = array();) because $pat_temp is being unconditionally initialized again at line #62 and not being use between line #52 and line #62

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.

asiby’s picture

Status: Needs review » Needs work
gisle’s picture

Assigned: vipul.patil7888 » Unassigned

Please don't assign the application iisue to yourself. Please see this page about assigning ownership to issues.

PA robot’s picture

Status: Needs work » Closed (won't fix)

Closing due to lack of activity. If you are still working on this application, you should fix all known problems and then set the status to "Needs review". (See also the project application workflow).

I'm a robot and this is an automated message from Project Applications Scraper.

vipul.patil7888’s picture

Hi asiby,

Thanks a lot for reviewing this module.
1)Issue fixed as per comment on #30:-
I have fixed the issue pointed by you in your comment #30. Now filename and class name are similar to each other.

2)Issue fixed as per comment on #31:-
i)After installing this module on a fresh Drupal 7.43 or any other latest release, the configure link of the module is now appearing and the menu item at admin/structure/aiml_parse also is now appearing (even for user 1) regardless of the permission configurations.
ii)Issue in point(2) is fixed. I have added concat "." operator in $output variable.
iii)I have removed unwanted initialization of $pat_temp = array();

Please refer the screenshots attached:-
"Admin_structure_menu_Aiml_parser.png"
"configure_link_menu.png"

Thanks,
Vipul

vipul.patil7888’s picture

Status: Closed (won't fix) » Needs review
nikhilsukul’s picture

Hi Vipul,

I have verified all the above issues as mentioned by asiby and they are working properly now.

kattekrab’s picture

Issue summary: View changes
FileSize
23.85 KB
19.08 KB
12.68 KB
14.51 KB

I've just done a manual test of this module.

But I have no idea if it works or not! I don't know what AIML is, or why I would need to use it, so it's hard to test if it works.

But, it does load into simplytest.me

Perhaps think a little about your future users. Who are they? Why do they need your module?
Could add some more help text, or guidance on how to be successful with your module?

Here's some screenshots from my test.

kattekrab’s picture

Status: Needs review » Needs work
nikhilsukul’s picture

Hi Vipul,

Found a new issue, Empty or non valid AIML files (files withou AIML tags) are uploading successfully, though the database is not updating with invalid data.

vipul.patil7888’s picture

Hi Nikhil,

Thanks for Reviewing my module. I have fixed this issue by adding validation for valid AIML files.

Thanks,
Vipul

vipul.patil7888’s picture

Status: Needs work » Needs review
vipul.patil7888’s picture

Hi Saurabh,

Please check last few issues which are fixed and also review module once again and please create issues if you find any.

Thanks,
Vipul

saurabh.tripathi.cs’s picture

Hi Vipul,
All Issues raised in the above comment trail with status:

#7=>fixed
#8=>fixed
#12 =>fixed
#15 => fixed
#22 => fixed
#31 => fixed
#38 =>fixed
#40 => fixed

Thanks

vipul.patil7888’s picture

Issue summary: View changes
vipul.patil7888’s picture

Issue summary: View changes
vipul.patil7888’s picture

Issue summary: View changes
vipul.patil7888’s picture

Issue tags: +PAreview: review bonus
klausi’s picture

Status: Needs review » Fixed
FileSize
3.19 KB

Review of the 7.x-1.x branch (commit fbdf0ae):

  • Coder Sniffer has found some issues with your code (please check the Drupal coding standards). See attachment.
  • DrupalPractice has found some issues with your code, but could be false positives.
    
    FILE: /home/klausi/pareview_temp/AimlParserReadAiml.inc
    ----------------------------------------------------------------------
    FOUND 0 ERRORS AND 1 WARNING AFFECTING 1 LINE
    ----------------------------------------------------------------------
     46 | WARNING | Unused variable $aiml_obj.
    ----------------------------------------------------------------------
    
    Time: 52ms; Memory: 4Mb
    
  • 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.

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:

  1. project page: what is the use case of this module? Who creates AIML tags? Into what database is the AIML data uploaded? The Drupal database? What is the purpose then of that uploaded data, what can you do with it? Is it then exposed as a page or something? Can you describe the workflow on the project page?
  2. aiml_parser_form(): doc block is wrong, this is not hook_form(). See https://www.drupal.org/docs/develop/coding-standards/api-documentation-a... . Same for aiml_parser_form_submit().

Otherwise looks good to me.

Thanks for your contribution, Vipul!

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.

saurabh.tripathi.cs’s picture

FileSize
404.94 KB
vipul.patil7888’s picture

Thanks Klausi,
We have fixed the automatic review issues stated above also we have added more details on the project page to make users understand about the scope of this module.
This was my first module and i will follow all required guidelines and will try to contribute even better in the future.
Thanks again

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.

bincy mathew’s picture

Hi, Is it possible for this module to take the 'template' from the drupal site content?