<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://wiki.expertiza.ncsu.edu/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Nkapadi</id>
	<title>Expertiza_Wiki - User contributions [en]</title>
	<link rel="self" type="application/atom+xml" href="https://wiki.expertiza.ncsu.edu/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Nkapadi"/>
	<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=Special:Contributions/Nkapadi"/>
	<updated>2026-06-26T12:37:41Z</updated>
	<subtitle>User contributions</subtitle>
	<generator>MediaWiki 1.41.0</generator>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2019_-_Project_E1924._Regulate_changing_of_rubrics_while_projects_are_in_progress&amp;diff=124816</id>
		<title>CSC/ECE 517 Spring 2019 - Project E1924. Regulate changing of rubrics while projects are in progress</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2019_-_Project_E1924._Regulate_changing_of_rubrics_while_projects_are_in_progress&amp;diff=124816"/>
		<updated>2019-05-01T10:50:58Z</updated>

		<summary type="html">&lt;p&gt;Nkapadi: /* Test Plan */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;''' Regulate changing of rubrics while projects are in progress '''&lt;br /&gt;
&lt;br /&gt;
Expertiza is a web application through which students can submit and peer-review learning objects (articles, code, web sites, etc). It consists of multiple features, one such feature is the ability to setup an assignment by an instructor. While setting up an assignment, the instructor would be asked to choose different kinds of rubrics. Any of these rubrics can later be edited or changed to a different rubric. A problem arises when an assignment is underway (students have already started reviewing) and a rubric is edited or changed. Some students who had started reviewing with the old rubric are not notified of the change. Only the rest of the students who had not started a review will be presented with the updated rubric.&lt;br /&gt;
&lt;br /&gt;
The goal of this project is two-fold:&lt;br /&gt;
 &lt;br /&gt;
1. If a rubric is replaced, or the items/questions are changed, then all the responses to that rubric need to be redone.&lt;br /&gt;
&lt;br /&gt;
2. The system should then email the previously done reviews to the reviewer and delete the response object and all associated answer objects. &lt;br /&gt;
&lt;br /&gt;
However, if the change does not involve an addition/deletion of questions, it is termed as a minor change. If the change is deemed as a minor change, the refactoring should not make any changes to the current implementation&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=='''Setting up and Building the Project'''==&lt;br /&gt;
Follow the Guidelines mentioned in the &amp;lt;span class=&amp;quot;plainlinks&amp;quot;&amp;gt;[https://github.com/expertiza/expertiza/blob/master/README.md read me]&amp;lt;/span&amp;gt; page of the project's Wiki Page for building the Project in a Local Environment.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=='''Project Description'''==&lt;br /&gt;
===Current Scenario===&lt;br /&gt;
Currently, when an instructor updates a questionnaire rubric of an ongoing assignment, the reviews are not reset and moreover, no notifications are sent to reviewers to update them of the changes made. As of status quo, the instructor, post making changes, would have to individually inform each reviewer of the changes made and ask them to change the reviews accordingly.&lt;br /&gt;
&lt;br /&gt;
===Expected Solution===&lt;br /&gt;
The project aims to resolve the two main issue arising from the problems mentioned above:&lt;br /&gt;
&lt;br /&gt;
* If a rubric is replaced, or the items/questions are changed, then all the reviews that have been done need to be redone&lt;br /&gt;
* The system should then email the previously done reviews to the reviewer and delete the response object and all associated answer objects.&lt;br /&gt;
&lt;br /&gt;
Further descriptions about how the project will be implemented and what files will be changed are mentioned in subsequent sections.&lt;br /&gt;
&lt;br /&gt;
=='''Design Diagrams'''==&lt;br /&gt;
===Use case Diagram===&lt;br /&gt;
&lt;br /&gt;
[[File:UseCase_rubric.png|Use Case Diagram]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===Data Flow Diagram===&lt;br /&gt;
&lt;br /&gt;
[[File:dfd_4.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The main function of the code is to change the rubric questionnaire. There are three main functions to change the rubric of a questionnaire: add, remove or edit questions. Editing a question is considered a minor change as it does not change the general format(i.e. number of questions or their types) of the rubric. The two major changes are highlighted, they are adding or removing a question.&lt;br /&gt;
&lt;br /&gt;
In case of a minor change the question in the database is simply updated, no other action/notification is required.&lt;br /&gt;
&lt;br /&gt;
In case of a major change, the reviews given for that question need to be deleted in case the question has been removed and the consequent changes need to be relayed to the appropriate databases. Moreover, the reviewers, whose reviews have been removed, need to be informed about the changes made and be asked to update the reviews via email. The email-ids for these users have to be queried from the Users database.&lt;br /&gt;
&lt;br /&gt;
=='''Proposed Solution'''==&lt;br /&gt;
The solution is divided into 2 phases viz. Identification of edit and Notification.&lt;br /&gt;
&lt;br /&gt;
===Identification of edit===&lt;br /&gt;
The primary metric for identification of a major change is when the ids of questions associated to a questionnaire change. &lt;br /&gt;
When a rubric is submitted after an edit, the update method is called. The current rubric is made such that the question type (Radio/Checkbox/True or False) is not editable, however, the wording of the question can be edited. As per the definition of a major change, it is obvious that there is no change in the question ids(records/objects) associated with the questionnaire. Hence this would be a minor change. &lt;br /&gt;
&lt;br /&gt;
The questions can be deleted and/or added. We term an edit as major edit if the change involves addition or deletion of a question because it entails a change in the objects associated with the questionnaire. The params passed to the controller also includes a tag/identifier if a new question was added. We are using this tag to identify there was a new question added and hence major change.&lt;br /&gt;
[[File:edit_questionnaire_page.png|Edit questionnaire page]]&lt;br /&gt;
In the diagram shown above, the &amp;quot;Save teammate review questionnaire&amp;quot; would result in a minor change. Clicking on the highlighted add and remove would result in a change of the questions and is therefore a major change.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===E-mail Notification===&lt;br /&gt;
Once this solution finds that the rubric has major edits and there exists some user who has started the response (corresponding records exist), email notification module is initiated. In this phase, these records are pulled from the ActiveRecord and sent to the user through email. Once the email is sent successfully, records are deleted from the DB.&lt;br /&gt;
&lt;br /&gt;
At this stage, the user has all the details already added by them and when they click on &amp;quot;Review&amp;quot;, the questions now correspond to the new rubric. This lets the user respond to the new rubric without losing data for any question. One of the motives behind sending these responses as email is that the first few questions in the review may be similar across rubrics and the user may re-use the same responses when prompted with the new rubric.&lt;br /&gt;
&lt;br /&gt;
=='''Code Changes'''==&lt;br /&gt;
Firstly, we need to check if there has been a change in the questionnaire, i.e if any question has been added or deleted. For this we use the tags in the params. The view has been coded such that it adds a tag called &amp;quot;:add_new_questions&amp;quot; whenever there is a post method to add a new question. We have used this tag to identify a major change and redirected to necessary helper methods.  This is indicated in the image below:&lt;br /&gt;
&lt;br /&gt;
[[File:new_question_added.jpg|identification of major change]]&lt;br /&gt;
&lt;br /&gt;
Similarly, we have identified when a question is deleted and redirected again to helper methods.&lt;br /&gt;
&lt;br /&gt;
The next step, is to look iterate through answers database and group the answers for the edited questionnaire per user/reviewer. The below UML diagram would assist in understanding the flow of information and the relation between the models.&lt;br /&gt;
&lt;br /&gt;
[[File:UML_diagram.png|UML diagram showing the relationship between necessary models]]&lt;br /&gt;
&lt;br /&gt;
Please note that FK stands for foreign key in the above diagram.&lt;br /&gt;
&lt;br /&gt;
Using the question ids returned from view, we obtained the response id from the answer database. We tracked this response id through the response, response_map and user models to arrive at the user id. This has been achieved using the code shown below:&lt;br /&gt;
&lt;br /&gt;
[[File:reviewer_answer_mapping.jpg|grouping of answers per reviewer]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Once we have identified the answers, user mail id and other associated information, this has to be mailed to the user and then the records deleted. This has been achieved using the code shown below:&lt;br /&gt;
&lt;br /&gt;
[[File:mailer_function.jpg|Mailer function and deleting of associated records]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=='''Test Plan'''==&lt;br /&gt;
The current rspec file describes various contexts for testing such as adding new questions if attributes weren't correctly entered etc. As stated in the earlier sections, the update method of the questionnaire controller would be edited to identify major changes and trigger emails and deletions of records of responses. A context corresponding to this in the spec file for questionnaire controller under the describe block for update would be added.&lt;br /&gt;
&lt;br /&gt;
Currently, we have added two tests: &lt;br /&gt;
#To verify whether a new question has been added or not and check whether the corresponding answers in the questionnaire have been appropriately deleted.&lt;br /&gt;
#To verify whether a question has been deleted or not and check whether the corresponding answers in the questionnaire have been appropriately deleted.&lt;br /&gt;
&lt;br /&gt;
=='''Team members'''==&lt;br /&gt;
1. Aishwarya Tirumala &amp;lt;br&amp;gt;&lt;br /&gt;
2. Nilay Kapadia &amp;lt;br&amp;gt;&lt;br /&gt;
3. Nitin Nataraj Kuncham &amp;lt;br&amp;gt;&lt;br /&gt;
4. Suraj Siddharudh &amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=='''References'''==&lt;br /&gt;
#[https://github.com/expertiza/expertiza Expertiza on GitHub]&lt;br /&gt;
#[https://www.rubyguides.com/2018/07/rspec-tutorial/ rpec tutorial]&lt;br /&gt;
#[https://www.stackoverflow.com/ Stackoverflow]&lt;/div&gt;</summary>
		<author><name>Nkapadi</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2019_-_Project_E1924._Regulate_changing_of_rubrics_while_projects_are_in_progress&amp;diff=124815</id>
		<title>CSC/ECE 517 Spring 2019 - Project E1924. Regulate changing of rubrics while projects are in progress</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2019_-_Project_E1924._Regulate_changing_of_rubrics_while_projects_are_in_progress&amp;diff=124815"/>
		<updated>2019-05-01T09:04:21Z</updated>

		<summary type="html">&lt;p&gt;Nkapadi: /* Test Plan */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;''' Regulate changing of rubrics while projects are in progress '''&lt;br /&gt;
&lt;br /&gt;
Expertiza is a web application through which students can submit and peer-review learning objects (articles, code, web sites, etc). It consists of multiple features, one such feature is the ability to setup an assignment by an instructor. While setting up an assignment, the instructor would be asked to choose different kinds of rubrics. Any of these rubrics can later be edited or changed to a different rubric. A problem arises when an assignment is underway (students have already started reviewing) and a rubric is edited or changed. Some students who had started reviewing with the old rubric are not notified of the change. Only the rest of the students who had not started a review will be presented with the updated rubric.&lt;br /&gt;
&lt;br /&gt;
The goal of this project is two-fold:&lt;br /&gt;
 &lt;br /&gt;
1. If a rubric is replaced, or the items/questions are changed, then all the responses to that rubric need to be redone.&lt;br /&gt;
&lt;br /&gt;
2. The system should then email the previously done reviews to the reviewer and delete the response object and all associated answer objects. &lt;br /&gt;
&lt;br /&gt;
However, if the change does not involve an addition/deletion of questions, it is termed as a minor change. If the change is deemed as a minor change, the refactoring should not make any changes to the current implementation&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=='''Setting up and Building the Project'''==&lt;br /&gt;
Follow the Guidelines mentioned in the &amp;lt;span class=&amp;quot;plainlinks&amp;quot;&amp;gt;[https://github.com/expertiza/expertiza/blob/master/README.md read me]&amp;lt;/span&amp;gt; page of the project's Wiki Page for building the Project in a Local Environment.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=='''Project Description'''==&lt;br /&gt;
===Current Scenario===&lt;br /&gt;
Currently, when an instructor updates a questionnaire rubric of an ongoing assignment, the reviews are not reset and moreover, no notifications are sent to reviewers to update them of the changes made. As of status quo, the instructor, post making changes, would have to individually inform each reviewer of the changes made and ask them to change the reviews accordingly.&lt;br /&gt;
&lt;br /&gt;
===Expected Solution===&lt;br /&gt;
The project aims to resolve the two main issue arising from the problems mentioned above:&lt;br /&gt;
&lt;br /&gt;
* If a rubric is replaced, or the items/questions are changed, then all the reviews that have been done need to be redone&lt;br /&gt;
* The system should then email the previously done reviews to the reviewer and delete the response object and all associated answer objects.&lt;br /&gt;
&lt;br /&gt;
Further descriptions about how the project will be implemented and what files will be changed are mentioned in subsequent sections.&lt;br /&gt;
&lt;br /&gt;
=='''Design Diagrams'''==&lt;br /&gt;
===Use case Diagram===&lt;br /&gt;
&lt;br /&gt;
[[File:UseCase_rubric.png|Use Case Diagram]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===Data Flow Diagram===&lt;br /&gt;
&lt;br /&gt;
[[File:dfd_4.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The main function of the code is to change the rubric questionnaire. There are three main functions to change the rubric of a questionnaire: add, remove or edit questions. Editing a question is considered a minor change as it does not change the general format(i.e. number of questions or their types) of the rubric. The two major changes are highlighted, they are adding or removing a question.&lt;br /&gt;
&lt;br /&gt;
In case of a minor change the question in the database is simply updated, no other action/notification is required.&lt;br /&gt;
&lt;br /&gt;
In case of a major change, the reviews given for that question need to be deleted in case the question has been removed and the consequent changes need to be relayed to the appropriate databases. Moreover, the reviewers, whose reviews have been removed, need to be informed about the changes made and be asked to update the reviews via email. The email-ids for these users have to be queried from the Users database.&lt;br /&gt;
&lt;br /&gt;
=='''Proposed Solution'''==&lt;br /&gt;
The solution is divided into 2 phases viz. Identification of edit and Notification.&lt;br /&gt;
&lt;br /&gt;
===Identification of edit===&lt;br /&gt;
The primary metric for identification of a major change is when the ids of questions associated to a questionnaire change. &lt;br /&gt;
When a rubric is submitted after an edit, the update method is called. The current rubric is made such that the question type (Radio/Checkbox/True or False) is not editable, however, the wording of the question can be edited. As per the definition of a major change, it is obvious that there is no change in the question ids(records/objects) associated with the questionnaire. Hence this would be a minor change. &lt;br /&gt;
&lt;br /&gt;
The questions can be deleted and/or added. We term an edit as major edit if the change involves addition or deletion of a question because it entails a change in the objects associated with the questionnaire. The params passed to the controller also includes a tag/identifier if a new question was added. We are using this tag to identify there was a new question added and hence major change.&lt;br /&gt;
[[File:edit_questionnaire_page.png|Edit questionnaire page]]&lt;br /&gt;
In the diagram shown above, the &amp;quot;Save teammate review questionnaire&amp;quot; would result in a minor change. Clicking on the highlighted add and remove would result in a change of the questions and is therefore a major change.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===E-mail Notification===&lt;br /&gt;
Once this solution finds that the rubric has major edits and there exists some user who has started the response (corresponding records exist), email notification module is initiated. In this phase, these records are pulled from the ActiveRecord and sent to the user through email. Once the email is sent successfully, records are deleted from the DB.&lt;br /&gt;
&lt;br /&gt;
At this stage, the user has all the details already added by them and when they click on &amp;quot;Review&amp;quot;, the questions now correspond to the new rubric. This lets the user respond to the new rubric without losing data for any question. One of the motives behind sending these responses as email is that the first few questions in the review may be similar across rubrics and the user may re-use the same responses when prompted with the new rubric.&lt;br /&gt;
&lt;br /&gt;
=='''Code Changes'''==&lt;br /&gt;
Firstly, we need to check if there has been a change in the questionnaire, i.e if any question has been added or deleted. For this we use the tags in the params. The view has been coded such that it adds a tag called &amp;quot;:add_new_questions&amp;quot; whenever there is a post method to add a new question. We have used this tag to identify a major change and redirected to necessary helper methods.  This is indicated in the image below:&lt;br /&gt;
&lt;br /&gt;
[[File:new_question_added.jpg|identification of major change]]&lt;br /&gt;
&lt;br /&gt;
Similarly, we have identified when a question is deleted and redirected again to helper methods.&lt;br /&gt;
&lt;br /&gt;
The next step, is to look iterate through answers database and group the answers for the edited questionnaire per user/reviewer. The below UML diagram would assist in understanding the flow of information and the relation between the models.&lt;br /&gt;
&lt;br /&gt;
[[File:UML_diagram.png|UML diagram showing the relationship between necessary models]]&lt;br /&gt;
&lt;br /&gt;
Please note that FK stands for foreign key in the above diagram.&lt;br /&gt;
&lt;br /&gt;
Using the question ids returned from view, we obtained the response id from the answer database. We tracked this response id through the response, response_map and user models to arrive at the user id. This has been achieved using the code shown below:&lt;br /&gt;
&lt;br /&gt;
[[File:reviewer_answer_mapping.jpg|grouping of answers per reviewer]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Once we have identified the answers, user mail id and other associated information, this has to be mailed to the user and then the records deleted. This has been achieved using the code shown below:&lt;br /&gt;
&lt;br /&gt;
[[File:mailer_function.jpg|Mailer function and deleting of associated records]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=='''Test Plan'''==&lt;br /&gt;
The current rspec file describes various contexts for testing such as adding new questions if attributes weren't correctly entered etc. As stated in the earlier sections, the update method of the questionnaire controller would be edited to identify major changes and trigger emails and deletions of records of responses. A context corresponding to this in the spec file for questionnaire controller under the describe block for update would be added.&lt;br /&gt;
&lt;br /&gt;
Currently, we have added a test to verify whether a new question has been added or not and check whether the corresponding answers in the questionnaire have been appropriately deleted.&lt;br /&gt;
&lt;br /&gt;
=='''Team members'''==&lt;br /&gt;
1. Aishwarya Tirumala &amp;lt;br&amp;gt;&lt;br /&gt;
2. Nilay Kapadia &amp;lt;br&amp;gt;&lt;br /&gt;
3. Nitin Nataraj Kuncham &amp;lt;br&amp;gt;&lt;br /&gt;
4. Suraj Siddharudh &amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=='''References'''==&lt;br /&gt;
#[https://github.com/expertiza/expertiza Expertiza on GitHub]&lt;br /&gt;
#[https://www.rubyguides.com/2018/07/rspec-tutorial/ rpec tutorial]&lt;br /&gt;
#[https://www.stackoverflow.com/ Stackoverflow]&lt;/div&gt;</summary>
		<author><name>Nkapadi</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2019_-_Project_E1924._Regulate_changing_of_rubrics_while_projects_are_in_progress&amp;diff=124814</id>
		<title>CSC/ECE 517 Spring 2019 - Project E1924. Regulate changing of rubrics while projects are in progress</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2019_-_Project_E1924._Regulate_changing_of_rubrics_while_projects_are_in_progress&amp;diff=124814"/>
		<updated>2019-05-01T09:04:12Z</updated>

		<summary type="html">&lt;p&gt;Nkapadi: /* Test Plan */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;''' Regulate changing of rubrics while projects are in progress '''&lt;br /&gt;
&lt;br /&gt;
Expertiza is a web application through which students can submit and peer-review learning objects (articles, code, web sites, etc). It consists of multiple features, one such feature is the ability to setup an assignment by an instructor. While setting up an assignment, the instructor would be asked to choose different kinds of rubrics. Any of these rubrics can later be edited or changed to a different rubric. A problem arises when an assignment is underway (students have already started reviewing) and a rubric is edited or changed. Some students who had started reviewing with the old rubric are not notified of the change. Only the rest of the students who had not started a review will be presented with the updated rubric.&lt;br /&gt;
&lt;br /&gt;
The goal of this project is two-fold:&lt;br /&gt;
 &lt;br /&gt;
1. If a rubric is replaced, or the items/questions are changed, then all the responses to that rubric need to be redone.&lt;br /&gt;
&lt;br /&gt;
2. The system should then email the previously done reviews to the reviewer and delete the response object and all associated answer objects. &lt;br /&gt;
&lt;br /&gt;
However, if the change does not involve an addition/deletion of questions, it is termed as a minor change. If the change is deemed as a minor change, the refactoring should not make any changes to the current implementation&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=='''Setting up and Building the Project'''==&lt;br /&gt;
Follow the Guidelines mentioned in the &amp;lt;span class=&amp;quot;plainlinks&amp;quot;&amp;gt;[https://github.com/expertiza/expertiza/blob/master/README.md read me]&amp;lt;/span&amp;gt; page of the project's Wiki Page for building the Project in a Local Environment.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=='''Project Description'''==&lt;br /&gt;
===Current Scenario===&lt;br /&gt;
Currently, when an instructor updates a questionnaire rubric of an ongoing assignment, the reviews are not reset and moreover, no notifications are sent to reviewers to update them of the changes made. As of status quo, the instructor, post making changes, would have to individually inform each reviewer of the changes made and ask them to change the reviews accordingly.&lt;br /&gt;
&lt;br /&gt;
===Expected Solution===&lt;br /&gt;
The project aims to resolve the two main issue arising from the problems mentioned above:&lt;br /&gt;
&lt;br /&gt;
* If a rubric is replaced, or the items/questions are changed, then all the reviews that have been done need to be redone&lt;br /&gt;
* The system should then email the previously done reviews to the reviewer and delete the response object and all associated answer objects.&lt;br /&gt;
&lt;br /&gt;
Further descriptions about how the project will be implemented and what files will be changed are mentioned in subsequent sections.&lt;br /&gt;
&lt;br /&gt;
=='''Design Diagrams'''==&lt;br /&gt;
===Use case Diagram===&lt;br /&gt;
&lt;br /&gt;
[[File:UseCase_rubric.png|Use Case Diagram]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===Data Flow Diagram===&lt;br /&gt;
&lt;br /&gt;
[[File:dfd_4.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The main function of the code is to change the rubric questionnaire. There are three main functions to change the rubric of a questionnaire: add, remove or edit questions. Editing a question is considered a minor change as it does not change the general format(i.e. number of questions or their types) of the rubric. The two major changes are highlighted, they are adding or removing a question.&lt;br /&gt;
&lt;br /&gt;
In case of a minor change the question in the database is simply updated, no other action/notification is required.&lt;br /&gt;
&lt;br /&gt;
In case of a major change, the reviews given for that question need to be deleted in case the question has been removed and the consequent changes need to be relayed to the appropriate databases. Moreover, the reviewers, whose reviews have been removed, need to be informed about the changes made and be asked to update the reviews via email. The email-ids for these users have to be queried from the Users database.&lt;br /&gt;
&lt;br /&gt;
=='''Proposed Solution'''==&lt;br /&gt;
The solution is divided into 2 phases viz. Identification of edit and Notification.&lt;br /&gt;
&lt;br /&gt;
===Identification of edit===&lt;br /&gt;
The primary metric for identification of a major change is when the ids of questions associated to a questionnaire change. &lt;br /&gt;
When a rubric is submitted after an edit, the update method is called. The current rubric is made such that the question type (Radio/Checkbox/True or False) is not editable, however, the wording of the question can be edited. As per the definition of a major change, it is obvious that there is no change in the question ids(records/objects) associated with the questionnaire. Hence this would be a minor change. &lt;br /&gt;
&lt;br /&gt;
The questions can be deleted and/or added. We term an edit as major edit if the change involves addition or deletion of a question because it entails a change in the objects associated with the questionnaire. The params passed to the controller also includes a tag/identifier if a new question was added. We are using this tag to identify there was a new question added and hence major change.&lt;br /&gt;
[[File:edit_questionnaire_page.png|Edit questionnaire page]]&lt;br /&gt;
In the diagram shown above, the &amp;quot;Save teammate review questionnaire&amp;quot; would result in a minor change. Clicking on the highlighted add and remove would result in a change of the questions and is therefore a major change.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===E-mail Notification===&lt;br /&gt;
Once this solution finds that the rubric has major edits and there exists some user who has started the response (corresponding records exist), email notification module is initiated. In this phase, these records are pulled from the ActiveRecord and sent to the user through email. Once the email is sent successfully, records are deleted from the DB.&lt;br /&gt;
&lt;br /&gt;
At this stage, the user has all the details already added by them and when they click on &amp;quot;Review&amp;quot;, the questions now correspond to the new rubric. This lets the user respond to the new rubric without losing data for any question. One of the motives behind sending these responses as email is that the first few questions in the review may be similar across rubrics and the user may re-use the same responses when prompted with the new rubric.&lt;br /&gt;
&lt;br /&gt;
=='''Code Changes'''==&lt;br /&gt;
Firstly, we need to check if there has been a change in the questionnaire, i.e if any question has been added or deleted. For this we use the tags in the params. The view has been coded such that it adds a tag called &amp;quot;:add_new_questions&amp;quot; whenever there is a post method to add a new question. We have used this tag to identify a major change and redirected to necessary helper methods.  This is indicated in the image below:&lt;br /&gt;
&lt;br /&gt;
[[File:new_question_added.jpg|identification of major change]]&lt;br /&gt;
&lt;br /&gt;
Similarly, we have identified when a question is deleted and redirected again to helper methods.&lt;br /&gt;
&lt;br /&gt;
The next step, is to look iterate through answers database and group the answers for the edited questionnaire per user/reviewer. The below UML diagram would assist in understanding the flow of information and the relation between the models.&lt;br /&gt;
&lt;br /&gt;
[[File:UML_diagram.png|UML diagram showing the relationship between necessary models]]&lt;br /&gt;
&lt;br /&gt;
Please note that FK stands for foreign key in the above diagram.&lt;br /&gt;
&lt;br /&gt;
Using the question ids returned from view, we obtained the response id from the answer database. We tracked this response id through the response, response_map and user models to arrive at the user id. This has been achieved using the code shown below:&lt;br /&gt;
&lt;br /&gt;
[[File:reviewer_answer_mapping.jpg|grouping of answers per reviewer]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Once we have identified the answers, user mail id and other associated information, this has to be mailed to the user and then the records deleted. This has been achieved using the code shown below:&lt;br /&gt;
&lt;br /&gt;
[[File:mailer_function.jpg|Mailer function and deleting of associated records]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=='''Test Plan'''==&lt;br /&gt;
The current rspec file describes various contexts for testing such as adding new questions if attributes weren't correctly entered etc. As stated in the earlier sections, the update method of the questionnaire controller would be edited to identify major changes and trigger emails and deletions of records of responses. A context corresponding to this in the spec file for questionnaire controller under the describe block for update would be added.&lt;br /&gt;
&lt;br /&gt;
#Currently, we have added a test to verify whether a new question has been added or not and check whether the corresponding answers in the questionnaire have been appropriately deleted.&lt;br /&gt;
&lt;br /&gt;
=='''Team members'''==&lt;br /&gt;
1. Aishwarya Tirumala &amp;lt;br&amp;gt;&lt;br /&gt;
2. Nilay Kapadia &amp;lt;br&amp;gt;&lt;br /&gt;
3. Nitin Nataraj Kuncham &amp;lt;br&amp;gt;&lt;br /&gt;
4. Suraj Siddharudh &amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=='''References'''==&lt;br /&gt;
#[https://github.com/expertiza/expertiza Expertiza on GitHub]&lt;br /&gt;
#[https://www.rubyguides.com/2018/07/rspec-tutorial/ rpec tutorial]&lt;br /&gt;
#[https://www.stackoverflow.com/ Stackoverflow]&lt;/div&gt;</summary>
		<author><name>Nkapadi</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2019_-_Project_E1924._Regulate_changing_of_rubrics_while_projects_are_in_progress&amp;diff=123954</id>
		<title>CSC/ECE 517 Spring 2019 - Project E1924. Regulate changing of rubrics while projects are in progress</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2019_-_Project_E1924._Regulate_changing_of_rubrics_while_projects_are_in_progress&amp;diff=123954"/>
		<updated>2019-04-13T00:49:12Z</updated>

		<summary type="html">&lt;p&gt;Nkapadi: /* Data Flow Diagram */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;''' Regulate changing of rubrics while projects are in progress '''&lt;br /&gt;
&lt;br /&gt;
Expertiza is a web application through which students can submit and peer-review learning objects (articles, code, web sites, etc). It consists of multiple features, one such feature is the ability to setup an assignment by an instructor. While setting up an assignment, the instructor would be asked to choose different kinds of rubrics. Any of these rubrics can later be edited or changed to a different rubric. A problem arises when an assignment is underway (students have already started reviewing) and a rubric is edited or changed. Some students started reviewing with the old rubric and the rest of the students who had not started a review will be presented with the updated rubric. This usually happens when an assignment is copied from a previous year and the rubrics are not updated to match the current topic. It could be at a later point that the instructor/TA realizes this and changes it. The goal of this project is two-fold: One, If a rubric is replaced, or the items/questions are changed, then all the reviews that have been done need to be redone and two, the system should then email the previously done reviews to the reviewer and delete the response object and all associated answer objects. If the change does not involve an addition/deletion of questions, it is termed as a minor change. If the change is deemed as a minor change, the refactoring should not make any changes to the current implementation&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=='''Setting up and Building the Project'''==&lt;br /&gt;
Follow the Guidelines mentioned in the &amp;lt;span class=&amp;quot;plainlinks&amp;quot;&amp;gt;[https://github.com/expertiza/expertiza/blob/master/README.md read me]&amp;lt;/span&amp;gt; page of the project's Wiki Page for building the Project in a Local Environment.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=='''Project Description'''==&lt;br /&gt;
===Current Scenario===&lt;br /&gt;
Currently, when an instructor updates a questionnaire rubric of an ongoing assignment, the reviews are not reset and moreover, no notifications are sent to reviewers to update them of the changes made. Moreover, the instructor, post making changes, would have to individually inform each reviewer of the changes made and ask them to change the reviews accordingly.&lt;br /&gt;
&lt;br /&gt;
===Expected Solution===&lt;br /&gt;
The project aims to resolve the two main issue arising from the problems mentioned above:&lt;br /&gt;
&lt;br /&gt;
* If a rubric is replaced, or the items/questions are changed, then all the reviews that have been done need to be redone&lt;br /&gt;
* The system should then email the previously done reviews to the reviewer and delete the response object and all associated answer objects.&lt;br /&gt;
&lt;br /&gt;
Further descriptions about how the project will be implemented and what files will be changed are mentioned in subsequent sections.&lt;br /&gt;
&lt;br /&gt;
=='''Design Diagrams'''==&lt;br /&gt;
===Use case Diagram===&lt;br /&gt;
&lt;br /&gt;
[[File:UseCase_rubric.png|Use Case Diagram]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===Data Flow Diagram===&lt;br /&gt;
&lt;br /&gt;
[[File:dfd_4.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The main function of the code is to change the rubric questionnaire. There are three main functions to change the rubric of a questionnaire: add, remove or edit questions. Editing a question is considered a minor change as it does not change the general format(i.e. number of questions or their types) of the rubric. The two major changes are highlighted, they are adding or removing a question.&lt;br /&gt;
&lt;br /&gt;
In case of a minor change the question in the database is simply updated, no other action/notification is required.&lt;br /&gt;
&lt;br /&gt;
In case of a major change, the reviews given for that question need to be deleted in case the question has been removed and the consequent changes need to be relayed to the appropriate databases. Moreover, the reviewers, whose reviews have been removed, need to be informed about the changes made and be asked to update the reviews via email. The email-ids for these users have to be queried from the Users database.&lt;br /&gt;
&lt;br /&gt;
=='''Proposed Solution'''==&lt;br /&gt;
The solution is divided into 2 phases viz. Identification of edit and Notification.&lt;br /&gt;
&lt;br /&gt;
===Identification of edit===&lt;br /&gt;
When a rubric is submitted after an edit, the update method is called. The current rubric is made such that the question type (Radio/Checkbox/True or False) is not editable, however, the wording of the question can be edited. The questions can be deleted and/or added. We term an edit as major edit if the change involves addition or deletion of a question and a minor edit corresponds to editing any existing questions. The params passed to the controller also includes a tag/identifier if a new question was added. We plan on using this identifier along with the number of questions to identify it the changes made were major or minor.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===E-mail Notification===&lt;br /&gt;
Once this solution finds that the rubric has major edits and there exists some user who has started the response (corresponding records exist), email notification module is initiated. In this phase, these records are pulled from the ActiveRecord and sent to the user through email. Once the email is sent successfully, records are deleted from the DB.&lt;br /&gt;
&lt;br /&gt;
At this stage, the user has all the details already added by them and when they click on &amp;quot;Review&amp;quot;, the questions now correspond to the new rubric. This lets the user to edit on the new rubric without losing data for any question. One of the motives behind sending these responses as email is that the first few questions in the review may be similar across rubrics and the user may re-use the same responses when prompted with the new rubric.&lt;br /&gt;
&lt;br /&gt;
=='''Proposed Code Changes'''==&lt;br /&gt;
Firstly, we need to check if there has been a change in the questionnaire, i.e if any question has been added or deleted. For this we pull out the records from the active database of the questions and compare it with the number of question entries in the view. We get the number of questions from the code snippet as shown below from questionnare_controller.rb.&lt;br /&gt;
&lt;br /&gt;
[[File:code2.png|Code]]&lt;br /&gt;
&lt;br /&gt;
Now, we come across two cases. &lt;br /&gt;
In the first scenario, If there is a change in the number of questions we do the necessary changes. We delete all the response objects and answers and mail the changes to the user.&lt;br /&gt;
&lt;br /&gt;
In the second scenario, If there is no change in the number of questions then there can be two possible cases. Either there really has been no change in the questions and we leave it as it is. Else, there has been equal number of additions and deletions and to detect this we check if the parameter add_new_questions is present. If it is, then there has been an update and we again do the required changes as discussed above. We check this through the code snippet below of the update method in questionnare_controller.rb.&lt;br /&gt;
&lt;br /&gt;
[[File:code1.png|Code]]&lt;br /&gt;
&lt;br /&gt;
=='''Test Plan'''==&lt;br /&gt;
The current rspec file describes various contexts for testing such as adding new questions if attributes weren't correctly entered etc. As stated in the earlier sections, the update method of the questionnaire controller would be edited to identify major changes and trigger emails and deletions of records of responses. A context corresponding to this in the spec file for questionnaire controller under the describe block for update would be added.&lt;br /&gt;
&lt;br /&gt;
At this moment we are thinking of at least 2 new test cases, both these cases correspond to editing a rubric:&lt;br /&gt;
# If there is no new question added and the question id's match with the ones in the record - validate the existence of the record&lt;br /&gt;
# If there is a new question added - assert if the email was sent&lt;br /&gt;
&lt;br /&gt;
=='''Team members'''==&lt;br /&gt;
1. Aishwarya Tirumala &amp;lt;br&amp;gt;&lt;br /&gt;
2. Nilay Kapadia &amp;lt;br&amp;gt;&lt;br /&gt;
3. Nitin Nataraj Kuncham &amp;lt;br&amp;gt;&lt;br /&gt;
4. Suraj Siddharudh &amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=='''References'''==&lt;br /&gt;
#[https://github.com/expertiza/expertiza Expertiza on GitHub]&lt;br /&gt;
#[https://www.rubyguides.com/2018/07/rspec-tutorial/ rpec tutorial]&lt;br /&gt;
#[https://www.stackoverflow.com/ Stackoverflow]&lt;/div&gt;</summary>
		<author><name>Nkapadi</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=File:Dfd_4.png&amp;diff=123689</id>
		<title>File:Dfd 4.png</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=File:Dfd_4.png&amp;diff=123689"/>
		<updated>2019-04-09T02:33:17Z</updated>

		<summary type="html">&lt;p&gt;Nkapadi: uploaded a new version of &amp;amp;quot;File:Dfd 4.png&amp;amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Nkapadi</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2019_-_Project_E1924._Regulate_changing_of_rubrics_while_projects_are_in_progress&amp;diff=123688</id>
		<title>CSC/ECE 517 Spring 2019 - Project E1924. Regulate changing of rubrics while projects are in progress</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2019_-_Project_E1924._Regulate_changing_of_rubrics_while_projects_are_in_progress&amp;diff=123688"/>
		<updated>2019-04-09T02:32:39Z</updated>

		<summary type="html">&lt;p&gt;Nkapadi: /* Data Flow Diagram */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;''' Regulate changing of rubrics while projects are in progress '''&lt;br /&gt;
&lt;br /&gt;
Expertiza is a web application through which students can submit and peer-review learning objects (articles, code, web sites, etc). It consists of multiple features, one such feature is the ability to setup an assignment by an instructor. While setting up an assignment, the instructor would be asked to choose different kinds of rubrics. Any of these rubrics can later be edited or changed to a different rubric. A problem arises when an assignment is underway (students have already started reviewing) and a rubric is edited or changed. Some students started reviewing with the old rubric and the rest of the students who had not started a review will be presented with the updated rubric. This usually happens when an assignment is copied from a previous year and the rubrics are not updated to match the current topic. It could be at a later point that the instructor/TA realizes this and changes it. The goal of this project is two-fold: One, If a rubric is replaced, or the items/questions are changed, then all the reviews that have been done need to be redone and two, the system should then email the previously done reviews to the reviewer and delete the response object and all associated answer objects.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=='''Setting up and Building the Project'''==&lt;br /&gt;
Follow the Guidelines mentioned in the &amp;lt;span class=&amp;quot;plainlinks&amp;quot;&amp;gt;[https://github.com/expertiza/expertiza/blob/master/README.md read me]&amp;lt;/span&amp;gt; page of the project's Wiki Page for building the Project in a Local Environment.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=='''Project Description'''==&lt;br /&gt;
===Current Scenario===&lt;br /&gt;
Currently, when an instructor updates a questionnaire rubric of an ongoing assignment, the reviews are not reset and moreover, no notifications are sent to reviewers to update them of the changes made. Moreover, the instructor, post making changes, would have to individually inform each reviewer of the changes made and ask them to change the reviews accordingly.&lt;br /&gt;
&lt;br /&gt;
===Expected Solution===&lt;br /&gt;
The project aims to resolve the two main issue arising from the problems mentioned above:&lt;br /&gt;
&lt;br /&gt;
* If a rubric is replaced, or the items/questions are changed, then all the reviews that have been done need to be redone&lt;br /&gt;
* The system should then email the previously done reviews to the reviewer and delete the response object and all associated answer objects.&lt;br /&gt;
&lt;br /&gt;
Further descriptions about how the project will be implemented and what files will be changed are mentioned in subsequent sections.&lt;br /&gt;
&lt;br /&gt;
=='''Design Diagrams'''==&lt;br /&gt;
===Use case Diagram===&lt;br /&gt;
&lt;br /&gt;
[[File:UseCase_rubric.png|Use Case Diagram]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===Data Flow Diagram===&lt;br /&gt;
&lt;br /&gt;
[[File:dfd_4.png]]&lt;br /&gt;
&lt;br /&gt;
=='''Proposed Solution'''==&lt;br /&gt;
The solution is divided into 2 phases viz. Identification of edit and Notification.&lt;br /&gt;
&lt;br /&gt;
===Identification of edit===&lt;br /&gt;
When a rubric is submitted after an edit, the update method is called. The current rubric is made such that the question type (Radio/Checkbox/True or False) is not editable, however, the wording of the question can be edited. The questions can be deleted and/or added. We term an edit as major edit if the change involves addition or deletion of a question and a minor edit corresponds to editing any existing questions. The params passed to the controller also includes a tag/identifier if a new question was added. We plan on using this identifier along with the number of questions to identify it the changes made were major or minor.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===E-mail Notification===&lt;br /&gt;
Once this solution finds that the rubric has major edits and there exists some user who has started the response (corresponding records exist), email notification module is initiated. In this phase, these records are pulled from the ActiveRecord and sent to the user through email. Once the email is sent successfully, records are deleted from the DB.&lt;br /&gt;
&lt;br /&gt;
At this stage, the user has all the details already added by them and when they click on &amp;quot;Review&amp;quot;, the questions now correspond to the new rubric. This lets the user to edit on the new rubric without losing data for any question. One of the motives behind sending these responses as email is that the first few questions in the review may be similar across rubrics and the user may re-use the same responses when prompted with the new rubric.&lt;br /&gt;
&lt;br /&gt;
=='''Proposed Code Changes'''==&lt;br /&gt;
Firstly, we need to check if there has been a change in the questionnaire, i.e if any question has been added or deleted. For this we pull out the records from the active database of the questions and compare it with the number of question entries in the view. We get the number of questions from the code snippet as shown below from questionnare_controller.rb.&lt;br /&gt;
&lt;br /&gt;
[[File:code2.png|Code]]&lt;br /&gt;
&lt;br /&gt;
Now, we come across two cases. &lt;br /&gt;
In the first scenario, If there is a change in the number of questions we do the necessary changes. We delete all the response objects and answers and mail the changes to the user.&lt;br /&gt;
&lt;br /&gt;
In the second scenario, If there is no change in the number of questions then there can be two possible cases. Either there really has been no change in the questions and we leave it as it is. Else, there has been equal number of additions and deletions and to detect this we check if the parameter add_new_questions is present. If it is, then there has been an update and we again do the required changes as discussed above. We check this through the code snippet below of the update method in questionnare_controller.rb.&lt;br /&gt;
&lt;br /&gt;
[[File:code1.png|Code]]&lt;br /&gt;
&lt;br /&gt;
=='''Test Plan'''==&lt;br /&gt;
The current rspec file describes various contexts for testing such as adding new questions if attributes weren't correctly entered etc. As stated in the earlier sections, the update method of the questionnaire controller would be edited to identify major changes and trigger emails and deletions of records of responses. A context corresponding to this in the spec file for questionnaire controller under the describe block for update would be added.&lt;br /&gt;
&lt;br /&gt;
At this moment we are thinking of at least 2 new test cases, both these cases correspond to editing a rubric:&lt;br /&gt;
# If there is no new question added and the question id's match with the ones in the record - validate the existence of the record&lt;br /&gt;
# If there is a new question added - assert if the email was sent&lt;/div&gt;</summary>
		<author><name>Nkapadi</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=File:Dfd_4.png&amp;diff=123686</id>
		<title>File:Dfd 4.png</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=File:Dfd_4.png&amp;diff=123686"/>
		<updated>2019-04-09T02:32:11Z</updated>

		<summary type="html">&lt;p&gt;Nkapadi: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Nkapadi</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2019_-_Project_E1924._Regulate_changing_of_rubrics_while_projects_are_in_progress&amp;diff=123685</id>
		<title>CSC/ECE 517 Spring 2019 - Project E1924. Regulate changing of rubrics while projects are in progress</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2019_-_Project_E1924._Regulate_changing_of_rubrics_while_projects_are_in_progress&amp;diff=123685"/>
		<updated>2019-04-09T02:30:02Z</updated>

		<summary type="html">&lt;p&gt;Nkapadi: /* Data Flow Diagram */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;''' Regulate changing of rubrics while projects are in progress '''&lt;br /&gt;
&lt;br /&gt;
Expertiza is a web application through which students can submit and peer-review learning objects (articles, code, web sites, etc). It consists of multiple features, one such feature is the ability to setup an assignment by an instructor. While setting up an assignment, the instructor would be asked to choose different kinds of rubrics. Any of these rubrics can later be edited or changed to a different rubric. A problem arises when an assignment is underway (students have already started reviewing) and a rubric is edited or changed. Some students started reviewing with the old rubric and the rest of the students who had not started a review will be presented with the updated rubric. This usually happens when an assignment is copied from a previous year and the rubrics are not updated to match the current topic. It could be at a later point that the instructor/TA realizes this and changes it. The goal of this project is two-fold: One, If a rubric is replaced, or the items/questions are changed, then all the reviews that have been done need to be redone and two, the system should then email the previously done reviews to the reviewer and delete the response object and all associated answer objects.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=='''Setting up and Building the Project'''==&lt;br /&gt;
Follow the Guidelines mentioned in the &amp;lt;span class=&amp;quot;plainlinks&amp;quot;&amp;gt;[https://github.com/expertiza/expertiza/blob/master/README.md read me]&amp;lt;/span&amp;gt; page of the project's Wiki Page for building the Project in a Local Environment.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=='''Project Description'''==&lt;br /&gt;
===Current Scenario===&lt;br /&gt;
Currently, when an instructor updates a questionnaire rubric of an ongoing assignment, the reviews are not reset and moreover, no notifications are sent to reviewers to update them of the changes made. Moreover, the instructor, post making changes, would have to individually inform each reviewer of the changes made and ask them to change the reviews accordingly.&lt;br /&gt;
&lt;br /&gt;
===Expected Solution===&lt;br /&gt;
The project aims to resolve the two main issue arising from the problems mentioned above:&lt;br /&gt;
&lt;br /&gt;
* If a rubric is replaced, or the items/questions are changed, then all the reviews that have been done need to be redone&lt;br /&gt;
* The system should then email the previously done reviews to the reviewer and delete the response object and all associated answer objects.&lt;br /&gt;
&lt;br /&gt;
Further descriptions about how the project will be implemented and what files will be changed are mentioned in subsequent sections.&lt;br /&gt;
&lt;br /&gt;
=='''Design Diagrams'''==&lt;br /&gt;
===Use case Diagram===&lt;br /&gt;
&lt;br /&gt;
[[File:UseCase_rubric.png|Use Case Diagram]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===Data Flow Diagram===&lt;br /&gt;
&lt;br /&gt;
[[File:dfd_2.png]]&lt;br /&gt;
&lt;br /&gt;
=='''Proposed Solution'''==&lt;br /&gt;
The solution is divided into 2 phases viz. Identification of edit and Notification.&lt;br /&gt;
&lt;br /&gt;
===Identification of edit===&lt;br /&gt;
When a rubric is submitted after an edit, the update method is called. The current rubric is made such that the question type (Radio/Checkbox/True or False) is not editable, however, the wording of the question can be edited. The questions can be deleted and/or added. We term an edit as major edit if the change involves addition or deletion of a question and a minor edit corresponds to editing any existing questions. The params passed to the controller also includes a tag/identifier if a new question was added. We plan on using this identifier along with the number of questions to identify it the changes made were major or minor.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===E-mail Notification===&lt;br /&gt;
Once this solution finds that the rubric has major edits and there exists some user who has started the response (corresponding records exist), email notification module is initiated. In this phase, these records are pulled from the ActiveRecord and sent to the user through email. Once the email is sent successfully, records are deleted from the DB.&lt;br /&gt;
&lt;br /&gt;
At this stage, the user has all the details already added by them and when they click on &amp;quot;Review&amp;quot;, the questions now correspond to the new rubric. This lets the user to edit on the new rubric without losing data for any question. One of the motives behind sending these responses as email is that the first few questions in the review may be similar across rubrics and the user may re-use the same responses when prompted with the new rubric.&lt;br /&gt;
&lt;br /&gt;
=='''Proposed Code Changes'''==&lt;br /&gt;
Firstly, we need to check if there has been a change in the questionnaire, i.e if any question has been added or deleted. For this we pull out the records from the active database of the questions and compare it with the number of question entries in the view. We get the number of questions from the code snippet as shown below from questionnare_controller.rb.&lt;br /&gt;
&lt;br /&gt;
[[File:code2.png|Code]]&lt;br /&gt;
&lt;br /&gt;
Now, we come across two cases. &lt;br /&gt;
In the first scenario, If there is a change in the number of questions we do the necessary changes. We delete all the response objects and answers and mail the changes to the user.&lt;br /&gt;
&lt;br /&gt;
In the second scenario, If there is no change in the number of questions then there can be two possible cases. Either there really has been no change in the questions and we leave it as it is. Else, there has been equal number of additions and deletions and to detect this we check if the parameter add_new_questions is present. If it is, then there has been an update and we again do the required changes as discussed above. We check this through the code snippet below of the update method in questionnare_controller.rb.&lt;br /&gt;
&lt;br /&gt;
[[File:code1.png|Code]]&lt;br /&gt;
&lt;br /&gt;
=='''Test Plan'''==&lt;br /&gt;
The current rspec file describes various contexts for testing such as adding new questions if attributes weren't correctly entered etc. As stated in the earlier sections, the update method of the questionnaire controller would be edited to identify major changes and trigger emails and deletions of records of responses. A context corresponding to this in the spec file for questionnaire controller under the describe block for update would be added.&lt;br /&gt;
&lt;br /&gt;
At this moment we are thinking of at least 2 new test cases, both these cases correspond to editing a rubric:&lt;br /&gt;
# If there is no new question added and the question id's match with the ones in the record - validate the existence of the record&lt;br /&gt;
# If there is a new question added - assert if the email was sent&lt;/div&gt;</summary>
		<author><name>Nkapadi</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=File:Dfd_2.png&amp;diff=123683</id>
		<title>File:Dfd 2.png</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=File:Dfd_2.png&amp;diff=123683"/>
		<updated>2019-04-09T02:29:33Z</updated>

		<summary type="html">&lt;p&gt;Nkapadi: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Nkapadi</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=File:Dfd.png&amp;diff=123681</id>
		<title>File:Dfd.png</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=File:Dfd.png&amp;diff=123681"/>
		<updated>2019-04-09T02:27:37Z</updated>

		<summary type="html">&lt;p&gt;Nkapadi: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Nkapadi</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2019_-_Project_E1924._Regulate_changing_of_rubrics_while_projects_are_in_progress&amp;diff=123679</id>
		<title>CSC/ECE 517 Spring 2019 - Project E1924. Regulate changing of rubrics while projects are in progress</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2019_-_Project_E1924._Regulate_changing_of_rubrics_while_projects_are_in_progress&amp;diff=123679"/>
		<updated>2019-04-09T02:27:24Z</updated>

		<summary type="html">&lt;p&gt;Nkapadi: /* Design Diagrams */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;''' Regulate changing of rubrics while projects are in progress '''&lt;br /&gt;
&lt;br /&gt;
Expertiza is a web application through which students can submit and peer-review learning objects (articles, code, web sites, etc). It consists of multiple features, one such feature is the ability to setup an assignment by an instructor. While setting up an assignment, the instructor would be asked to choose different kinds of rubrics. Any of these rubrics can later be edited or changed to a different rubric. A problem arises when an assignment is underway (students have already started reviewing) and a rubric is edited or changed. Some students started reviewing with the old rubric and the rest of the students who had not started a review will be presented with the updated rubric. This usually happens when an assignment is copied from a previous year and the rubrics are not updated to match the current topic. It could be at a later point that the instructor/TA realizes this and changes it. The goal of this project is two-fold: One, If a rubric is replaced, or the items/questions are changed, then all the reviews that have been done need to be redone and two, the system should then email the previously done reviews to the reviewer and delete the response object and all associated answer objects.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=='''Setting up and Building the Project'''==&lt;br /&gt;
Follow the Guidelines mentioned in the &amp;lt;span class=&amp;quot;plainlinks&amp;quot;&amp;gt;[https://github.com/expertiza/expertiza/blob/master/README.md read me]&amp;lt;/span&amp;gt; page of the project's Wiki Page for building the Project in a Local Environment.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=='''Project Description'''==&lt;br /&gt;
===Current Scenario===&lt;br /&gt;
Currently, when an instructor updates a questionnaire rubric of an ongoing assignment, the reviews are not reset and moreover, no notifications are sent to reviewers to update them of the changes made. Moreover, the instructor, post making changes, would have to individually inform each reviewer of the changes made and ask them to change the reviews accordingly.&lt;br /&gt;
&lt;br /&gt;
===Expected Solution===&lt;br /&gt;
The project aims to resolve the two main issue arising from the problems mentioned above:&lt;br /&gt;
&lt;br /&gt;
* If a rubric is replaced, or the items/questions are changed, then all the reviews that have been done need to be redone&lt;br /&gt;
* The system should then email the previously done reviews to the reviewer and delete the response object and all associated answer objects.&lt;br /&gt;
&lt;br /&gt;
Further descriptions about how the project will be implemented and what files will be changed are mentioned in subsequent sections.&lt;br /&gt;
&lt;br /&gt;
=='''Design Diagrams'''==&lt;br /&gt;
===Use case Diagram===&lt;br /&gt;
&lt;br /&gt;
[[File:UseCase_rubric.png|Use Case Diagram]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===Data Flow Diagram===&lt;br /&gt;
&lt;br /&gt;
=='''Proposed Solution'''==&lt;br /&gt;
The solution is divided into 2 phases viz. Identification of edit and Notification.&lt;br /&gt;
&lt;br /&gt;
===Identification of edit===&lt;br /&gt;
When a rubric is submitted after an edit, the update method is called. The current rubric is made such that the question type (Radio/Checkbox/True or False) is not editable, however, the wording of the question can be edited. The questions can be deleted and/or added. We term an edit as major edit if the change involves addition or deletion of a question and a minor edit corresponds to editing any existing questions. The params passed to the controller also includes a tag/identifier if a new question was added. We plan on using this identifier along with the number of questions to identify it the changes made were major or minor.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===E-mail Notification===&lt;br /&gt;
Once this solution finds that the rubric has major edits and there exists some user who has started the response (corresponding records exist), email notification module is initiated. In this phase, these records are pulled from the ActiveRecord and sent to the user through email. Once the email is sent successfully, records are deleted from the DB.&lt;br /&gt;
&lt;br /&gt;
At this stage, the user has all the details already added by them and when they click on &amp;quot;Review&amp;quot;, the questions now correspond to the new rubric. This lets the user to edit on the new rubric without losing data for any question. One of the motives behind sending these responses as email is that the first few questions in the review may be similar across rubrics and the user may re-use the same responses when prompted with the new rubric.&lt;br /&gt;
&lt;br /&gt;
=='''Proposed Code Changes'''==&lt;br /&gt;
Firstly, we need to check if there has been a change in the questionnaire, i.e if any question has been added or deleted. For this we pull out the records from the active database of the questions and compare it with the number of question entries in the view. We get the number of questions from the code snippet as shown below from questionnare_controller.rb.&lt;br /&gt;
&lt;br /&gt;
[[File:code2.png|Code]]&lt;br /&gt;
&lt;br /&gt;
Now, we come across two cases. &lt;br /&gt;
In the first scenario, If there is a change in the number of questions we do the necessary changes. We delete all the response objects and answers and mail the changes to the user.&lt;br /&gt;
&lt;br /&gt;
In the second scenario, If there is no change in the number of questions then there can be two possible cases. Either there really has been no change in the questions and we leave it as it is. Else, there has been equal number of additions and deletions and to detect this we check if the parameter add_new_questions is present. If it is, then there has been an update and we again do the required changes as discussed above. We check this through the code snippet below of the update method in questionnare_controller.rb.&lt;br /&gt;
&lt;br /&gt;
[[File:code1.png|Code]]&lt;br /&gt;
&lt;br /&gt;
=='''Test Plan'''==&lt;br /&gt;
The current rspec file describes various contexts for testing such as adding new questions if attributes weren't correctly entered etc. As stated in the earlier sections, the update method of the questionnaire controller would be edited to identify major changes and trigger emails and deletions of records of responses. A context corresponding to this in the spec file for questionnaire controller under the describe block for update would be added.&lt;br /&gt;
&lt;br /&gt;
At this moment we are thinking of at least 2 new test cases, both these cases correspond to editing a rubric:&lt;br /&gt;
# If there is no new question added and the question id's match with the ones in the record - validate the existence of the record&lt;br /&gt;
# If there is a new question added - assert if the email was sent&lt;/div&gt;</summary>
		<author><name>Nkapadi</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2019_-_Project_E1924._Regulate_changing_of_rubrics_while_projects_are_in_progress&amp;diff=123582</id>
		<title>CSC/ECE 517 Spring 2019 - Project E1924. Regulate changing of rubrics while projects are in progress</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2019_-_Project_E1924._Regulate_changing_of_rubrics_while_projects_are_in_progress&amp;diff=123582"/>
		<updated>2019-04-08T08:21:52Z</updated>

		<summary type="html">&lt;p&gt;Nkapadi: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;''' Regulate changing of rubrics while projects are in progress '''&lt;br /&gt;
&lt;br /&gt;
Expertiza is a web application through which students can submit and peer-review learning objects (articles, code, web sites, etc). It consists of multiple features, one such feature is the ability to setup an assignment by an instructor. While setting up an assignment, the instructor would be asked to choose different kinds of rubrics. Any of these rubrics can later be edited or changed to a different rubric. A problem arises when an assignment is underway (students have already started reviewing) and a rubric is edited or changed. Some students started reviewing with the old rubric and the rest of the students who had not started a review will be presented with the updated rubric. This usually happens when an assignment is copied from a previous year and the rubrics are not updated to match the current topic. It could be at a later point that the instructor/TA realizes this and changes it. The goal of this project is two-fold: One, If a rubric is replaced, or the items/questions are changed, then all the reviews that have been done need to be redone and two, the system should then email the previously done reviews to the reviewer and delete the response object and all associated answer objects.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=='''Setting up and Building the Project'''==&lt;br /&gt;
Follow the Guidelines mentioned in the &amp;lt;span class=&amp;quot;plainlinks&amp;quot;&amp;gt;[https://github.com/expertiza/expertiza/blob/master/README.md read me]&amp;lt;/span&amp;gt; page of the project's Wiki Page for building the Project in a Local Environment.&lt;br /&gt;
&lt;br /&gt;
=='''Project Description'''==&lt;br /&gt;
===Current Scenario===&lt;br /&gt;
Currently, when an instructor updates a questionnaire rubric of an ongoing assignment, the reviews are not reset and moreover, no notifications are sent to reviewers to update them of the changes made. Moreover, the instructor, post making changes, would have to individually inform each reviewer of the changes made and ask them to change the reviews accordingly.&lt;br /&gt;
&lt;br /&gt;
===Expected Solution===&lt;br /&gt;
The project aims to resolve the two main issue arising from the problems mentioned above:&lt;br /&gt;
&lt;br /&gt;
* If a rubric is replaced, or the items/questions are changed, then all the reviews that have been done need to be redone&lt;br /&gt;
* The system should then email the previously done reviews to the reviewer and delete the response object and all associated answer objects.&lt;br /&gt;
&lt;br /&gt;
Further descriptions about how the project will be implemented and what files will be changed are mentioned in subsequent sections.&lt;/div&gt;</summary>
		<author><name>Nkapadi</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2019_-_Project_E1924._Regulate_changing_of_rubrics_while_projects_are_in_progress&amp;diff=123581</id>
		<title>CSC/ECE 517 Spring 2019 - Project E1924. Regulate changing of rubrics while projects are in progress</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2019_-_Project_E1924._Regulate_changing_of_rubrics_while_projects_are_in_progress&amp;diff=123581"/>
		<updated>2019-04-08T08:21:21Z</updated>

		<summary type="html">&lt;p&gt;Nkapadi: /* Expected Solution */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;''' Regulate changing of rubrics while projects are in progress '''&lt;br /&gt;
Expertiza is a web application through which students can submit and peer-review learning objects (articles, code, web sites, etc). It consists of multiple features, one such feature is the ability to setup an assignment by an instructor. While setting up an assignment, the instructor would be asked to choose different kinds of rubrics. Any of these rubrics can later be edited or changed to a different rubric. A problem arises when an assignment is underway (students have already started reviewing) and a rubric is edited or changed. Some students started reviewing with the old rubric and the rest of the students who had not started a review will be presented with the updated rubric. This usually happens when an assignment is copied from a previous year and the rubrics are not updated to match the current topic. It could be at a later point that the instructor/TA realizes this and changes it. The goal of this project is two-fold: One, If a rubric is replaced, or the items/questions are changed, then all the reviews that have been done need to be redone and two, the system should then email the previously done reviews to the reviewer and delete the response object and all associated answer objects.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=='''Setting up and Building the Project'''==&lt;br /&gt;
Follow the Guidelines mentioned in the &amp;lt;span class=&amp;quot;plainlinks&amp;quot;&amp;gt;[https://github.com/expertiza/expertiza/blob/master/README.md read me]&amp;lt;/span&amp;gt; page of the project's Wiki Page for building the Project in a Local Environment.&lt;br /&gt;
&lt;br /&gt;
=='''Project Description'''==&lt;br /&gt;
===Current Scenario===&lt;br /&gt;
Currently, when an instructor updates a questionnaire rubric of an ongoing assignment, the reviews are not reset and moreover, no notifications are sent to reviewers to update them of the changes made. Moreover, the instructor, post making changes, would have to individually inform each reviewer of the changes made and ask them to change the reviews accordingly.&lt;br /&gt;
&lt;br /&gt;
===Expected Solution===&lt;br /&gt;
The project aims to resolve the two main issue arising from the problems mentioned above:&lt;br /&gt;
&lt;br /&gt;
* If a rubric is replaced, or the items/questions are changed, then all the reviews that have been done need to be redone&lt;br /&gt;
* The system should then email the previously done reviews to the reviewer and delete the response object and all associated answer objects.&lt;br /&gt;
&lt;br /&gt;
Further descriptions about how the project will be implemented and what files will be changed are mentioned in subsequent sections.&lt;/div&gt;</summary>
		<author><name>Nkapadi</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2019_-_Project_E1924._Regulate_changing_of_rubrics_while_projects_are_in_progress&amp;diff=123580</id>
		<title>CSC/ECE 517 Spring 2019 - Project E1924. Regulate changing of rubrics while projects are in progress</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2019_-_Project_E1924._Regulate_changing_of_rubrics_while_projects_are_in_progress&amp;diff=123580"/>
		<updated>2019-04-08T08:20:32Z</updated>

		<summary type="html">&lt;p&gt;Nkapadi: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;''' Regulate changing of rubrics while projects are in progress '''&lt;br /&gt;
Expertiza is a web application through which students can submit and peer-review learning objects (articles, code, web sites, etc). It consists of multiple features, one such feature is the ability to setup an assignment by an instructor. While setting up an assignment, the instructor would be asked to choose different kinds of rubrics. Any of these rubrics can later be edited or changed to a different rubric. A problem arises when an assignment is underway (students have already started reviewing) and a rubric is edited or changed. Some students started reviewing with the old rubric and the rest of the students who had not started a review will be presented with the updated rubric. This usually happens when an assignment is copied from a previous year and the rubrics are not updated to match the current topic. It could be at a later point that the instructor/TA realizes this and changes it. The goal of this project is two-fold: One, If a rubric is replaced, or the items/questions are changed, then all the reviews that have been done need to be redone and two, the system should then email the previously done reviews to the reviewer and delete the response object and all associated answer objects.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=='''Setting up and Building the Project'''==&lt;br /&gt;
Follow the Guidelines mentioned in the &amp;lt;span class=&amp;quot;plainlinks&amp;quot;&amp;gt;[https://github.com/expertiza/expertiza/blob/master/README.md read me]&amp;lt;/span&amp;gt; page of the project's Wiki Page for building the Project in a Local Environment.&lt;br /&gt;
&lt;br /&gt;
=='''Project Description'''==&lt;br /&gt;
===Current Scenario===&lt;br /&gt;
Currently, when an instructor updates a questionnaire rubric of an ongoing assignment, the reviews are not reset and moreover, no notifications are sent to reviewers to update them of the changes made. Moreover, the instructor, post making changes, would have to individually inform each reviewer of the changes made and ask them to change the reviews accordingly.&lt;br /&gt;
&lt;br /&gt;
===Expected Solution===&lt;br /&gt;
The project aims to resolve the two main issue arising from the problems mentioned above:&lt;br /&gt;
&lt;br /&gt;
1. If a rubric is replaced, or the items/questions are changed, then all the reviews that have been done need to be redone&lt;br /&gt;
2. The system should then email the previously done reviews to the reviewer and delete the response object and all associated answer objects.&lt;br /&gt;
&lt;br /&gt;
Further descriptions about how the project will be implemented and what files will be changed are mentioned in subsequent sections.&lt;/div&gt;</summary>
		<author><name>Nkapadi</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2019_-_Project_E1917._Fix_Code_Climate_issues_in_controllers_with_names_beginning_with_P_through_Z&amp;diff=122439</id>
		<title>CSC/ECE 517 Spring 2019 - Project E1917. Fix Code Climate issues in controllers with names beginning with P through Z</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2019_-_Project_E1917._Fix_Code_Climate_issues_in_controllers_with_names_beginning_with_P_through_Z&amp;diff=122439"/>
		<updated>2019-03-26T01:55:14Z</updated>

		<summary type="html">&lt;p&gt;Nkapadi: /* Implementation */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== '''About Expertiza''' ==&lt;br /&gt;
Expertiza is an open source project based on Ruby on Rails framework. Expertiza allows the instructor to create new assignments and customize new or existing assignments. It also allows the instructor to create a list of topics the students can sign up for. Students can form teams in Expertiza to work on various projects and assignments. Students can also peer review other students' submissions. Expertiza supports submission across various document types, including the URLs and wiki pages[1].&lt;br /&gt;
&lt;br /&gt;
== '''Code Climate Issues and Problem Statements''' ==&lt;br /&gt;
&lt;br /&gt;
Codeclimate is a command line interface for the Code Climate analysis platform [2]. It can detect code smells which violate ruby/rails best practices. The task is to fix certain code climate issues detected by Code Climate analysis platform in controllers with the name beginning with P through Z. These issues includes unsafe use of methods, inappropriate syntax, non-optimal code structure which violates the DRY principle and so on. There are 37 different types of issues fixed in this project.&lt;br /&gt;
&lt;br /&gt;
====List of Issues====&lt;br /&gt;
&lt;br /&gt;
*Unprotected mass assignment&lt;br /&gt;
*Use a guard clause instead of wrapping the code inside a conditional expression&lt;br /&gt;
*Do not use Time.now without zone. Use one of Time.zone.now, Time.current, Time.now.in_time_zone, Time.now.utc, Time.now.getlocal, Time.now.iso8601, Time.now.jisx0301, Time.now.rfc3339, Time.now.to_i, Time.now.to_f instead&lt;br /&gt;
*Move redirect_to &amp;quot;/&amp;quot; out of the conditional.&lt;br /&gt;
*Block has too many lines&lt;br /&gt;
*Useless assignment to variable - initheader.&lt;br /&gt;
*Replace class var @@assignment_id with a class instance var&lt;br /&gt;
*Avoid comparing a variable with multiple items in a conditional, use Array#include? Instead&lt;br /&gt;
*Identical blocks of code found in 2 locations. Consider refactoring. &lt;br /&gt;
*Favor unless over if for negative conditions.&lt;br /&gt;
*Operator = should be surrounded by a single space. &lt;br /&gt;
*Line is too long&lt;br /&gt;
*Extra empty line detected at method body beginning. &lt;br /&gt;
*Unnecessary spacing detected.&lt;br /&gt;
*Parameters should be whitelisted for mass assignment&lt;br /&gt;
*Avoid using update_attribute because it skips validations. &lt;br /&gt;
*end at 44, 4 is not aligned with def at 39, 2. &lt;br /&gt;
*Unsafe reflection method const_get called with parameter value &lt;br /&gt;
*TODO found&lt;br /&gt;
*Convert if nested inside else to elsif&lt;br /&gt;
*Similar blocks of code found in 3 locations. Consider refactoring&lt;br /&gt;
*User controlled method execution&lt;br /&gt;
*Extra blank line detected&lt;br /&gt;
*Use empty lines between method definitions. &lt;br /&gt;
*Prefer each over for&lt;br /&gt;
*Prefer Date or Time over DateTime.&lt;br /&gt;
*Omit parentheses for ternary conditions&lt;br /&gt;
*Do not place comments on the same line as the end keyword. &lt;br /&gt;
*Useless assignment to variable - controllers. Did you mean controller?&lt;br /&gt;
*end at 135, 2 is not aligned with class at 1, 0&lt;br /&gt;
*Put one space between the method name and the first argument. &lt;br /&gt;
*Space missing after colon. &lt;br /&gt;
*Use the new Ruby 1.9 hash syntax&lt;br /&gt;
*show, edit, update, destroy are not explicitly defined on the controller. &lt;br /&gt;
*Rename is_user_ta? to user_ta?&lt;br /&gt;
*Avoid comma after the last item of an array&lt;br /&gt;
*Move redirect_to view_student_teams_path student_id: student.id out of the conditional&lt;br /&gt;
&lt;br /&gt;
== '''Implementation''' ==&lt;br /&gt;
&lt;br /&gt;
There are many minor issues such as unnecessary spacing, extra blank line detected, extra parentheses used and so on. We're not going to show all these minor fixing in this section. The focus would be on some of the important issues listed above that we fixed.&lt;br /&gt;
&lt;br /&gt;
===Issue - Unprotected Mass Assignment===&lt;br /&gt;
Mass assignment is a feature of Rails which allows an application to create a record from the values of a hash. Protection for mass assignment is on by default. Query parameters must be explicitly whitelisted via permit in order to be used in mass assignment.This issue appears in different controller files. An example of how we fixed it in questions_controller.rb is shown below:&lt;br /&gt;
[[File:Unprotected mass assignment 2.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Use a guard clause instead of wrapping the code inside a conditional expression.=== &lt;br /&gt;
Used a return/unless combination to return in case the condition is false.&lt;br /&gt;
&lt;br /&gt;
[[File:Guard clause.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Do not use Time.now without zone. Use one of Time.zone.now, Time.current, Time.now.in_time_zone, Time.now.utc, Time.now.getlocal, Time.now.iso8601, Time.now.jisx0301, Time.now.rfc3339, Time.now.to_i, Time.now.to_f instead.===&lt;br /&gt;
[[File:Time zone and out of condition.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Move redirect_to &amp;quot;/&amp;quot; out of the conditional.===&lt;br /&gt;
&lt;br /&gt;
[[File:Time_zone_and_out_of_condition.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Avoid comparing a variable with multiple items in a conditional, use Array#include? Instead ===&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_5.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Favor unless over if for negative conditions.===&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_10.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Parameters should be whitelisted for mass assignment.===&lt;br /&gt;
[[File:Whitelist_and_update_attributes.png]]&lt;br /&gt;
=== Avoid using update_attribute because it skips validations===&lt;br /&gt;
&lt;br /&gt;
The method update_attribute will skip validation. Should use update_attributes instead.&lt;br /&gt;
&lt;br /&gt;
[[File:Whitelist_and_update_attributes.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Unsafe reflection method const_get called with parameter value===&lt;br /&gt;
[[File:Unsafe const_get.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Avoid comma after the last item of an array===&lt;br /&gt;
[[File:Issue_36.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Line is too long.===&lt;br /&gt;
Code climate will complain when a line is too long.&lt;br /&gt;
&lt;br /&gt;
[[File:Line too long.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Similar blocks of code found in 3 locations. Consider refactoring===&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_21.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - User controlled method execution===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===Issue - Rename is_user_ta? to user_ta?===&lt;br /&gt;
Renamed is_user_ta? to user_ta? to follow naming conventions enforced by Rubocop.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_35.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - show, edit, update, destroy are not explicitly defined on the controller.===&lt;br /&gt;
Show, edit, update and destroy have been explicitly defined to avoid confusion among filters between different controllers.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_32.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Use the new Ruby 1.9 hash syntax===&lt;br /&gt;
This ruby syntax has been deprecated as of the current ruby version(2.3.7) used in expertiza.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_33.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Space missing after colon===&lt;br /&gt;
Space has been added after colon to make the code easily readable.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_30.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Put one space between the method name and the first argument.===&lt;br /&gt;
Space has been added between method name and the first argument to make the code easily readable.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_31.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Do not place comments on the same line as the end keyword.===&lt;br /&gt;
Adding comments at the last the line of the code is considered a bad coding practice according to rubocop standards.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_27.png]]&lt;br /&gt;
&lt;br /&gt;
== '''Testing''' ==&lt;br /&gt;
&lt;br /&gt;
The Expertiza project provides 77 rspec tests under expertiza/spec and 8 of them are related to our controllers files.  After modifying those 28 files, we want to make sure these tests could still pass. We passed all the Rspec tests except for &amp;quot;response_controller&amp;quot;. However, we were not requirement to fix the issues for this controllers.&lt;br /&gt;
&lt;br /&gt;
[[File:Testing pass.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:One_failure_testing.png]]&lt;br /&gt;
&lt;br /&gt;
===Reference===&lt;br /&gt;
*1:http://wiki.expertiza.ncsu.edu/index.php/CSC/ECE_517_Fall_2017/E1784_Fix_mass_assignments_reported_by_Brakeman.rb&lt;br /&gt;
*2: https://github.com/codeclimate/codeclimate/blob/master/README.md&lt;br /&gt;
*The Class GitHub Repository: https://github.com/expertiza/expertiza&lt;br /&gt;
*The Class Code Climate:https://codeclimate.com/github/expertiza/expertiza&lt;/div&gt;</summary>
		<author><name>Nkapadi</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2019_-_Project_E1917._Fix_Code_Climate_issues_in_controllers_with_names_beginning_with_P_through_Z&amp;diff=122437</id>
		<title>CSC/ECE 517 Spring 2019 - Project E1917. Fix Code Climate issues in controllers with names beginning with P through Z</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2019_-_Project_E1917._Fix_Code_Climate_issues_in_controllers_with_names_beginning_with_P_through_Z&amp;diff=122437"/>
		<updated>2019-03-26T01:52:53Z</updated>

		<summary type="html">&lt;p&gt;Nkapadi: /* Implementation */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== '''About Expertiza''' ==&lt;br /&gt;
Expertiza is an open source project based on Ruby on Rails framework. Expertiza allows the instructor to create new assignments and customize new or existing assignments. It also allows the instructor to create a list of topics the students can sign up for. Students can form teams in Expertiza to work on various projects and assignments. Students can also peer review other students' submissions. Expertiza supports submission across various document types, including the URLs and wiki pages[1].&lt;br /&gt;
&lt;br /&gt;
== '''Code Climate Issues and Problem Statements''' ==&lt;br /&gt;
&lt;br /&gt;
Codeclimate is a command line interface for the Code Climate analysis platform [2]. It can detect code smells which violate ruby/rails best practices. The task is to fix certain code climate issues detected by Code Climate analysis platform in controllers with the name beginning with P through Z. These issues includes unsafe use of methods, inappropriate syntax, non-optimal code structure which violates the DRY principle and so on. There are 37 different types of issues fixed in this project.&lt;br /&gt;
&lt;br /&gt;
====List of Issues====&lt;br /&gt;
&lt;br /&gt;
*Unprotected mass assignment&lt;br /&gt;
*Use a guard clause instead of wrapping the code inside a conditional expression&lt;br /&gt;
*Do not use Time.now without zone. Use one of Time.zone.now, Time.current, Time.now.in_time_zone, Time.now.utc, Time.now.getlocal, Time.now.iso8601, Time.now.jisx0301, Time.now.rfc3339, Time.now.to_i, Time.now.to_f instead&lt;br /&gt;
*Move redirect_to &amp;quot;/&amp;quot; out of the conditional.&lt;br /&gt;
*Block has too many lines&lt;br /&gt;
*Useless assignment to variable - initheader.&lt;br /&gt;
*Replace class var @@assignment_id with a class instance var&lt;br /&gt;
*Avoid comparing a variable with multiple items in a conditional, use Array#include? Instead&lt;br /&gt;
*Identical blocks of code found in 2 locations. Consider refactoring. &lt;br /&gt;
*Favor unless over if for negative conditions.&lt;br /&gt;
*Operator = should be surrounded by a single space. &lt;br /&gt;
*Line is too long&lt;br /&gt;
*Extra empty line detected at method body beginning. &lt;br /&gt;
*Unnecessary spacing detected.&lt;br /&gt;
*Parameters should be whitelisted for mass assignment&lt;br /&gt;
*Avoid using update_attribute because it skips validations. &lt;br /&gt;
*end at 44, 4 is not aligned with def at 39, 2. &lt;br /&gt;
*Unsafe reflection method const_get called with parameter value &lt;br /&gt;
*TODO found&lt;br /&gt;
*Convert if nested inside else to elsif&lt;br /&gt;
*Similar blocks of code found in 3 locations. Consider refactoring&lt;br /&gt;
*User controlled method execution&lt;br /&gt;
*Extra blank line detected&lt;br /&gt;
*Use empty lines between method definitions. &lt;br /&gt;
*Prefer each over for&lt;br /&gt;
*Prefer Date or Time over DateTime.&lt;br /&gt;
*Omit parentheses for ternary conditions&lt;br /&gt;
*Do not place comments on the same line as the end keyword. &lt;br /&gt;
*Useless assignment to variable - controllers. Did you mean controller?&lt;br /&gt;
*end at 135, 2 is not aligned with class at 1, 0&lt;br /&gt;
*Put one space between the method name and the first argument. &lt;br /&gt;
*Space missing after colon. &lt;br /&gt;
*Use the new Ruby 1.9 hash syntax&lt;br /&gt;
*show, edit, update, destroy are not explicitly defined on the controller. &lt;br /&gt;
*Rename is_user_ta? to user_ta?&lt;br /&gt;
*Avoid comma after the last item of an array&lt;br /&gt;
*Move redirect_to view_student_teams_path student_id: student.id out of the conditional&lt;br /&gt;
&lt;br /&gt;
== '''Implementation''' ==&lt;br /&gt;
&lt;br /&gt;
There are many minor issues such as unnecessary spacing, extra blank line detected, extra parentheses used and so on. We're not going to show all these minor fixing in this section. The focus would be on some of the important issues listed above that we fixed.&lt;br /&gt;
&lt;br /&gt;
===Issue - Unprotected Mass Assignment===&lt;br /&gt;
Mass assignment is a feature of Rails which allows an application to create a record from the values of a hash. Protection for mass assignment is on by default. Query parameters must be explicitly whitelisted via permit in order to be used in mass assignment.This issue appears in different controller files. An example of how we fixed it in questions_controller.rb is shown below:&lt;br /&gt;
[[File:Unprotected mass assignment 2.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Use a guard clause instead of wrapping the code inside a conditional expression.=== &lt;br /&gt;
Used a return/unless combination to return in case the condition is false.&lt;br /&gt;
&lt;br /&gt;
[[File:Guard clause.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Do not use Time.now without zone. Use one of Time.zone.now, Time.current, Time.now.in_time_zone, Time.now.utc, Time.now.getlocal, Time.now.iso8601, Time.now.jisx0301, Time.now.rfc3339, Time.now.to_i, Time.now.to_f instead.===&lt;br /&gt;
[[File:Time zone and out of condition.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Move redirect_to &amp;quot;/&amp;quot; out of the conditional.===&lt;br /&gt;
&lt;br /&gt;
[[File:Time_zone_and_out_of_condition.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Avoid comparing a variable with multiple items in a conditional, use Array#include? Instead ===&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_5.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Favor unless over if for negative conditions.===&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_10.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Parameters should be whitelisted for mass assignment.===&lt;br /&gt;
[[File:Whitelist_and_update_attributes.png]]&lt;br /&gt;
=== Avoid using update_attribute because it skips validations===&lt;br /&gt;
&lt;br /&gt;
The method update_attribute will skip validation. Should use update_attributes instead.&lt;br /&gt;
&lt;br /&gt;
[[File:Whitelist_and_update_attributes.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Unsafe reflection method const_get called with parameter value===&lt;br /&gt;
[[File:Unsafe const_get.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Avoid comma after the last item of an array===&lt;br /&gt;
[[File:Issue_36.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Line is too long.===&lt;br /&gt;
Code climate will complain when a line is too long.&lt;br /&gt;
&lt;br /&gt;
[[File:Line too long.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Similar blocks of code found in 3 locations. Consider refactoring===&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_21.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - User controlled method execution===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===Issue - Prefer each over for===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===Issue - Rename is_user_ta? to user_ta?===&lt;br /&gt;
Renamed is_user_ta? to user_ta? to follow naming conventions enforced by Rubocop.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_35.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - show, edit, update, destroy are not explicitly defined on the controller.===&lt;br /&gt;
Show, edit, update and destroy have been explicitly defined to avoid confusion among filters between different controllers.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_32.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Use the new Ruby 1.9 hash syntax===&lt;br /&gt;
This ruby syntax has been deprecated as of the current ruby version(2.3.7) used in expertiza.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_33.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Space missing after colon===&lt;br /&gt;
Space has been added after colon to make the code easily readable.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_30.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Put one space between the method name and the first argument.===&lt;br /&gt;
Space has been added between method name and the first argument to make the code easily readable.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_31.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Do not place comments on the same line as the end keyword.===&lt;br /&gt;
Adding comments at the last the line of the code is considered a bad coding practice according to rubocop standards.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_27.png]]&lt;br /&gt;
&lt;br /&gt;
== '''Testing''' ==&lt;br /&gt;
&lt;br /&gt;
The Expertiza project provides 77 rspec tests under expertiza/spec and 8 of them are related to our controllers files.  After modifying those 28 files, we want to make sure these tests could still pass. We passed all the Rspec tests except for &amp;quot;response_controller&amp;quot;. However, we were not requirement to fix the issues for this controllers.&lt;br /&gt;
&lt;br /&gt;
[[File:Testing pass.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:One_failure_testing.png]]&lt;br /&gt;
&lt;br /&gt;
===Reference===&lt;br /&gt;
*1:http://wiki.expertiza.ncsu.edu/index.php/CSC/ECE_517_Fall_2017/E1784_Fix_mass_assignments_reported_by_Brakeman.rb&lt;br /&gt;
*2: https://github.com/codeclimate/codeclimate/blob/master/README.md&lt;br /&gt;
*The Class GitHub Repository: https://github.com/expertiza/expertiza&lt;br /&gt;
*The Class Code Climate:https://codeclimate.com/github/expertiza/expertiza&lt;/div&gt;</summary>
		<author><name>Nkapadi</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2019_-_Project_E1917._Fix_Code_Climate_issues_in_controllers_with_names_beginning_with_P_through_Z&amp;diff=122436</id>
		<title>CSC/ECE 517 Spring 2019 - Project E1917. Fix Code Climate issues in controllers with names beginning with P through Z</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2019_-_Project_E1917._Fix_Code_Climate_issues_in_controllers_with_names_beginning_with_P_through_Z&amp;diff=122436"/>
		<updated>2019-03-26T01:48:32Z</updated>

		<summary type="html">&lt;p&gt;Nkapadi: /* Implementation */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== '''About Expertiza''' ==&lt;br /&gt;
Expertiza is an open source project based on Ruby on Rails framework. Expertiza allows the instructor to create new assignments and customize new or existing assignments. It also allows the instructor to create a list of topics the students can sign up for. Students can form teams in Expertiza to work on various projects and assignments. Students can also peer review other students' submissions. Expertiza supports submission across various document types, including the URLs and wiki pages[1].&lt;br /&gt;
&lt;br /&gt;
== '''Code Climate Issues and Problem Statements''' ==&lt;br /&gt;
&lt;br /&gt;
Codeclimate is a command line interface for the Code Climate analysis platform [2]. It can detect code smells which violate ruby/rails best practices. The task is to fix certain code climate issues detected by Code Climate analysis platform in controllers with the name beginning with P through Z. These issues includes unsafe use of methods, inappropriate syntax, non-optimal code structure which violates the DRY principle and so on. There are 37 different types of issues fixed in this project.&lt;br /&gt;
&lt;br /&gt;
====List of Issues====&lt;br /&gt;
&lt;br /&gt;
*Unprotected mass assignment&lt;br /&gt;
*Use a guard clause instead of wrapping the code inside a conditional expression&lt;br /&gt;
*Do not use Time.now without zone. Use one of Time.zone.now, Time.current, Time.now.in_time_zone, Time.now.utc, Time.now.getlocal, Time.now.iso8601, Time.now.jisx0301, Time.now.rfc3339, Time.now.to_i, Time.now.to_f instead&lt;br /&gt;
*Move redirect_to &amp;quot;/&amp;quot; out of the conditional.&lt;br /&gt;
*Block has too many lines&lt;br /&gt;
*Useless assignment to variable - initheader.&lt;br /&gt;
*Replace class var @@assignment_id with a class instance var&lt;br /&gt;
*Avoid comparing a variable with multiple items in a conditional, use Array#include? Instead&lt;br /&gt;
*Identical blocks of code found in 2 locations. Consider refactoring. &lt;br /&gt;
*Favor unless over if for negative conditions.&lt;br /&gt;
*Operator = should be surrounded by a single space. &lt;br /&gt;
*Line is too long&lt;br /&gt;
*Extra empty line detected at method body beginning. &lt;br /&gt;
*Unnecessary spacing detected.&lt;br /&gt;
*Parameters should be whitelisted for mass assignment&lt;br /&gt;
*Avoid using update_attribute because it skips validations. &lt;br /&gt;
*end at 44, 4 is not aligned with def at 39, 2. &lt;br /&gt;
*Unsafe reflection method const_get called with parameter value &lt;br /&gt;
*TODO found&lt;br /&gt;
*Convert if nested inside else to elsif&lt;br /&gt;
*Similar blocks of code found in 3 locations. Consider refactoring&lt;br /&gt;
*User controlled method execution&lt;br /&gt;
*Extra blank line detected&lt;br /&gt;
*Use empty lines between method definitions. &lt;br /&gt;
*Prefer each over for&lt;br /&gt;
*Prefer Date or Time over DateTime.&lt;br /&gt;
*Omit parentheses for ternary conditions&lt;br /&gt;
*Do not place comments on the same line as the end keyword. &lt;br /&gt;
*Useless assignment to variable - controllers. Did you mean controller?&lt;br /&gt;
*end at 135, 2 is not aligned with class at 1, 0&lt;br /&gt;
*Put one space between the method name and the first argument. &lt;br /&gt;
*Space missing after colon. &lt;br /&gt;
*Use the new Ruby 1.9 hash syntax&lt;br /&gt;
*show, edit, update, destroy are not explicitly defined on the controller. &lt;br /&gt;
*Rename is_user_ta? to user_ta?&lt;br /&gt;
*Avoid comma after the last item of an array&lt;br /&gt;
*Move redirect_to view_student_teams_path student_id: student.id out of the conditional&lt;br /&gt;
&lt;br /&gt;
== '''Implementation''' ==&lt;br /&gt;
&lt;br /&gt;
There are many minor issues such as unnecessary spacing, extra blank line detected, extra parentheses used and so on. We're not going to show all these minor fixing in this section. The focus would be on some of the important issues listed above that we fixed.&lt;br /&gt;
&lt;br /&gt;
===Issue - Unprotected Mass Assignment===&lt;br /&gt;
Mass assignment is a feature of Rails which allows an application to create a record from the values of a hash. Protection for mass assignment is on by default. Query parameters must be explicitly whitelisted via permit in order to be used in mass assignment.This issue appears in different controller files. An example of how we fixed it in questions_controller.rb is shown below:&lt;br /&gt;
[[File:Unprotected mass assignment 2.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Use a guard clause instead of wrapping the code inside a conditional expression.=== &lt;br /&gt;
Used a return/unless combination to return in case the condition is false.&lt;br /&gt;
&lt;br /&gt;
[[File:Guard clause.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Do not use Time.now without zone. Use one of Time.zone.now, Time.current, Time.now.in_time_zone, Time.now.utc, Time.now.getlocal, Time.now.iso8601, Time.now.jisx0301, Time.now.rfc3339, Time.now.to_i, Time.now.to_f instead.===&lt;br /&gt;
[[File:Time zone and out of condition.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Move redirect_to &amp;quot;/&amp;quot; out of the conditional.===&lt;br /&gt;
&lt;br /&gt;
[[File:Time_zone_and_out_of_condition.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Avoid comparing a variable with multiple items in a conditional, use Array#include? Instead ===&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_5.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Favor unless over if for negative conditions.===&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_10.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Parameters should be whitelisted for mass assignment.===&lt;br /&gt;
[[File:Whitelist_and_update_attributes.png]]&lt;br /&gt;
=== Avoid using update_attribute because it skips validations===&lt;br /&gt;
&lt;br /&gt;
The method update_attribute will skip validation. Should use update_attributes instead.&lt;br /&gt;
&lt;br /&gt;
[[File:Whitelist_and_update_attributes.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Unsafe reflection method const_get called with parameter value===&lt;br /&gt;
[[File:Unsafe const_get.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Avoid comma after the last item of an array===&lt;br /&gt;
[[File:Issue_36.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Line is too long.===&lt;br /&gt;
Code climate will complain when a line is too long.&lt;br /&gt;
&lt;br /&gt;
[[File:Line too long.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Similar blocks of code found in 3 locations. Consider refactoring===&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_21.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - User controlled method execution===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===Issue - Use empty lines between method definitions.===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===Issue - Prefer each over for===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===Issue - Rename is_user_ta? to user_ta?===&lt;br /&gt;
Renamed is_user_ta? to user_ta? to follow naming conventions enforced by Rubocop.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_35.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - show, edit, update, destroy are not explicitly defined on the controller.===&lt;br /&gt;
Show, edit, update and destroy have been explicitly defined to avoid confusion among filters between different controllers.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_32.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Use the new Ruby 1.9 hash syntax===&lt;br /&gt;
This ruby syntax has been deprecated as of the current ruby version(2.3.7) used in expertiza.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_33.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Space missing after colon===&lt;br /&gt;
Space has been added after colon to make the code easily readable.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_30.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Put one space between the method name and the first argument.===&lt;br /&gt;
Space has been added between method name and the first argument to make the code easily readable.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_31.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Do not place comments on the same line as the end keyword.===&lt;br /&gt;
Adding comments at the last the line of the code is considered a bad coding practice according to rubocop standards.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_27.png]]&lt;br /&gt;
&lt;br /&gt;
== '''Testing''' ==&lt;br /&gt;
&lt;br /&gt;
The Expertiza project provides 77 rspec tests under expertiza/spec and 8 of them are related to our controllers files.  After modifying those 28 files, we want to make sure these tests could still pass. We passed all the Rspec tests except for &amp;quot;response_controller&amp;quot;. However, we were not requirement to fix the issues for this controllers.&lt;br /&gt;
&lt;br /&gt;
[[File:Testing pass.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:One_failure_testing.png]]&lt;br /&gt;
&lt;br /&gt;
===Reference===&lt;br /&gt;
*1:http://wiki.expertiza.ncsu.edu/index.php/CSC/ECE_517_Fall_2017/E1784_Fix_mass_assignments_reported_by_Brakeman.rb&lt;br /&gt;
*2: https://github.com/codeclimate/codeclimate/blob/master/README.md&lt;br /&gt;
*The Class GitHub Repository: https://github.com/expertiza/expertiza&lt;br /&gt;
*The Class Code Climate:https://codeclimate.com/github/expertiza/expertiza&lt;/div&gt;</summary>
		<author><name>Nkapadi</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2019_-_Project_E1917._Fix_Code_Climate_issues_in_controllers_with_names_beginning_with_P_through_Z&amp;diff=122431</id>
		<title>CSC/ECE 517 Spring 2019 - Project E1917. Fix Code Climate issues in controllers with names beginning with P through Z</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2019_-_Project_E1917._Fix_Code_Climate_issues_in_controllers_with_names_beginning_with_P_through_Z&amp;diff=122431"/>
		<updated>2019-03-26T01:41:21Z</updated>

		<summary type="html">&lt;p&gt;Nkapadi: /* Issue - Similar blocks of code found in 3 locations. Consider refactoring */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== '''About Expertiza''' ==&lt;br /&gt;
Expertiza is an open source project based on Ruby on Rails framework. Expertiza allows the instructor to create new assignments and customize new or existing assignments. It also allows the instructor to create a list of topics the students can sign up for. Students can form teams in Expertiza to work on various projects and assignments. Students can also peer review other students' submissions. Expertiza supports submission across various document types, including the URLs and wiki pages[1].&lt;br /&gt;
&lt;br /&gt;
== '''Code Climate Issues and Problem Statements''' ==&lt;br /&gt;
&lt;br /&gt;
Codeclimate is a command line interface for the Code Climate analysis platform [2]. It can detect code smells which violate ruby/rails best practices. The task is to fix certain code climate issues detected by Code Climate analysis platform in controllers with the name beginning with P through Z. These issues includes unsafe use of methods, inappropriate syntax, non-optimal code structure which violates the DRY principle and so on. There are 37 different types of issues fixed in this project.&lt;br /&gt;
&lt;br /&gt;
====List of Issues====&lt;br /&gt;
&lt;br /&gt;
*Unprotected mass assignment&lt;br /&gt;
*Use a guard clause instead of wrapping the code inside a conditional expression&lt;br /&gt;
*Do not use Time.now without zone. Use one of Time.zone.now, Time.current, Time.now.in_time_zone, Time.now.utc, Time.now.getlocal, Time.now.iso8601, Time.now.jisx0301, Time.now.rfc3339, Time.now.to_i, Time.now.to_f instead&lt;br /&gt;
*Move redirect_to &amp;quot;/&amp;quot; out of the conditional.&lt;br /&gt;
*Block has too many lines&lt;br /&gt;
*Useless assignment to variable - initheader.&lt;br /&gt;
*Replace class var @@assignment_id with a class instance var&lt;br /&gt;
*Avoid comparing a variable with multiple items in a conditional, use Array#include? Instead&lt;br /&gt;
*Identical blocks of code found in 2 locations. Consider refactoring. &lt;br /&gt;
*Favor unless over if for negative conditions.&lt;br /&gt;
*Operator = should be surrounded by a single space. &lt;br /&gt;
*Line is too long&lt;br /&gt;
*Extra empty line detected at method body beginning. &lt;br /&gt;
*Unnecessary spacing detected.&lt;br /&gt;
*Parameters should be whitelisted for mass assignment&lt;br /&gt;
*Avoid using update_attribute because it skips validations. &lt;br /&gt;
*end at 44, 4 is not aligned with def at 39, 2. &lt;br /&gt;
*Unsafe reflection method const_get called with parameter value &lt;br /&gt;
*TODO found&lt;br /&gt;
*Convert if nested inside else to elsif&lt;br /&gt;
*Similar blocks of code found in 3 locations. Consider refactoring&lt;br /&gt;
*User controlled method execution&lt;br /&gt;
*Extra blank line detected&lt;br /&gt;
*Use empty lines between method definitions. &lt;br /&gt;
*Prefer each over for&lt;br /&gt;
*Prefer Date or Time over DateTime.&lt;br /&gt;
*Omit parentheses for ternary conditions&lt;br /&gt;
*Do not place comments on the same line as the end keyword. &lt;br /&gt;
*Useless assignment to variable - controllers. Did you mean controller?&lt;br /&gt;
*end at 135, 2 is not aligned with class at 1, 0&lt;br /&gt;
*Put one space between the method name and the first argument. &lt;br /&gt;
*Space missing after colon. &lt;br /&gt;
*Use the new Ruby 1.9 hash syntax&lt;br /&gt;
*show, edit, update, destroy are not explicitly defined on the controller. &lt;br /&gt;
*Rename is_user_ta? to user_ta?&lt;br /&gt;
*Avoid comma after the last item of an array&lt;br /&gt;
*Move redirect_to view_student_teams_path student_id: student.id out of the conditional&lt;br /&gt;
&lt;br /&gt;
== '''Implementation''' ==&lt;br /&gt;
&lt;br /&gt;
There are many minor issues such as unnecessary spacing, extra blank line detected, extra parentheses used and so on. We're not going to show all these minor fixing in this section. The focus would be on some of the important issues listed above that we fixed.&lt;br /&gt;
&lt;br /&gt;
===Issue - Unprotected Mass Assignment===&lt;br /&gt;
Mass assignment is a feature of Rails which allows an application to create a record from the values of a hash. Protection for mass assignment is on by default. Query parameters must be explicitly whitelisted via permit in order to be used in mass assignment.This issue appears in different controller files. An example of how we fixed it in questions_controller.rb is shown below:&lt;br /&gt;
[[File:Unprotected mass assignment 2.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Use a guard clause instead of wrapping the code inside a conditional expression.=== &lt;br /&gt;
Used a return/unless combination to return in case the condition is false.&lt;br /&gt;
&lt;br /&gt;
[[File:Guard clause.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Do not use Time.now without zone. Use one of Time.zone.now, Time.current, Time.now.in_time_zone, Time.now.utc, Time.now.getlocal, Time.now.iso8601, Time.now.jisx0301, Time.now.rfc3339, Time.now.to_i, Time.now.to_f instead.===&lt;br /&gt;
[[File:Time zone and out of condition.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Move redirect_to &amp;quot;/&amp;quot; out of the conditional.===&lt;br /&gt;
&lt;br /&gt;
[[File:Time_zone_and_out_of_condition.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Avoid comparing a variable with multiple items in a conditional, use Array#include? Instead ===&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_5.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Favor unless over if for negative conditions.===&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_10.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Parameters should be whitelisted for mass assignment.===&lt;br /&gt;
[[File:Whitelist_and_update_attributes.png]]&lt;br /&gt;
=== Avoid using update_attribute because it skips validations===&lt;br /&gt;
&lt;br /&gt;
The method update_attribute will skip validation. Should use update_attributes instead.&lt;br /&gt;
&lt;br /&gt;
[[File:Whitelist_and_update_attributes.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Unsafe reflection method const_get called with parameter value===&lt;br /&gt;
[[File:Unsafe const_get.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Avoid comma after the last item of an array===&lt;br /&gt;
[[File:Issue_36.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Line is too long.===&lt;br /&gt;
Code climate will complain when a line is too long.&lt;br /&gt;
&lt;br /&gt;
[[File:Line too long.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Similar blocks of code found in 3 locations. Consider refactoring===&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_21.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - User controlled method execution===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===Issue - Extra blank line detected===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===Issue - Use empty lines between method definitions.===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===Issue - Prefer each over for===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===Issue - Rename is_user_ta? to user_ta?===&lt;br /&gt;
Renamed is_user_ta? to user_ta? to follow naming conventions enforced by Rubocop.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_35.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - show, edit, update, destroy are not explicitly defined on the controller.===&lt;br /&gt;
Show, edit, update and destroy have been explicitly defined to avoid confusion among filters between different controllers.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_32.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Use the new Ruby 1.9 hash syntax===&lt;br /&gt;
This ruby syntax has been deprecated as of the current ruby version(2.3.7) used in expertiza.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_33.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Space missing after colon===&lt;br /&gt;
Space has been added after colon to make the code easily readable.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_30.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Put one space between the method name and the first argument.===&lt;br /&gt;
Space has been added between method name and the first argument to make the code easily readable.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_31.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Do not place comments on the same line as the end keyword.===&lt;br /&gt;
Adding comments at the last the line of the code is considered a bad coding practice according to rubocop standards.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_27.png]]&lt;br /&gt;
&lt;br /&gt;
== '''Testing''' ==&lt;br /&gt;
&lt;br /&gt;
The Expertiza project provides 77 rspec tests under expertiza/spec and 8 of them are related to our controllers files.  After modifying those 28 files, we want to make sure these tests could still pass. We passed all the Rspec tests except for &amp;quot;response_controller&amp;quot;. However, we were not requirement to fix the issues for this controllers.&lt;br /&gt;
&lt;br /&gt;
[[File:Testing pass.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:One_failure_testing.png]]&lt;br /&gt;
&lt;br /&gt;
===Reference===&lt;br /&gt;
*1:http://wiki.expertiza.ncsu.edu/index.php/CSC/ECE_517_Fall_2017/E1784_Fix_mass_assignments_reported_by_Brakeman.rb&lt;br /&gt;
*2: https://github.com/codeclimate/codeclimate/blob/master/README.md&lt;br /&gt;
*The Class GitHub Repository: https://github.com/expertiza/expertiza&lt;br /&gt;
*The Class Code Climate:https://codeclimate.com/github/expertiza/expertiza&lt;/div&gt;</summary>
		<author><name>Nkapadi</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2019_-_Project_E1917._Fix_Code_Climate_issues_in_controllers_with_names_beginning_with_P_through_Z&amp;diff=122430</id>
		<title>CSC/ECE 517 Spring 2019 - Project E1917. Fix Code Climate issues in controllers with names beginning with P through Z</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2019_-_Project_E1917._Fix_Code_Climate_issues_in_controllers_with_names_beginning_with_P_through_Z&amp;diff=122430"/>
		<updated>2019-03-26T01:40:57Z</updated>

		<summary type="html">&lt;p&gt;Nkapadi: /* Implementation */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== '''About Expertiza''' ==&lt;br /&gt;
Expertiza is an open source project based on Ruby on Rails framework. Expertiza allows the instructor to create new assignments and customize new or existing assignments. It also allows the instructor to create a list of topics the students can sign up for. Students can form teams in Expertiza to work on various projects and assignments. Students can also peer review other students' submissions. Expertiza supports submission across various document types, including the URLs and wiki pages[1].&lt;br /&gt;
&lt;br /&gt;
== '''Code Climate Issues and Problem Statements''' ==&lt;br /&gt;
&lt;br /&gt;
Codeclimate is a command line interface for the Code Climate analysis platform [2]. It can detect code smells which violate ruby/rails best practices. The task is to fix certain code climate issues detected by Code Climate analysis platform in controllers with the name beginning with P through Z. These issues includes unsafe use of methods, inappropriate syntax, non-optimal code structure which violates the DRY principle and so on. There are 37 different types of issues fixed in this project.&lt;br /&gt;
&lt;br /&gt;
====List of Issues====&lt;br /&gt;
&lt;br /&gt;
*Unprotected mass assignment&lt;br /&gt;
*Use a guard clause instead of wrapping the code inside a conditional expression&lt;br /&gt;
*Do not use Time.now without zone. Use one of Time.zone.now, Time.current, Time.now.in_time_zone, Time.now.utc, Time.now.getlocal, Time.now.iso8601, Time.now.jisx0301, Time.now.rfc3339, Time.now.to_i, Time.now.to_f instead&lt;br /&gt;
*Move redirect_to &amp;quot;/&amp;quot; out of the conditional.&lt;br /&gt;
*Block has too many lines&lt;br /&gt;
*Useless assignment to variable - initheader.&lt;br /&gt;
*Replace class var @@assignment_id with a class instance var&lt;br /&gt;
*Avoid comparing a variable with multiple items in a conditional, use Array#include? Instead&lt;br /&gt;
*Identical blocks of code found in 2 locations. Consider refactoring. &lt;br /&gt;
*Favor unless over if for negative conditions.&lt;br /&gt;
*Operator = should be surrounded by a single space. &lt;br /&gt;
*Line is too long&lt;br /&gt;
*Extra empty line detected at method body beginning. &lt;br /&gt;
*Unnecessary spacing detected.&lt;br /&gt;
*Parameters should be whitelisted for mass assignment&lt;br /&gt;
*Avoid using update_attribute because it skips validations. &lt;br /&gt;
*end at 44, 4 is not aligned with def at 39, 2. &lt;br /&gt;
*Unsafe reflection method const_get called with parameter value &lt;br /&gt;
*TODO found&lt;br /&gt;
*Convert if nested inside else to elsif&lt;br /&gt;
*Similar blocks of code found in 3 locations. Consider refactoring&lt;br /&gt;
*User controlled method execution&lt;br /&gt;
*Extra blank line detected&lt;br /&gt;
*Use empty lines between method definitions. &lt;br /&gt;
*Prefer each over for&lt;br /&gt;
*Prefer Date or Time over DateTime.&lt;br /&gt;
*Omit parentheses for ternary conditions&lt;br /&gt;
*Do not place comments on the same line as the end keyword. &lt;br /&gt;
*Useless assignment to variable - controllers. Did you mean controller?&lt;br /&gt;
*end at 135, 2 is not aligned with class at 1, 0&lt;br /&gt;
*Put one space between the method name and the first argument. &lt;br /&gt;
*Space missing after colon. &lt;br /&gt;
*Use the new Ruby 1.9 hash syntax&lt;br /&gt;
*show, edit, update, destroy are not explicitly defined on the controller. &lt;br /&gt;
*Rename is_user_ta? to user_ta?&lt;br /&gt;
*Avoid comma after the last item of an array&lt;br /&gt;
*Move redirect_to view_student_teams_path student_id: student.id out of the conditional&lt;br /&gt;
&lt;br /&gt;
== '''Implementation''' ==&lt;br /&gt;
&lt;br /&gt;
There are many minor issues such as unnecessary spacing, extra blank line detected, extra parentheses used and so on. We're not going to show all these minor fixing in this section. The focus would be on some of the important issues listed above that we fixed.&lt;br /&gt;
&lt;br /&gt;
===Issue - Unprotected Mass Assignment===&lt;br /&gt;
Mass assignment is a feature of Rails which allows an application to create a record from the values of a hash. Protection for mass assignment is on by default. Query parameters must be explicitly whitelisted via permit in order to be used in mass assignment.This issue appears in different controller files. An example of how we fixed it in questions_controller.rb is shown below:&lt;br /&gt;
[[File:Unprotected mass assignment 2.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Use a guard clause instead of wrapping the code inside a conditional expression.=== &lt;br /&gt;
Used a return/unless combination to return in case the condition is false.&lt;br /&gt;
&lt;br /&gt;
[[File:Guard clause.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Do not use Time.now without zone. Use one of Time.zone.now, Time.current, Time.now.in_time_zone, Time.now.utc, Time.now.getlocal, Time.now.iso8601, Time.now.jisx0301, Time.now.rfc3339, Time.now.to_i, Time.now.to_f instead.===&lt;br /&gt;
[[File:Time zone and out of condition.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Move redirect_to &amp;quot;/&amp;quot; out of the conditional.===&lt;br /&gt;
&lt;br /&gt;
[[File:Time_zone_and_out_of_condition.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Avoid comparing a variable with multiple items in a conditional, use Array#include? Instead ===&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_5.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Favor unless over if for negative conditions.===&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_10.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Parameters should be whitelisted for mass assignment.===&lt;br /&gt;
[[File:Whitelist_and_update_attributes.png]]&lt;br /&gt;
=== Avoid using update_attribute because it skips validations===&lt;br /&gt;
&lt;br /&gt;
The method update_attribute will skip validation. Should use update_attributes instead.&lt;br /&gt;
&lt;br /&gt;
[[File:Whitelist_and_update_attributes.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Unsafe reflection method const_get called with parameter value===&lt;br /&gt;
[[File:Unsafe const_get.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Avoid comma after the last item of an array===&lt;br /&gt;
[[File:Issue_36.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Line is too long.===&lt;br /&gt;
Code climate will complain when a line is too long.&lt;br /&gt;
&lt;br /&gt;
[[File:Line too long.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Similar blocks of code found in 3 locations. Consider refactoring===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===Issue - User controlled method execution===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===Issue - Extra blank line detected===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===Issue - Use empty lines between method definitions.===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===Issue - Prefer each over for===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===Issue - Rename is_user_ta? to user_ta?===&lt;br /&gt;
Renamed is_user_ta? to user_ta? to follow naming conventions enforced by Rubocop.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_35.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - show, edit, update, destroy are not explicitly defined on the controller.===&lt;br /&gt;
Show, edit, update and destroy have been explicitly defined to avoid confusion among filters between different controllers.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_32.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Use the new Ruby 1.9 hash syntax===&lt;br /&gt;
This ruby syntax has been deprecated as of the current ruby version(2.3.7) used in expertiza.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_33.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Space missing after colon===&lt;br /&gt;
Space has been added after colon to make the code easily readable.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_30.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Put one space between the method name and the first argument.===&lt;br /&gt;
Space has been added between method name and the first argument to make the code easily readable.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_31.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Do not place comments on the same line as the end keyword.===&lt;br /&gt;
Adding comments at the last the line of the code is considered a bad coding practice according to rubocop standards.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_27.png]]&lt;br /&gt;
&lt;br /&gt;
== '''Testing''' ==&lt;br /&gt;
&lt;br /&gt;
The Expertiza project provides 77 rspec tests under expertiza/spec and 8 of them are related to our controllers files.  After modifying those 28 files, we want to make sure these tests could still pass. We passed all the Rspec tests except for &amp;quot;response_controller&amp;quot;. However, we were not requirement to fix the issues for this controllers.&lt;br /&gt;
&lt;br /&gt;
[[File:Testing pass.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:One_failure_testing.png]]&lt;br /&gt;
&lt;br /&gt;
===Reference===&lt;br /&gt;
*1:http://wiki.expertiza.ncsu.edu/index.php/CSC/ECE_517_Fall_2017/E1784_Fix_mass_assignments_reported_by_Brakeman.rb&lt;br /&gt;
*2: https://github.com/codeclimate/codeclimate/blob/master/README.md&lt;br /&gt;
*The Class GitHub Repository: https://github.com/expertiza/expertiza&lt;br /&gt;
*The Class Code Climate:https://codeclimate.com/github/expertiza/expertiza&lt;/div&gt;</summary>
		<author><name>Nkapadi</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=File:Issue_21.png&amp;diff=122429</id>
		<title>File:Issue 21.png</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=File:Issue_21.png&amp;diff=122429"/>
		<updated>2019-03-26T01:39:07Z</updated>

		<summary type="html">&lt;p&gt;Nkapadi: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Nkapadi</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=File:Issue_10.png&amp;diff=122422</id>
		<title>File:Issue 10.png</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=File:Issue_10.png&amp;diff=122422"/>
		<updated>2019-03-26T01:31:55Z</updated>

		<summary type="html">&lt;p&gt;Nkapadi: uploaded a new version of &amp;amp;quot;File:Issue 10.png&amp;amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Nkapadi</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2019_-_Project_E1917._Fix_Code_Climate_issues_in_controllers_with_names_beginning_with_P_through_Z&amp;diff=122421</id>
		<title>CSC/ECE 517 Spring 2019 - Project E1917. Fix Code Climate issues in controllers with names beginning with P through Z</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2019_-_Project_E1917._Fix_Code_Climate_issues_in_controllers_with_names_beginning_with_P_through_Z&amp;diff=122421"/>
		<updated>2019-03-26T01:31:22Z</updated>

		<summary type="html">&lt;p&gt;Nkapadi: /* Issue - Favor unless over if for negative conditions. */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== '''About Expertiza''' ==&lt;br /&gt;
Expertiza is an open source project based on Ruby on Rails framework. Expertiza allows the instructor to create new assignments and customize new or existing assignments. It also allows the instructor to create a list of topics the students can sign up for. Students can form teams in Expertiza to work on various projects and assignments. Students can also peer review other students' submissions. Expertiza supports submission across various document types, including the URLs and wiki pages[1].&lt;br /&gt;
&lt;br /&gt;
== '''Code Climate Issues and Problem Statements''' ==&lt;br /&gt;
&lt;br /&gt;
Codeclimate is a command line interface for the Code Climate analysis platform [2]. It can detect code smells which violate ruby/rails best practices. The task is to fix certain code climate issues detected by Code Climate analysis platform in controllers with the name beginning with P through Z. These issues includes unsafe use of methods, inappropriate syntax, non-optimal code structure which violates the DRY principle and so on. There are 37 different types of issues fixed in this project.&lt;br /&gt;
&lt;br /&gt;
====List of Issues====&lt;br /&gt;
&lt;br /&gt;
*Unprotected mass assignment&lt;br /&gt;
*Use a guard clause instead of wrapping the code inside a conditional expression&lt;br /&gt;
*Do not use Time.now without zone. Use one of Time.zone.now, Time.current, Time.now.in_time_zone, Time.now.utc, Time.now.getlocal, Time.now.iso8601, Time.now.jisx0301, Time.now.rfc3339, Time.now.to_i, Time.now.to_f instead&lt;br /&gt;
*Move redirect_to &amp;quot;/&amp;quot; out of the conditional.&lt;br /&gt;
*Block has too many lines&lt;br /&gt;
*Useless assignment to variable - initheader.&lt;br /&gt;
*Replace class var @@assignment_id with a class instance var&lt;br /&gt;
*Avoid comparing a variable with multiple items in a conditional, use Array#include? Instead&lt;br /&gt;
*Identical blocks of code found in 2 locations. Consider refactoring. &lt;br /&gt;
*Favor unless over if for negative conditions.&lt;br /&gt;
*Operator = should be surrounded by a single space. &lt;br /&gt;
*Line is too long&lt;br /&gt;
*Extra empty line detected at method body beginning. &lt;br /&gt;
*Unnecessary spacing detected.&lt;br /&gt;
*Parameters should be whitelisted for mass assignment&lt;br /&gt;
*Avoid using update_attribute because it skips validations. &lt;br /&gt;
*end at 44, 4 is not aligned with def at 39, 2. &lt;br /&gt;
*Unsafe reflection method const_get called with parameter value &lt;br /&gt;
*TODO found&lt;br /&gt;
*Convert if nested inside else to elsif&lt;br /&gt;
*Similar blocks of code found in 3 locations. Consider refactoring&lt;br /&gt;
*User controlled method execution&lt;br /&gt;
*Extra blank line detected&lt;br /&gt;
*Use empty lines between method definitions. &lt;br /&gt;
*Prefer each over for&lt;br /&gt;
*Prefer Date or Time over DateTime.&lt;br /&gt;
*Omit parentheses for ternary conditions&lt;br /&gt;
*Do not place comments on the same line as the end keyword. &lt;br /&gt;
*Useless assignment to variable - controllers. Did you mean controller?&lt;br /&gt;
*end at 135, 2 is not aligned with class at 1, 0&lt;br /&gt;
*Put one space between the method name and the first argument. &lt;br /&gt;
*Space missing after colon. &lt;br /&gt;
*Use the new Ruby 1.9 hash syntax&lt;br /&gt;
*show, edit, update, destroy are not explicitly defined on the controller. &lt;br /&gt;
*Rename is_user_ta? to user_ta?&lt;br /&gt;
*Avoid comma after the last item of an array&lt;br /&gt;
*Move redirect_to view_student_teams_path student_id: student.id out of the conditional&lt;br /&gt;
&lt;br /&gt;
== '''Implementation''' ==&lt;br /&gt;
&lt;br /&gt;
There are many minor issues such as unnecessary spacing, extra blank line detected, extra parentheses used and so on. We're not going to show all these minor fixing in this section. The focus would be on some of the important issues listed above that we fixed.&lt;br /&gt;
&lt;br /&gt;
===Issue - Unprotected Mass Assignment===&lt;br /&gt;
Mass assignment is a feature of Rails which allows an application to create a record from the values of a hash. Protection for mass assignment is on by default. Query parameters must be explicitly whitelisted via permit in order to be used in mass assignment.This issue appears in different controller files. An example of how we fixed it in questions_controller.rb is shown below:&lt;br /&gt;
[[File:Unprotected mass assignment 2.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Use a guard clause instead of wrapping the code inside a conditional expression.=== &lt;br /&gt;
Used a return/unless combination to return in case the condition is false.&lt;br /&gt;
&lt;br /&gt;
[[File:Guard clause.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Do not use Time.now without zone. Use one of Time.zone.now, Time.current, Time.now.in_time_zone, Time.now.utc, Time.now.getlocal, Time.now.iso8601, Time.now.jisx0301, Time.now.rfc3339, Time.now.to_i, Time.now.to_f instead.===&lt;br /&gt;
[[File:Time zone and out of condition.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Move redirect_to &amp;quot;/&amp;quot; out of the conditional.===&lt;br /&gt;
&lt;br /&gt;
[[File:Time_zone_and_out_of_condition.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Avoid comparing a variable with multiple items in a conditional, use Array#include? Instead ===&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_5.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Favor unless over if for negative conditions.===&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_10.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Parameters should be whitelisted for mass assignment / Avoid using update_attribute because it skips validations===&lt;br /&gt;
[[File:Whitelist_and_update_attributes.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Unsafe reflection method const_get called with parameter value===&lt;br /&gt;
[[File:Unsafe const_get.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Avoid comma after the last item of an array===&lt;br /&gt;
[[File:Issue_36.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Line is too long.===&lt;br /&gt;
[[File:Line too long.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Rename is_user_ta? to user_ta?===&lt;br /&gt;
Renamed is_user_ta? to user_ta? to follow naming conventions enforced by Rubocop.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_35.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - show, edit, update, destroy are not explicitly defined on the controller.===&lt;br /&gt;
Show, edit, update and destroy have been explicitly defined to avoid confusion among filters between different controllers.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_32.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Use the new Ruby 1.9 hash syntax===&lt;br /&gt;
This ruby syntax has been deprecated as of the current ruby version(2.3.7) used in expertiza.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_33.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Space missing after colon===&lt;br /&gt;
Space has been added after colon to make the code easily readable.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_30.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Put one space between the method name and the first argument.===&lt;br /&gt;
Space has been added between method name and the first argument to make the code easily readable.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_31.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Do not place comments on the same line as the end keyword.===&lt;br /&gt;
Adding comments at the last the line of the code is considered a bad coding practice according to rubocop standards.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_27.png]]&lt;br /&gt;
&lt;br /&gt;
== '''Testing''' ==&lt;br /&gt;
&lt;br /&gt;
The Expertiza project provides 77 rspec tests under expertiza/spec and 8 of them are related to our controllers files.  After modifying those 28 files, we want to make sure these tests could still pass. We passed all the Rspec tests except for &amp;quot;response_controller&amp;quot;. However, we were not requirement to fix the issues for this controllers.&lt;br /&gt;
&lt;br /&gt;
[[File:Testing pass.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:One_failure_testing.png]]&lt;br /&gt;
&lt;br /&gt;
===Reference===&lt;br /&gt;
*1:http://wiki.expertiza.ncsu.edu/index.php/CSC/ECE_517_Fall_2017/E1784_Fix_mass_assignments_reported_by_Brakeman.rb&lt;br /&gt;
*2: https://github.com/codeclimate/codeclimate/blob/master/README.md&lt;br /&gt;
*The Class GitHub Repository: https://github.com/expertiza/expertiza&lt;br /&gt;
*The Class Code Climate:https://codeclimate.com/github/expertiza/expertiza&lt;/div&gt;</summary>
		<author><name>Nkapadi</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=File:Issue_10.png&amp;diff=122420</id>
		<title>File:Issue 10.png</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=File:Issue_10.png&amp;diff=122420"/>
		<updated>2019-03-26T01:30:59Z</updated>

		<summary type="html">&lt;p&gt;Nkapadi: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Nkapadi</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2019_-_Project_E1917._Fix_Code_Climate_issues_in_controllers_with_names_beginning_with_P_through_Z&amp;diff=122417</id>
		<title>CSC/ECE 517 Spring 2019 - Project E1917. Fix Code Climate issues in controllers with names beginning with P through Z</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2019_-_Project_E1917._Fix_Code_Climate_issues_in_controllers_with_names_beginning_with_P_through_Z&amp;diff=122417"/>
		<updated>2019-03-26T01:27:37Z</updated>

		<summary type="html">&lt;p&gt;Nkapadi: /* Issue - Avoid comparing a variable with multiple items in a conditional, use Array#include? Instead */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== '''About Expertiza''' ==&lt;br /&gt;
Expertiza is an open source project based on Ruby on Rails framework. Expertiza allows the instructor to create new assignments and customize new or existing assignments. It also allows the instructor to create a list of topics the students can sign up for. Students can form teams in Expertiza to work on various projects and assignments. Students can also peer review other students' submissions. Expertiza supports submission across various document types, including the URLs and wiki pages[1].&lt;br /&gt;
&lt;br /&gt;
== '''Code Climate Issues and Problem Statements''' ==&lt;br /&gt;
&lt;br /&gt;
Codeclimate is a command line interface for the Code Climate analysis platform [2]. It can detect code smells which violate ruby/rails best practices. The task is to fix certain code climate issues detected by Code Climate analysis platform in controllers with the name beginning with P through Z. These issues includes unsafe use of methods, inappropriate syntax, non-optimal code structure which violates the DRY principle and so on. There are 37 different types of issues fixed in this project.&lt;br /&gt;
&lt;br /&gt;
====List of Issues====&lt;br /&gt;
&lt;br /&gt;
*Unprotected mass assignment&lt;br /&gt;
*Use a guard clause instead of wrapping the code inside a conditional expression&lt;br /&gt;
*Do not use Time.now without zone. Use one of Time.zone.now, Time.current, Time.now.in_time_zone, Time.now.utc, Time.now.getlocal, Time.now.iso8601, Time.now.jisx0301, Time.now.rfc3339, Time.now.to_i, Time.now.to_f instead&lt;br /&gt;
*Move redirect_to &amp;quot;/&amp;quot; out of the conditional.&lt;br /&gt;
*Block has too many lines&lt;br /&gt;
*Useless assignment to variable - initheader.&lt;br /&gt;
*Replace class var @@assignment_id with a class instance var&lt;br /&gt;
*Avoid comparing a variable with multiple items in a conditional, use Array#include? Instead&lt;br /&gt;
*Identical blocks of code found in 2 locations. Consider refactoring. &lt;br /&gt;
*Favor unless over if for negative conditions.&lt;br /&gt;
*Operator = should be surrounded by a single space. &lt;br /&gt;
*Line is too long&lt;br /&gt;
*Extra empty line detected at method body beginning. &lt;br /&gt;
*Unnecessary spacing detected.&lt;br /&gt;
*Parameters should be whitelisted for mass assignment&lt;br /&gt;
*Avoid using update_attribute because it skips validations. &lt;br /&gt;
*end at 44, 4 is not aligned with def at 39, 2. &lt;br /&gt;
*Unsafe reflection method const_get called with parameter value &lt;br /&gt;
*TODO found&lt;br /&gt;
*Convert if nested inside else to elsif&lt;br /&gt;
*Similar blocks of code found in 3 locations. Consider refactoring&lt;br /&gt;
*User controlled method execution&lt;br /&gt;
*Extra blank line detected&lt;br /&gt;
*Use empty lines between method definitions. &lt;br /&gt;
*Prefer each over for&lt;br /&gt;
*Prefer Date or Time over DateTime.&lt;br /&gt;
*Omit parentheses for ternary conditions&lt;br /&gt;
*Do not place comments on the same line as the end keyword. &lt;br /&gt;
*Useless assignment to variable - controllers. Did you mean controller?&lt;br /&gt;
*end at 135, 2 is not aligned with class at 1, 0&lt;br /&gt;
*Put one space between the method name and the first argument. &lt;br /&gt;
*Space missing after colon. &lt;br /&gt;
*Use the new Ruby 1.9 hash syntax&lt;br /&gt;
*show, edit, update, destroy are not explicitly defined on the controller. &lt;br /&gt;
*Rename is_user_ta? to user_ta?&lt;br /&gt;
*Avoid comma after the last item of an array&lt;br /&gt;
*Move redirect_to view_student_teams_path student_id: student.id out of the conditional&lt;br /&gt;
&lt;br /&gt;
== '''Implementation''' ==&lt;br /&gt;
&lt;br /&gt;
There are many minor issues such as unnecessary spacing, extra blank line detected, extra parentheses used and so on. We're not going to show all these minor fixing in this section. The focus would be on some of the important issues listed above that we fixed.&lt;br /&gt;
&lt;br /&gt;
===Issue - Unprotected Mass Assignment===&lt;br /&gt;
Mass assignment is a feature of Rails which allows an application to create a record from the values of a hash. Protection for mass assignment is on by default. Query parameters must be explicitly whitelisted via permit in order to be used in mass assignment.This issue appears in different controller files. An example of how we fixed it in questions_controller.rb is shown below:&lt;br /&gt;
[[File:Unprotected mass assignment 2.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Use a guard clause instead of wrapping the code inside a conditional expression.=== &lt;br /&gt;
Used a return/unless combination to return in case the condition is false.&lt;br /&gt;
&lt;br /&gt;
[[File:Guard clause.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Do not use Time.now without zone. Use one of Time.zone.now, Time.current, Time.now.in_time_zone, Time.now.utc, Time.now.getlocal, Time.now.iso8601, Time.now.jisx0301, Time.now.rfc3339, Time.now.to_i, Time.now.to_f instead.===&lt;br /&gt;
[[File:Time zone and out of condition.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Move redirect_to &amp;quot;/&amp;quot; out of the conditional.===&lt;br /&gt;
&lt;br /&gt;
[[File:Time_zone_and_out_of_condition.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Avoid comparing a variable with multiple items in a conditional, use Array#include? Instead ===&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_5.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Favor unless over if for negative conditions.===&lt;br /&gt;
&lt;br /&gt;
===Issue - Parameters should be whitelisted for mass assignment / Avoid using update_attribute because it skips validations===&lt;br /&gt;
[[File:Whitelist_and_update_attributes.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Unsafe reflection method const_get called with parameter value===&lt;br /&gt;
[[File:Unsafe const_get.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Avoid comma after the last item of an array===&lt;br /&gt;
[[File:Issue_36.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Line is too long.===&lt;br /&gt;
[[File:Line too long.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Rename is_user_ta? to user_ta?===&lt;br /&gt;
Renamed is_user_ta? to user_ta? to follow naming conventions enforced by Rubocop.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_35.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - show, edit, update, destroy are not explicitly defined on the controller.===&lt;br /&gt;
Show, edit, update and destroy have been explicitly defined to avoid confusion among filters between different controllers.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_32.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Use the new Ruby 1.9 hash syntax===&lt;br /&gt;
This ruby syntax has been deprecated as of the current ruby version(2.3.7) used in expertiza.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_33.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Space missing after colon===&lt;br /&gt;
Space has been added after colon to make the code easily readable.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_30.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Put one space between the method name and the first argument.===&lt;br /&gt;
Space has been added between method name and the first argument to make the code easily readable.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_31.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Do not place comments on the same line as the end keyword.===&lt;br /&gt;
Adding comments at the last the line of the code is considered a bad coding practice according to rubocop standards.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_27.png]]&lt;br /&gt;
&lt;br /&gt;
== '''Testing''' ==&lt;br /&gt;
&lt;br /&gt;
The Expertiza project provides 77 rspec tests under expertiza/spec and 8 of them are related to our controllers files.  After modifying those 28 files, we want to make sure these tests could still pass. We passed all the Rspec tests except for &amp;quot;response_controller&amp;quot;. However, we were not requirement to fix the issues for this controllers.&lt;br /&gt;
&lt;br /&gt;
[[File:Testing pass.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:One_failure_testing.png]]&lt;br /&gt;
&lt;br /&gt;
===Reference===&lt;br /&gt;
*1:http://wiki.expertiza.ncsu.edu/index.php/CSC/ECE_517_Fall_2017/E1784_Fix_mass_assignments_reported_by_Brakeman.rb&lt;br /&gt;
*2: https://github.com/codeclimate/codeclimate/blob/master/README.md&lt;br /&gt;
*The Class GitHub Repository: https://github.com/expertiza/expertiza&lt;br /&gt;
*The Class Code Climate:https://codeclimate.com/github/expertiza/expertiza&lt;/div&gt;</summary>
		<author><name>Nkapadi</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=File:Issue_5.png&amp;diff=122416</id>
		<title>File:Issue 5.png</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=File:Issue_5.png&amp;diff=122416"/>
		<updated>2019-03-26T01:27:17Z</updated>

		<summary type="html">&lt;p&gt;Nkapadi: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Nkapadi</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2019_-_Project_E1917._Fix_Code_Climate_issues_in_controllers_with_names_beginning_with_P_through_Z&amp;diff=122411</id>
		<title>CSC/ECE 517 Spring 2019 - Project E1917. Fix Code Climate issues in controllers with names beginning with P through Z</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2019_-_Project_E1917._Fix_Code_Climate_issues_in_controllers_with_names_beginning_with_P_through_Z&amp;diff=122411"/>
		<updated>2019-03-26T01:23:01Z</updated>

		<summary type="html">&lt;p&gt;Nkapadi: /* Issue - Do not use Time.now without zone. Use one of Time.zone.now, Time.current, Time.now.in_time_zone, Time.now.utc, Time.now.getlocal, Time.now.iso8601, Time.now.jisx0301, Time.now.rfc3339, Time.now.to_i, Time.now.to_f instead. */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== '''About Expertiza''' ==&lt;br /&gt;
Expertiza is an open source project based on Ruby on Rails framework. Expertiza allows the instructor to create new assignments and customize new or existing assignments. It also allows the instructor to create a list of topics the students can sign up for. Students can form teams in Expertiza to work on various projects and assignments. Students can also peer review other students' submissions. Expertiza supports submission across various document types, including the URLs and wiki pages[1].&lt;br /&gt;
&lt;br /&gt;
== '''Code Climate Issues and Problem Statements''' ==&lt;br /&gt;
&lt;br /&gt;
Codeclimate is a command line interface for the Code Climate analysis platform [2]. It can detect code smells which violate ruby/rails best practices. The task is to fix certain code climate issues detected by Code Climate analysis platform in controllers with the name beginning with P through Z. These issues includes unsafe use of methods, inappropriate syntax, non-optimal code structure which violates the DRY principle and so on. There are 37 different types of issues fixed in this project.&lt;br /&gt;
&lt;br /&gt;
====List of Issues====&lt;br /&gt;
&lt;br /&gt;
*Unprotected mass assignment&lt;br /&gt;
*Use a guard clause instead of wrapping the code inside a conditional expression&lt;br /&gt;
*Do not use Time.now without zone. Use one of Time.zone.now, Time.current, Time.now.in_time_zone, Time.now.utc, Time.now.getlocal, Time.now.iso8601, Time.now.jisx0301, Time.now.rfc3339, Time.now.to_i, Time.now.to_f instead&lt;br /&gt;
*Move redirect_to &amp;quot;/&amp;quot; out of the conditional.&lt;br /&gt;
*Block has too many lines&lt;br /&gt;
*Useless assignment to variable - initheader.&lt;br /&gt;
*Replace class var @@assignment_id with a class instance var&lt;br /&gt;
*Avoid comparing a variable with multiple items in a conditional, use Array#include? Instead&lt;br /&gt;
*Identical blocks of code found in 2 locations. Consider refactoring. &lt;br /&gt;
*Favor unless over if for negative conditions.&lt;br /&gt;
*Operator = should be surrounded by a single space. &lt;br /&gt;
*Line is too long&lt;br /&gt;
*Extra empty line detected at method body beginning. &lt;br /&gt;
*Unnecessary spacing detected.&lt;br /&gt;
*Parameters should be whitelisted for mass assignment&lt;br /&gt;
*Avoid using update_attribute because it skips validations. &lt;br /&gt;
*end at 44, 4 is not aligned with def at 39, 2. &lt;br /&gt;
*Unsafe reflection method const_get called with parameter value &lt;br /&gt;
*TODO found&lt;br /&gt;
*Convert if nested inside else to elsif&lt;br /&gt;
*Similar blocks of code found in 3 locations. Consider refactoring&lt;br /&gt;
*User controlled method execution&lt;br /&gt;
*Extra blank line detected&lt;br /&gt;
*Use empty lines between method definitions. &lt;br /&gt;
*Prefer each over for&lt;br /&gt;
*Prefer Date or Time over DateTime.&lt;br /&gt;
*Omit parentheses for ternary conditions&lt;br /&gt;
*Do not place comments on the same line as the end keyword. &lt;br /&gt;
*Useless assignment to variable - controllers. Did you mean controller?&lt;br /&gt;
*end at 135, 2 is not aligned with class at 1, 0&lt;br /&gt;
*Put one space between the method name and the first argument. &lt;br /&gt;
*Space missing after colon. &lt;br /&gt;
*Use the new Ruby 1.9 hash syntax&lt;br /&gt;
*show, edit, update, destroy are not explicitly defined on the controller. &lt;br /&gt;
*Rename is_user_ta? to user_ta?&lt;br /&gt;
*Avoid comma after the last item of an array&lt;br /&gt;
*Move redirect_to view_student_teams_path student_id: student.id out of the conditional&lt;br /&gt;
&lt;br /&gt;
== '''Implementation''' ==&lt;br /&gt;
&lt;br /&gt;
There are many minor issues such as unnecessary spacing, extra blank line detected, extra parentheses used and so on. We're not going to show all these minor fixing in this section. The focus would be on some of the important issues listed above that we fixed.&lt;br /&gt;
&lt;br /&gt;
===Issue - Unprotected Mass Assignment===&lt;br /&gt;
Mass assignment is a feature of Rails which allows an application to create a record from the values of a hash. Protection for mass assignment is on by default. Query parameters must be explicitly whitelisted via permit in order to be used in mass assignment.This issue appears in different controller files. An example of how we fixed it in questions_controller.rb is shown below:&lt;br /&gt;
[[File:Unprotected mass assignment 2.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Use a guard clause instead of wrapping the code inside a conditional expression.=== &lt;br /&gt;
Used a return/unless combination to return in case the condition is false.&lt;br /&gt;
&lt;br /&gt;
[[File:Guard clause.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Do not use Time.now without zone. Use one of Time.zone.now, Time.current, Time.now.in_time_zone, Time.now.utc, Time.now.getlocal, Time.now.iso8601, Time.now.jisx0301, Time.now.rfc3339, Time.now.to_i, Time.now.to_f instead.===&lt;br /&gt;
[[File:Time zone and out of condition.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Move redirect_to &amp;quot;/&amp;quot; out of the conditional.===&lt;br /&gt;
&lt;br /&gt;
[[File:Time_zone_and_out_of_condition.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Avoid comparing a variable with multiple items in a conditional, use Array#include? Instead ===&lt;br /&gt;
&lt;br /&gt;
===Issue - Favor unless over if for negative conditions.===&lt;br /&gt;
&lt;br /&gt;
===Issue - Parameters should be whitelisted for mass assignment / Avoid using update_attribute because it skips validations===&lt;br /&gt;
[[File:Whitelist_and_update_attributes.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Unsafe reflection method const_get called with parameter value===&lt;br /&gt;
[[File:Unsafe const_get.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Avoid comma after the last item of an array===&lt;br /&gt;
[[File:Issue_36.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Rename is_user_ta? to user_ta?===&lt;br /&gt;
Renamed is_user_ta? to user_ta? to follow naming conventions enforced by Rubocop.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_35.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - show, edit, update, destroy are not explicitly defined on the controller.===&lt;br /&gt;
Show, edit, update and destroy have been explicitly defined to avoid confusion among filters between different controllers.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_32.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Use the new Ruby 1.9 hash syntax===&lt;br /&gt;
This ruby syntax has been deprecated as of the current ruby version(2.3.7) used in expertiza.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_33.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Space missing after colon===&lt;br /&gt;
Space has been added after colon to make the code easily readable.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_30.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Put one space between the method name and the first argument.===&lt;br /&gt;
Space has been added between method name and the first argument to make the code easily readable.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_31.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Do not place comments on the same line as the end keyword.===&lt;br /&gt;
Adding comments at the last the line of the code is considered a bad coding practice according to rubocop standards.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_27.png]]&lt;br /&gt;
&lt;br /&gt;
== '''Testing''' ==&lt;br /&gt;
&lt;br /&gt;
The Expertiza project provides 77 rspec tests under expertiza/spec and 8 of them are related to our controllers files.  After modifying those 28 files, we want to make sure these tests could still pass. We passed all the Rspec tests except for &amp;quot;response_controller&amp;quot;. However, we were not requirement to fix the issues for this controllers.&lt;br /&gt;
&lt;br /&gt;
[[File:Testing pass.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:One_failure_testing.png]]&lt;br /&gt;
&lt;br /&gt;
===Reference===&lt;br /&gt;
*1:http://wiki.expertiza.ncsu.edu/index.php/CSC/ECE_517_Fall_2017/E1784_Fix_mass_assignments_reported_by_Brakeman.rb&lt;br /&gt;
*2: https://github.com/codeclimate/codeclimate/blob/master/README.md&lt;br /&gt;
*The Class GitHub Repository: https://github.com/expertiza/expertiza&lt;br /&gt;
*The Class Code Climate:https://codeclimate.com/github/expertiza/expertiza&lt;/div&gt;</summary>
		<author><name>Nkapadi</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2019_-_Project_E1917._Fix_Code_Climate_issues_in_controllers_with_names_beginning_with_P_through_Z&amp;diff=122409</id>
		<title>CSC/ECE 517 Spring 2019 - Project E1917. Fix Code Climate issues in controllers with names beginning with P through Z</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2019_-_Project_E1917._Fix_Code_Climate_issues_in_controllers_with_names_beginning_with_P_through_Z&amp;diff=122409"/>
		<updated>2019-03-26T01:19:26Z</updated>

		<summary type="html">&lt;p&gt;Nkapadi: /* Issue - Use a guard clause instead of wrapping the code inside a conditional expression. */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== '''About Expertiza''' ==&lt;br /&gt;
Expertiza is an open source project based on Ruby on Rails framework. Expertiza allows the instructor to create new assignments and customize new or existing assignments. It also allows the instructor to create a list of topics the students can sign up for. Students can form teams in Expertiza to work on various projects and assignments. Students can also peer review other students' submissions. Expertiza supports submission across various document types, including the URLs and wiki pages[1].&lt;br /&gt;
&lt;br /&gt;
== '''Code Climate Issues and Problem Statements''' ==&lt;br /&gt;
&lt;br /&gt;
Codeclimate is a command line interface for the Code Climate analysis platform [2]. It can detect code smells which violate ruby/rails best practices. The task is to fix certain code climate issues detected by Code Climate analysis platform in controllers with the name beginning with P through Z. These issues includes unsafe use of methods, inappropriate syntax, non-optimal code structure which violates the DRY principle and so on. There are 37 different types of issues fixed in this project.&lt;br /&gt;
&lt;br /&gt;
====List of Issues====&lt;br /&gt;
&lt;br /&gt;
*Unprotected mass assignment&lt;br /&gt;
*Use a guard clause instead of wrapping the code inside a conditional expression&lt;br /&gt;
*Do not use Time.now without zone. Use one of Time.zone.now, Time.current, Time.now.in_time_zone, Time.now.utc, Time.now.getlocal, Time.now.iso8601, Time.now.jisx0301, Time.now.rfc3339, Time.now.to_i, Time.now.to_f instead&lt;br /&gt;
*Move redirect_to &amp;quot;/&amp;quot; out of the conditional.&lt;br /&gt;
*Block has too many lines&lt;br /&gt;
*Useless assignment to variable - initheader.&lt;br /&gt;
*Replace class var @@assignment_id with a class instance var&lt;br /&gt;
*Avoid comparing a variable with multiple items in a conditional, use Array#include? Instead&lt;br /&gt;
*Identical blocks of code found in 2 locations. Consider refactoring. &lt;br /&gt;
*Favor unless over if for negative conditions.&lt;br /&gt;
*Operator = should be surrounded by a single space. &lt;br /&gt;
*Line is too long&lt;br /&gt;
*Extra empty line detected at method body beginning. &lt;br /&gt;
*Unnecessary spacing detected.&lt;br /&gt;
*Parameters should be whitelisted for mass assignment&lt;br /&gt;
*Avoid using update_attribute because it skips validations. &lt;br /&gt;
*end at 44, 4 is not aligned with def at 39, 2. &lt;br /&gt;
*Unsafe reflection method const_get called with parameter value &lt;br /&gt;
*TODO found&lt;br /&gt;
*Convert if nested inside else to elsif&lt;br /&gt;
*Similar blocks of code found in 3 locations. Consider refactoring&lt;br /&gt;
*User controlled method execution&lt;br /&gt;
*Extra blank line detected&lt;br /&gt;
*Use empty lines between method definitions. &lt;br /&gt;
*Prefer each over for&lt;br /&gt;
*Prefer Date or Time over DateTime.&lt;br /&gt;
*Omit parentheses for ternary conditions&lt;br /&gt;
*Do not place comments on the same line as the end keyword. &lt;br /&gt;
*Useless assignment to variable - controllers. Did you mean controller?&lt;br /&gt;
*end at 135, 2 is not aligned with class at 1, 0&lt;br /&gt;
*Put one space between the method name and the first argument. &lt;br /&gt;
*Space missing after colon. &lt;br /&gt;
*Use the new Ruby 1.9 hash syntax&lt;br /&gt;
*show, edit, update, destroy are not explicitly defined on the controller. &lt;br /&gt;
*Rename is_user_ta? to user_ta?&lt;br /&gt;
*Avoid comma after the last item of an array&lt;br /&gt;
*Move redirect_to view_student_teams_path student_id: student.id out of the conditional&lt;br /&gt;
&lt;br /&gt;
== '''Implementation''' ==&lt;br /&gt;
&lt;br /&gt;
There are many minor issues such as unnecessary spacing, extra blank line detected, extra parentheses used and so on. We're not going to show all these minor fixing in this section. The focus would be on some of the important issues listed above that we fixed.&lt;br /&gt;
&lt;br /&gt;
===Issue - Unprotected Mass Assignment===&lt;br /&gt;
Mass assignment is a feature of Rails which allows an application to create a record from the values of a hash. Protection for mass assignment is on by default. Query parameters must be explicitly whitelisted via permit in order to be used in mass assignment.This issue appears in different controller files. An example of how we fixed it in questions_controller.rb is shown below:&lt;br /&gt;
[[File:Unprotected mass assignment 2.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Use a guard clause instead of wrapping the code inside a conditional expression.=== &lt;br /&gt;
Used a return/unless combination to return in case the condition is false.&lt;br /&gt;
&lt;br /&gt;
[[File:Guard clause.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Do not use Time.now without zone. Use one of Time.zone.now, Time.current, Time.now.in_time_zone, Time.now.utc, Time.now.getlocal, Time.now.iso8601, Time.now.jisx0301, Time.now.rfc3339, Time.now.to_i, Time.now.to_f instead.===&lt;br /&gt;
&lt;br /&gt;
===Issue - Move redirect_to &amp;quot;/&amp;quot; out of the conditional.===&lt;br /&gt;
&lt;br /&gt;
[[File:Time_zone_and_out_of_condition.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Avoid comparing a variable with multiple items in a conditional, use Array#include? Instead ===&lt;br /&gt;
&lt;br /&gt;
===Issue - Favor unless over if for negative conditions.===&lt;br /&gt;
&lt;br /&gt;
===Issue - Parameters should be whitelisted for mass assignment.===&lt;br /&gt;
===Issue - Avoid using update_attribute because it skips validations.===&lt;br /&gt;
[[File:Whitelist_and_update_attributes.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Unsafe reflection method const_get called with parameter value===&lt;br /&gt;
[[File:Unsafe const_get.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Avoid comma after the last item of an array===&lt;br /&gt;
[[File:Issue_36.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Rename is_user_ta? to user_ta?===&lt;br /&gt;
Renamed is_user_ta? to user_ta? to follow naming conventions enforced by Rubocop.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_35.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - show, edit, update, destroy are not explicitly defined on the controller.===&lt;br /&gt;
Show, edit, update and destroy have been explicitly defined to avoid confusion among filters between different controllers.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_32.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Use the new Ruby 1.9 hash syntax===&lt;br /&gt;
This ruby syntax has been deprecated as of the current ruby version(2.3.7) used in expertiza.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_33.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Space missing after colon===&lt;br /&gt;
Space has been added after colon to make the code easily readable.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_30.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Put one space between the method name and the first argument.===&lt;br /&gt;
Space has been added between method name and the first argument to make the code easily readable.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_31.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Do not place comments on the same line as the end keyword.===&lt;br /&gt;
Adding comments at the last the line of the code is considered a bad coding practice according to rubocop standards.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_27.png]]&lt;br /&gt;
&lt;br /&gt;
== '''Testing''' ==&lt;br /&gt;
&lt;br /&gt;
The Expertiza project provides 77 rspec tests under expertiza/spec and 8 of them are related to our controllers files.  After modifying those 28 files, we want to make sure these tests could still pass. We passed all the Rspec tests except for &amp;quot;response_controller&amp;quot;. However, we were not requirement to fix the issues for this controllers.&lt;br /&gt;
&lt;br /&gt;
[[File:Testing pass.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:One_failure_testing.png]]&lt;br /&gt;
&lt;br /&gt;
===Reference===&lt;br /&gt;
*1:http://wiki.expertiza.ncsu.edu/index.php/CSC/ECE_517_Fall_2017/E1784_Fix_mass_assignments_reported_by_Brakeman.rb&lt;br /&gt;
*2: https://github.com/codeclimate/codeclimate/blob/master/README.md&lt;br /&gt;
*The Class GitHub Repository: https://github.com/expertiza/expertiza&lt;br /&gt;
*The Class Code Climate:https://codeclimate.com/github/expertiza/expertiza&lt;/div&gt;</summary>
		<author><name>Nkapadi</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2019_-_Project_E1917._Fix_Code_Climate_issues_in_controllers_with_names_beginning_with_P_through_Z&amp;diff=122403</id>
		<title>CSC/ECE 517 Spring 2019 - Project E1917. Fix Code Climate issues in controllers with names beginning with P through Z</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2019_-_Project_E1917._Fix_Code_Climate_issues_in_controllers_with_names_beginning_with_P_through_Z&amp;diff=122403"/>
		<updated>2019-03-26T01:11:34Z</updated>

		<summary type="html">&lt;p&gt;Nkapadi: /* Issue - Unprotected Mass Assignment */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== '''About Expertiza''' ==&lt;br /&gt;
Expertiza is an open source project based on Ruby on Rails framework. Expertiza allows the instructor to create new assignments and customize new or existing assignments. It also allows the instructor to create a list of topics the students can sign up for. Students can form teams in Expertiza to work on various projects and assignments. Students can also peer review other students' submissions. Expertiza supports submission across various document types, including the URLs and wiki pages[1].&lt;br /&gt;
&lt;br /&gt;
== '''Code Climate Issues and Problem Statements''' ==&lt;br /&gt;
&lt;br /&gt;
Codeclimate is a command line interface for the Code Climate analysis platform [2]. It can detect code smells which violate ruby/rails best practices. The task is to fix certain code climate issues detected by Code Climate analysis platform in controllers with the name beginning with P through Z. These issues includes unsafe use of methods, inappropriate syntax, non-optimal code structure which violates the DRY principle and so on. There are 37 different types of issues fixed in this project.&lt;br /&gt;
&lt;br /&gt;
====List of Issues====&lt;br /&gt;
&lt;br /&gt;
*Unprotected mass assignment&lt;br /&gt;
*Use a guard clause instead of wrapping the code inside a conditional expression&lt;br /&gt;
*Do not use Time.now without zone. Use one of Time.zone.now, Time.current, Time.now.in_time_zone, Time.now.utc, Time.now.getlocal, Time.now.iso8601, Time.now.jisx0301, Time.now.rfc3339, Time.now.to_i, Time.now.to_f instead&lt;br /&gt;
*Move redirect_to &amp;quot;/&amp;quot; out of the conditional.&lt;br /&gt;
*Block has too many lines&lt;br /&gt;
*Useless assignment to variable - initheader.&lt;br /&gt;
*Replace class var @@assignment_id with a class instance var&lt;br /&gt;
*Avoid comparing a variable with multiple items in a conditional, use Array#include? Instead&lt;br /&gt;
*Identical blocks of code found in 2 locations. Consider refactoring. &lt;br /&gt;
*Favor unless over if for negative conditions.&lt;br /&gt;
*Operator = should be surrounded by a single space. &lt;br /&gt;
*Line is too long&lt;br /&gt;
*Extra empty line detected at method body beginning. &lt;br /&gt;
*Unnecessary spacing detected.&lt;br /&gt;
*Parameters should be whitelisted for mass assignment&lt;br /&gt;
*Avoid using update_attribute because it skips validations. &lt;br /&gt;
*end at 44, 4 is not aligned with def at 39, 2. &lt;br /&gt;
*Unsafe reflection method const_get called with parameter value &lt;br /&gt;
*TODO found&lt;br /&gt;
*Convert if nested inside else to elsif&lt;br /&gt;
*Similar blocks of code found in 3 locations. Consider refactoring&lt;br /&gt;
*User controlled method execution&lt;br /&gt;
*Extra blank line detected&lt;br /&gt;
*Use empty lines between method definitions. &lt;br /&gt;
*Prefer each over for&lt;br /&gt;
*Prefer Date or Time over DateTime.&lt;br /&gt;
*Omit parentheses for ternary conditions&lt;br /&gt;
*Do not place comments on the same line as the end keyword. &lt;br /&gt;
*Useless assignment to variable - controllers. Did you mean controller?&lt;br /&gt;
*end at 135, 2 is not aligned with class at 1, 0&lt;br /&gt;
*Put one space between the method name and the first argument. &lt;br /&gt;
*Space missing after colon. &lt;br /&gt;
*Use the new Ruby 1.9 hash syntax&lt;br /&gt;
*show, edit, update, destroy are not explicitly defined on the controller. &lt;br /&gt;
*Rename is_user_ta? to user_ta?&lt;br /&gt;
*Avoid comma after the last item of an array&lt;br /&gt;
*Move redirect_to view_student_teams_path student_id: student.id out of the conditional&lt;br /&gt;
&lt;br /&gt;
== '''Implementation''' ==&lt;br /&gt;
&lt;br /&gt;
There are many minor issues such as unnecessary spacing, extra blank line detected, extra parentheses used and so on. We're not going to show all these minor fixing in this section. The focus would be on some of the important issues listed above that we fixed.&lt;br /&gt;
&lt;br /&gt;
===Issue - Unprotected Mass Assignment===&lt;br /&gt;
Mass assignment is a feature of Rails which allows an application to create a record from the values of a hash. Protection for mass assignment is on by default. Query parameters must be explicitly whitelisted via permit in order to be used in mass assignment.This issue appears in different controller files. An example of how we fixed it in questions_controller.rb is shown below:&lt;br /&gt;
[[File:Unprotected mass assignment 2.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Use a guard clause instead of wrapping the code inside a conditional expression.=== &lt;br /&gt;
[[File:Guard clause.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Do not use Time.now without zone. Use one of Time.zone.now, Time.current, Time.now.in_time_zone, Time.now.utc, Time.now.getlocal, Time.now.iso8601, Time.now.jisx0301, Time.now.rfc3339, Time.now.to_i, Time.now.to_f instead.===&lt;br /&gt;
&lt;br /&gt;
===Issue - Move redirect_to &amp;quot;/&amp;quot; out of the conditional.===&lt;br /&gt;
&lt;br /&gt;
[[File:Time_zone_and_out_of_condition.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Avoid comparing a variable with multiple items in a conditional, use Array#include? Instead ===&lt;br /&gt;
&lt;br /&gt;
===Issue - Favor unless over if for negative conditions.===&lt;br /&gt;
&lt;br /&gt;
===Issue - Parameters should be whitelisted for mass assignment.===&lt;br /&gt;
[[File:Whitelist_and_update_attributes.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Unsafe reflection method const_get called with parameter value===&lt;br /&gt;
[[File:Unsafe const_get.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Avoid comma after the last item of an array===&lt;br /&gt;
[[File:Issue_36.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Rename is_user_ta? to user_ta?===&lt;br /&gt;
Renamed is_user_ta? to user_ta? to follow naming conventions enforced by Rubocop.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_35.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - show, edit, update, destroy are not explicitly defined on the controller.===&lt;br /&gt;
Show, edit, update and destroy have been explicitly defined to avoid confusion among filters between different controllers.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_32.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Use the new Ruby 1.9 hash syntax===&lt;br /&gt;
This ruby syntax has been deprecated as of the current ruby version(2.3.7) used in expertiza.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_33.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Space missing after colon===&lt;br /&gt;
Space has been added after colon to make the code easily readable.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_30.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Put one space between the method name and the first argument.===&lt;br /&gt;
Space has been added between method name and the first argument to make the code easily readable.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_31.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Do not place comments on the same line as the end keyword.===&lt;br /&gt;
Adding comments at the last the line of the code is considered a bad coding practice according to rubocop standards.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_27.png]]&lt;br /&gt;
&lt;br /&gt;
== '''Testing''' ==&lt;br /&gt;
&lt;br /&gt;
The Expertiza project provides 77 rspec tests under expertiza/spec and 8 of them are related to our controllers files.  After modifying those 28 files, we want to make sure these tests could still pass. We passed all the Rspec tests except for &amp;quot;response_controller&amp;quot;. However, we were not requirement to fix the issues for this controllers.&lt;br /&gt;
&lt;br /&gt;
[[File:Testing pass.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:One_failure_testing.png]]&lt;br /&gt;
&lt;br /&gt;
===Reference===&lt;br /&gt;
*1:http://wiki.expertiza.ncsu.edu/index.php/CSC/ECE_517_Fall_2017/E1784_Fix_mass_assignments_reported_by_Brakeman.rb&lt;br /&gt;
*2: https://github.com/codeclimate/codeclimate/blob/master/README.md&lt;br /&gt;
*The Class GitHub Repository: https://github.com/expertiza/expertiza&lt;br /&gt;
*The Class Code Climate:https://codeclimate.com/github/expertiza/expertiza&lt;/div&gt;</summary>
		<author><name>Nkapadi</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=File:Unprotected_mass_assignment_2.png&amp;diff=122401</id>
		<title>File:Unprotected mass assignment 2.png</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=File:Unprotected_mass_assignment_2.png&amp;diff=122401"/>
		<updated>2019-03-26T01:11:09Z</updated>

		<summary type="html">&lt;p&gt;Nkapadi: uploaded a new version of &amp;amp;quot;File:Unprotected mass assignment 2.png&amp;amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Nkapadi</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=File:Unprotected_mass_assignment_2.png&amp;diff=122397</id>
		<title>File:Unprotected mass assignment 2.png</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=File:Unprotected_mass_assignment_2.png&amp;diff=122397"/>
		<updated>2019-03-26T01:09:21Z</updated>

		<summary type="html">&lt;p&gt;Nkapadi: uploaded a new version of &amp;amp;quot;File:Unprotected mass assignment 2.png&amp;amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Nkapadi</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=File:Unprotected_mass_assignment_2.png&amp;diff=122394</id>
		<title>File:Unprotected mass assignment 2.png</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=File:Unprotected_mass_assignment_2.png&amp;diff=122394"/>
		<updated>2019-03-26T01:07:51Z</updated>

		<summary type="html">&lt;p&gt;Nkapadi: uploaded a new version of &amp;amp;quot;File:Unprotected mass assignment 2.png&amp;amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Nkapadi</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=File:Unprotected_mass_assignment_2.png&amp;diff=122390</id>
		<title>File:Unprotected mass assignment 2.png</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=File:Unprotected_mass_assignment_2.png&amp;diff=122390"/>
		<updated>2019-03-26T01:07:20Z</updated>

		<summary type="html">&lt;p&gt;Nkapadi: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Nkapadi</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2019_-_Project_E1917._Fix_Code_Climate_issues_in_controllers_with_names_beginning_with_P_through_Z&amp;diff=122388</id>
		<title>CSC/ECE 517 Spring 2019 - Project E1917. Fix Code Climate issues in controllers with names beginning with P through Z</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2019_-_Project_E1917._Fix_Code_Climate_issues_in_controllers_with_names_beginning_with_P_through_Z&amp;diff=122388"/>
		<updated>2019-03-26T01:05:28Z</updated>

		<summary type="html">&lt;p&gt;Nkapadi: /* Issue - Do not place comments on the same line as the end keyword. */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== '''About Expertiza''' ==&lt;br /&gt;
Expertiza is an open source project based on Ruby on Rails framework. Expertiza allows the instructor to create new assignments and customize new or existing assignments. It also allows the instructor to create a list of topics the students can sign up for. Students can form teams in Expertiza to work on various projects and assignments. Students can also peer review other students' submissions. Expertiza supports submission across various document types, including the URLs and wiki pages[1].&lt;br /&gt;
&lt;br /&gt;
== '''Code Climate Issues and Problem Statements''' ==&lt;br /&gt;
&lt;br /&gt;
Codeclimate is a command line interface for the Code Climate analysis platform [2]. It can detect code smells which violate ruby/rails best practices. The task is to fix certain code climate issues detected by Code Climate analysis platform in controllers with the name beginning with P through Z. These issues includes unsafe use of methods, inappropriate syntax, non-optimal code structure which violates the DRY principle and so on. There are 37 different types of issues fixed in this project.&lt;br /&gt;
&lt;br /&gt;
====List of Issues====&lt;br /&gt;
&lt;br /&gt;
*Unprotected mass assignment&lt;br /&gt;
*Use a guard clause instead of wrapping the code inside a conditional expression&lt;br /&gt;
*Do not use Time.now without zone. Use one of Time.zone.now, Time.current, Time.now.in_time_zone, Time.now.utc, Time.now.getlocal, Time.now.iso8601, Time.now.jisx0301, Time.now.rfc3339, Time.now.to_i, Time.now.to_f instead&lt;br /&gt;
*Move redirect_to &amp;quot;/&amp;quot; out of the conditional.&lt;br /&gt;
*Block has too many lines&lt;br /&gt;
*Useless assignment to variable - initheader.&lt;br /&gt;
*Replace class var @@assignment_id with a class instance var&lt;br /&gt;
*Avoid comparing a variable with multiple items in a conditional, use Array#include? Instead&lt;br /&gt;
*Identical blocks of code found in 2 locations. Consider refactoring. &lt;br /&gt;
*Favor unless over if for negative conditions.&lt;br /&gt;
*Operator = should be surrounded by a single space. &lt;br /&gt;
*Line is too long&lt;br /&gt;
*Extra empty line detected at method body beginning. &lt;br /&gt;
*Unnecessary spacing detected.&lt;br /&gt;
*Parameters should be whitelisted for mass assignment&lt;br /&gt;
*Avoid using update_attribute because it skips validations. &lt;br /&gt;
*end at 44, 4 is not aligned with def at 39, 2. &lt;br /&gt;
*Unsafe reflection method const_get called with parameter value &lt;br /&gt;
*TODO found&lt;br /&gt;
*Convert if nested inside else to elsif&lt;br /&gt;
*Similar blocks of code found in 3 locations. Consider refactoring&lt;br /&gt;
*User controlled method execution&lt;br /&gt;
*Extra blank line detected&lt;br /&gt;
*Use empty lines between method definitions. &lt;br /&gt;
*Prefer each over for&lt;br /&gt;
*Prefer Date or Time over DateTime.&lt;br /&gt;
*Omit parentheses for ternary conditions&lt;br /&gt;
*Do not place comments on the same line as the end keyword. &lt;br /&gt;
*Useless assignment to variable - controllers. Did you mean controller?&lt;br /&gt;
*end at 135, 2 is not aligned with class at 1, 0&lt;br /&gt;
*Put one space between the method name and the first argument. &lt;br /&gt;
*Space missing after colon. &lt;br /&gt;
*Use the new Ruby 1.9 hash syntax&lt;br /&gt;
*show, edit, update, destroy are not explicitly defined on the controller. &lt;br /&gt;
*Rename is_user_ta? to user_ta?&lt;br /&gt;
*Avoid comma after the last item of an array&lt;br /&gt;
*Move redirect_to view_student_teams_path student_id: student.id out of the conditional&lt;br /&gt;
&lt;br /&gt;
== '''Implementation''' ==&lt;br /&gt;
&lt;br /&gt;
There are many minor issues such as unnecessary spacing, extra blank line detected, extra parentheses used and so on. We're not going to show all these minor fixing in this section. The focus would be on some of the important issues listed above that we fixed.&lt;br /&gt;
&lt;br /&gt;
===Issue - Unprotected Mass Assignment===&lt;br /&gt;
Mass assignment is a feature of Rails which allows an application to create a record from the values of a hash. Protection for mass assignment is on by default. Query parameters must be explicitly whitelisted via permit in order to be used in mass assignment.This issue appears in different controller files. An example of how we fixed it in questions_controller.rb is shown below:&lt;br /&gt;
[[File:Mass_Assignment_Issue.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Use a guard clause instead of wrapping the code inside a conditional expression.=== &lt;br /&gt;
[[File:Guard clause.png|center]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Do not use Time.now without zone. Use one of Time.zone.now, Time.current, Time.now.in_time_zone, Time.now.utc, Time.now.getlocal, Time.now.iso8601, Time.now.jisx0301, Time.now.rfc3339, Time.now.to_i, Time.now.to_f instead.===&lt;br /&gt;
&lt;br /&gt;
===Issue - Move redirect_to &amp;quot;/&amp;quot; out of the conditional.===&lt;br /&gt;
&lt;br /&gt;
[[File:Time_zone_and_out_of_condition.png|center]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Avoid comparing a variable with multiple items in a conditional, use Array#include? Instead ===&lt;br /&gt;
&lt;br /&gt;
===Issue - Favor unless over if for negative conditions.===&lt;br /&gt;
&lt;br /&gt;
===Issue - Unsafe reflection method const_get called with parameter value===&lt;br /&gt;
&lt;br /&gt;
[[File:Unsafe const_get.png|center]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Avoid comma after the last item of an array===&lt;br /&gt;
[[File:Issue_36.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Rename is_user_ta? to user_ta?===&lt;br /&gt;
Renamed is_user_ta? to user_ta? to follow naming conventions enforced by Rubocop.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_35.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - show, edit, update, destroy are not explicitly defined on the controller.===&lt;br /&gt;
Show, edit, update and destroy have been explicitly defined to avoid confusion among filters between different controllers.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_32.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Use the new Ruby 1.9 hash syntax===&lt;br /&gt;
This ruby syntax has been deprecated as of the current ruby version(2.3.7) used in expertiza.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_33.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Space missing after colon===&lt;br /&gt;
Space has been added after colon to make the code easily readable.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_30.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Put one space between the method name and the first argument.===&lt;br /&gt;
Space has been added between method name and the first argument to make the code easily readable.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_31.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Do not place comments on the same line as the end keyword.===&lt;br /&gt;
Adding comments at the last the line of the code is considered a bad coding practice according to rubocop standards.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_27.png]]&lt;br /&gt;
&lt;br /&gt;
== '''Testing''' ==&lt;br /&gt;
&lt;br /&gt;
The Expertiza project provides 77 rspec tests under expertiza/spec and 8 of them are related to our controllers files.  After modifying those 28 files, we want to make sure these tests could still pass. We passed all the Rspec tests except for &amp;quot;response_controller&amp;quot;. However, we were not requirement to fix the issues for this controllers.&lt;br /&gt;
&lt;br /&gt;
[[File:Testing pass.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:One_failure_testing.png]]&lt;br /&gt;
&lt;br /&gt;
===Reference===&lt;br /&gt;
*1:http://wiki.expertiza.ncsu.edu/index.php/CSC/ECE_517_Fall_2017/E1784_Fix_mass_assignments_reported_by_Brakeman.rb&lt;br /&gt;
*2: https://github.com/codeclimate/codeclimate/blob/master/README.md&lt;br /&gt;
*The Class GitHub Repository: https://github.com/expertiza/expertiza&lt;br /&gt;
*The Class Code Climate:https://codeclimate.com/github/expertiza/expertiza&lt;/div&gt;</summary>
		<author><name>Nkapadi</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2019_-_Project_E1917._Fix_Code_Climate_issues_in_controllers_with_names_beginning_with_P_through_Z&amp;diff=122386</id>
		<title>CSC/ECE 517 Spring 2019 - Project E1917. Fix Code Climate issues in controllers with names beginning with P through Z</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2019_-_Project_E1917._Fix_Code_Climate_issues_in_controllers_with_names_beginning_with_P_through_Z&amp;diff=122386"/>
		<updated>2019-03-26T01:03:23Z</updated>

		<summary type="html">&lt;p&gt;Nkapadi: /* Issue - Put one space between the method name and the first argument. */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== '''About Expertiza''' ==&lt;br /&gt;
Expertiza is an open source project based on Ruby on Rails framework. Expertiza allows the instructor to create new assignments and customize new or existing assignments. It also allows the instructor to create a list of topics the students can sign up for. Students can form teams in Expertiza to work on various projects and assignments. Students can also peer review other students' submissions. Expertiza supports submission across various document types, including the URLs and wiki pages[1].&lt;br /&gt;
&lt;br /&gt;
== '''Code Climate Issues and Problem Statements''' ==&lt;br /&gt;
&lt;br /&gt;
Codeclimate is a command line interface for the Code Climate analysis platform [2]. It can detect code smells which violate ruby/rails best practices. The task is to fix certain code climate issues detected by Code Climate analysis platform in controllers with the name beginning with P through Z. These issues includes unsafe use of methods, inappropriate syntax, non-optimal code structure which violates the DRY principle and so on. There are 37 different types of issues fixed in this project.&lt;br /&gt;
&lt;br /&gt;
====List of Issues====&lt;br /&gt;
&lt;br /&gt;
*Unprotected mass assignment&lt;br /&gt;
*Use a guard clause instead of wrapping the code inside a conditional expression&lt;br /&gt;
*Do not use Time.now without zone. Use one of Time.zone.now, Time.current, Time.now.in_time_zone, Time.now.utc, Time.now.getlocal, Time.now.iso8601, Time.now.jisx0301, Time.now.rfc3339, Time.now.to_i, Time.now.to_f instead&lt;br /&gt;
*Move redirect_to &amp;quot;/&amp;quot; out of the conditional.&lt;br /&gt;
*Block has too many lines&lt;br /&gt;
*Useless assignment to variable - initheader.&lt;br /&gt;
*Replace class var @@assignment_id with a class instance var&lt;br /&gt;
*Avoid comparing a variable with multiple items in a conditional, use Array#include? Instead&lt;br /&gt;
*Identical blocks of code found in 2 locations. Consider refactoring. &lt;br /&gt;
*Favor unless over if for negative conditions.&lt;br /&gt;
*Operator = should be surrounded by a single space. &lt;br /&gt;
*Line is too long&lt;br /&gt;
*Extra empty line detected at method body beginning. &lt;br /&gt;
*Unnecessary spacing detected.&lt;br /&gt;
*Parameters should be whitelisted for mass assignment&lt;br /&gt;
*Avoid using update_attribute because it skips validations. &lt;br /&gt;
*end at 44, 4 is not aligned with def at 39, 2. &lt;br /&gt;
*Unsafe reflection method const_get called with parameter value &lt;br /&gt;
*TODO found&lt;br /&gt;
*Convert if nested inside else to elsif&lt;br /&gt;
*Similar blocks of code found in 3 locations. Consider refactoring&lt;br /&gt;
*User controlled method execution&lt;br /&gt;
*Extra blank line detected&lt;br /&gt;
*Use empty lines between method definitions. &lt;br /&gt;
*Prefer each over for&lt;br /&gt;
*Prefer Date or Time over DateTime.&lt;br /&gt;
*Omit parentheses for ternary conditions&lt;br /&gt;
*Do not place comments on the same line as the end keyword. &lt;br /&gt;
*Useless assignment to variable - controllers. Did you mean controller?&lt;br /&gt;
*end at 135, 2 is not aligned with class at 1, 0&lt;br /&gt;
*Put one space between the method name and the first argument. &lt;br /&gt;
*Space missing after colon. &lt;br /&gt;
*Use the new Ruby 1.9 hash syntax&lt;br /&gt;
*show, edit, update, destroy are not explicitly defined on the controller. &lt;br /&gt;
*Rename is_user_ta? to user_ta?&lt;br /&gt;
*Avoid comma after the last item of an array&lt;br /&gt;
*Move redirect_to view_student_teams_path student_id: student.id out of the conditional&lt;br /&gt;
&lt;br /&gt;
== '''Implementation''' ==&lt;br /&gt;
&lt;br /&gt;
There are many minor issues such as unnecessary spacing, extra blank line detected, extra parentheses used and so on. We're not going to show all these minor fixing in this section. The focus would be on some of the important issues listed above that we fixed.&lt;br /&gt;
&lt;br /&gt;
===Issue - Unprotected Mass Assignment===&lt;br /&gt;
Mass assignment is a feature of Rails which allows an application to create a record from the values of a hash. Protection for mass assignment is on by default. Query parameters must be explicitly whitelisted via permit in order to be used in mass assignment.This issue appears in different controller files. An example of how we fixed it in questions_controller.rb is shown below:&lt;br /&gt;
[[File:Mass_Assignment_Issue.png|center]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Use a guard clause instead of wrapping the code inside a conditional expression.=== &lt;br /&gt;
[[File:Guard clause.png|center]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Do not use Time.now without zone. Use one of Time.zone.now, Time.current, Time.now.in_time_zone, Time.now.utc, Time.now.getlocal, Time.now.iso8601, Time.now.jisx0301, Time.now.rfc3339, Time.now.to_i, Time.now.to_f instead.===&lt;br /&gt;
&lt;br /&gt;
===Issue - Move redirect_to &amp;quot;/&amp;quot; out of the conditional.===&lt;br /&gt;
&lt;br /&gt;
[[File:Time_zone_and_out_of_condition.png|center]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Avoid comparing a variable with multiple items in a conditional, use Array#include? Instead ===&lt;br /&gt;
&lt;br /&gt;
===Issue - Favor unless over if for negative conditions.===&lt;br /&gt;
&lt;br /&gt;
===Issue - Unsafe reflection method const_get called with parameter value===&lt;br /&gt;
&lt;br /&gt;
[[File:Unsafe const_get.png|center]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Avoid comma after the last item of an array===&lt;br /&gt;
[[File:Issue_36.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Rename is_user_ta? to user_ta?===&lt;br /&gt;
Renamed is_user_ta? to user_ta? to follow naming conventions enforced by Rubocop.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_35.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - show, edit, update, destroy are not explicitly defined on the controller.===&lt;br /&gt;
Show, edit, update and destroy have been explicitly defined to avoid confusion among filters between different controllers.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_32.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Use the new Ruby 1.9 hash syntax===&lt;br /&gt;
This ruby syntax has been deprecated as of the current ruby version(2.3.7) used in expertiza.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_33.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Space missing after colon===&lt;br /&gt;
Space has been added after colon to make the code easily readable.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_30.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Put one space between the method name and the first argument.===&lt;br /&gt;
Space has been added between method name and the first argument to make the code easily readable.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_31.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Do not place comments on the same line as the end keyword.===&lt;br /&gt;
[[File:Issue_27.png]]&lt;br /&gt;
&lt;br /&gt;
== '''Testing''' ==&lt;br /&gt;
&lt;br /&gt;
The Expertiza project provides 77 rspec tests under expertiza/spec and 8 of them are related to our controllers files.  After modifying those 28 files, we want to make sure these tests could still pass. We passed all the Rspec tests except for &amp;quot;response_controller&amp;quot;. However, we were not requirement to fix the issues for this controllers.&lt;br /&gt;
&lt;br /&gt;
[[File:Testing pass.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:One_failure_testing.png]]&lt;br /&gt;
&lt;br /&gt;
===Reference===&lt;br /&gt;
*1:http://wiki.expertiza.ncsu.edu/index.php/CSC/ECE_517_Fall_2017/E1784_Fix_mass_assignments_reported_by_Brakeman.rb&lt;br /&gt;
*2: https://github.com/codeclimate/codeclimate/blob/master/README.md&lt;br /&gt;
*The Class GitHub Repository: https://github.com/expertiza/expertiza&lt;br /&gt;
*The Class Code Climate:https://codeclimate.com/github/expertiza/expertiza&lt;/div&gt;</summary>
		<author><name>Nkapadi</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2019_-_Project_E1917._Fix_Code_Climate_issues_in_controllers_with_names_beginning_with_P_through_Z&amp;diff=122384</id>
		<title>CSC/ECE 517 Spring 2019 - Project E1917. Fix Code Climate issues in controllers with names beginning with P through Z</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2019_-_Project_E1917._Fix_Code_Climate_issues_in_controllers_with_names_beginning_with_P_through_Z&amp;diff=122384"/>
		<updated>2019-03-26T01:02:46Z</updated>

		<summary type="html">&lt;p&gt;Nkapadi: /* Issue - Space missing after colon */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== '''About Expertiza''' ==&lt;br /&gt;
Expertiza is an open source project based on Ruby on Rails framework. Expertiza allows the instructor to create new assignments and customize new or existing assignments. It also allows the instructor to create a list of topics the students can sign up for. Students can form teams in Expertiza to work on various projects and assignments. Students can also peer review other students' submissions. Expertiza supports submission across various document types, including the URLs and wiki pages[1].&lt;br /&gt;
&lt;br /&gt;
== '''Code Climate Issues and Problem Statements''' ==&lt;br /&gt;
&lt;br /&gt;
Codeclimate is a command line interface for the Code Climate analysis platform [2]. It can detect code smells which violate ruby/rails best practices. The task is to fix certain code climate issues detected by Code Climate analysis platform in controllers with the name beginning with P through Z. These issues includes unsafe use of methods, inappropriate syntax, non-optimal code structure which violates the DRY principle and so on. There are 37 different types of issues fixed in this project.&lt;br /&gt;
&lt;br /&gt;
====List of Issues====&lt;br /&gt;
&lt;br /&gt;
*Unprotected mass assignment&lt;br /&gt;
*Use a guard clause instead of wrapping the code inside a conditional expression&lt;br /&gt;
*Do not use Time.now without zone. Use one of Time.zone.now, Time.current, Time.now.in_time_zone, Time.now.utc, Time.now.getlocal, Time.now.iso8601, Time.now.jisx0301, Time.now.rfc3339, Time.now.to_i, Time.now.to_f instead&lt;br /&gt;
*Move redirect_to &amp;quot;/&amp;quot; out of the conditional.&lt;br /&gt;
*Block has too many lines&lt;br /&gt;
*Useless assignment to variable - initheader.&lt;br /&gt;
*Replace class var @@assignment_id with a class instance var&lt;br /&gt;
*Avoid comparing a variable with multiple items in a conditional, use Array#include? Instead&lt;br /&gt;
*Identical blocks of code found in 2 locations. Consider refactoring. &lt;br /&gt;
*Favor unless over if for negative conditions.&lt;br /&gt;
*Operator = should be surrounded by a single space. &lt;br /&gt;
*Line is too long&lt;br /&gt;
*Extra empty line detected at method body beginning. &lt;br /&gt;
*Unnecessary spacing detected.&lt;br /&gt;
*Parameters should be whitelisted for mass assignment&lt;br /&gt;
*Avoid using update_attribute because it skips validations. &lt;br /&gt;
*end at 44, 4 is not aligned with def at 39, 2. &lt;br /&gt;
*Unsafe reflection method const_get called with parameter value &lt;br /&gt;
*TODO found&lt;br /&gt;
*Convert if nested inside else to elsif&lt;br /&gt;
*Similar blocks of code found in 3 locations. Consider refactoring&lt;br /&gt;
*User controlled method execution&lt;br /&gt;
*Extra blank line detected&lt;br /&gt;
*Use empty lines between method definitions. &lt;br /&gt;
*Prefer each over for&lt;br /&gt;
*Prefer Date or Time over DateTime.&lt;br /&gt;
*Omit parentheses for ternary conditions&lt;br /&gt;
*Do not place comments on the same line as the end keyword. &lt;br /&gt;
*Useless assignment to variable - controllers. Did you mean controller?&lt;br /&gt;
*end at 135, 2 is not aligned with class at 1, 0&lt;br /&gt;
*Put one space between the method name and the first argument. &lt;br /&gt;
*Space missing after colon. &lt;br /&gt;
*Use the new Ruby 1.9 hash syntax&lt;br /&gt;
*show, edit, update, destroy are not explicitly defined on the controller. &lt;br /&gt;
*Rename is_user_ta? to user_ta?&lt;br /&gt;
*Avoid comma after the last item of an array&lt;br /&gt;
*Move redirect_to view_student_teams_path student_id: student.id out of the conditional&lt;br /&gt;
&lt;br /&gt;
== '''Implementation''' ==&lt;br /&gt;
&lt;br /&gt;
There are many minor issues such as unnecessary spacing, extra blank line detected, extra parentheses used and so on. We're not going to show all these minor fixing in this section. The focus would be on some of the important issues listed above that we fixed.&lt;br /&gt;
&lt;br /&gt;
===Issue - Unprotected Mass Assignment===&lt;br /&gt;
Mass assignment is a feature of Rails which allows an application to create a record from the values of a hash. Protection for mass assignment is on by default. Query parameters must be explicitly whitelisted via permit in order to be used in mass assignment.This issue appears in different controller files. An example of how we fixed it in questions_controller.rb is shown below:&lt;br /&gt;
[[File:Mass_Assignment_Issue.png|center]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Use a guard clause instead of wrapping the code inside a conditional expression.=== &lt;br /&gt;
[[File:Guard clause.png|center]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Do not use Time.now without zone. Use one of Time.zone.now, Time.current, Time.now.in_time_zone, Time.now.utc, Time.now.getlocal, Time.now.iso8601, Time.now.jisx0301, Time.now.rfc3339, Time.now.to_i, Time.now.to_f instead.===&lt;br /&gt;
&lt;br /&gt;
===Issue - Move redirect_to &amp;quot;/&amp;quot; out of the conditional.===&lt;br /&gt;
&lt;br /&gt;
[[File:Time_zone_and_out_of_condition.png|center]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Avoid comparing a variable with multiple items in a conditional, use Array#include? Instead ===&lt;br /&gt;
&lt;br /&gt;
===Issue - Favor unless over if for negative conditions.===&lt;br /&gt;
&lt;br /&gt;
===Issue - Unsafe reflection method const_get called with parameter value===&lt;br /&gt;
&lt;br /&gt;
[[File:Unsafe const_get.png|center]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Avoid comma after the last item of an array===&lt;br /&gt;
[[File:Issue_36.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Rename is_user_ta? to user_ta?===&lt;br /&gt;
Renamed is_user_ta? to user_ta? to follow naming conventions enforced by Rubocop.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_35.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - show, edit, update, destroy are not explicitly defined on the controller.===&lt;br /&gt;
Show, edit, update and destroy have been explicitly defined to avoid confusion among filters between different controllers.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_32.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Use the new Ruby 1.9 hash syntax===&lt;br /&gt;
This ruby syntax has been deprecated as of the current ruby version(2.3.7) used in expertiza.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_33.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Space missing after colon===&lt;br /&gt;
Space has been added after colon to make the code easily readable.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_30.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Put one space between the method name and the first argument.===&lt;br /&gt;
[[File:Issue_31.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Do not place comments on the same line as the end keyword.===&lt;br /&gt;
[[File:Issue_27.png]]&lt;br /&gt;
&lt;br /&gt;
== '''Testing''' ==&lt;br /&gt;
&lt;br /&gt;
The Expertiza project provides 77 rspec tests under expertiza/spec and 8 of them are related to our controllers files.  After modifying those 28 files, we want to make sure these tests could still pass. We passed all the Rspec tests except for &amp;quot;response_controller&amp;quot;. However, we were not requirement to fix the issues for this controllers.&lt;br /&gt;
&lt;br /&gt;
[[File:Testing pass.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:One_failure_testing.png]]&lt;br /&gt;
&lt;br /&gt;
===Reference===&lt;br /&gt;
*1:http://wiki.expertiza.ncsu.edu/index.php/CSC/ECE_517_Fall_2017/E1784_Fix_mass_assignments_reported_by_Brakeman.rb&lt;br /&gt;
*2: https://github.com/codeclimate/codeclimate/blob/master/README.md&lt;br /&gt;
*The Class GitHub Repository: https://github.com/expertiza/expertiza&lt;br /&gt;
*The Class Code Climate:https://codeclimate.com/github/expertiza/expertiza&lt;/div&gt;</summary>
		<author><name>Nkapadi</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2019_-_Project_E1917._Fix_Code_Climate_issues_in_controllers_with_names_beginning_with_P_through_Z&amp;diff=122379</id>
		<title>CSC/ECE 517 Spring 2019 - Project E1917. Fix Code Climate issues in controllers with names beginning with P through Z</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2019_-_Project_E1917._Fix_Code_Climate_issues_in_controllers_with_names_beginning_with_P_through_Z&amp;diff=122379"/>
		<updated>2019-03-26T01:01:59Z</updated>

		<summary type="html">&lt;p&gt;Nkapadi: /* Issue - Use the new Ruby 1.9 hash syntax */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== '''About Expertiza''' ==&lt;br /&gt;
Expertiza is an open source project based on Ruby on Rails framework. Expertiza allows the instructor to create new assignments and customize new or existing assignments. It also allows the instructor to create a list of topics the students can sign up for. Students can form teams in Expertiza to work on various projects and assignments. Students can also peer review other students' submissions. Expertiza supports submission across various document types, including the URLs and wiki pages[1].&lt;br /&gt;
&lt;br /&gt;
== '''Code Climate Issues and Problem Statements''' ==&lt;br /&gt;
&lt;br /&gt;
Codeclimate is a command line interface for the Code Climate analysis platform [2]. It can detect code smells which violate ruby/rails best practices. The task is to fix certain code climate issues detected by Code Climate analysis platform in controllers with the name beginning with P through Z. These issues includes unsafe use of methods, inappropriate syntax, non-optimal code structure which violates the DRY principle and so on. There are 37 different types of issues fixed in this project.&lt;br /&gt;
&lt;br /&gt;
====List of Issues====&lt;br /&gt;
&lt;br /&gt;
*Unprotected mass assignment&lt;br /&gt;
*Use a guard clause instead of wrapping the code inside a conditional expression&lt;br /&gt;
*Do not use Time.now without zone. Use one of Time.zone.now, Time.current, Time.now.in_time_zone, Time.now.utc, Time.now.getlocal, Time.now.iso8601, Time.now.jisx0301, Time.now.rfc3339, Time.now.to_i, Time.now.to_f instead&lt;br /&gt;
*Move redirect_to &amp;quot;/&amp;quot; out of the conditional.&lt;br /&gt;
*Block has too many lines&lt;br /&gt;
*Useless assignment to variable - initheader.&lt;br /&gt;
*Replace class var @@assignment_id with a class instance var&lt;br /&gt;
*Avoid comparing a variable with multiple items in a conditional, use Array#include? Instead&lt;br /&gt;
*Identical blocks of code found in 2 locations. Consider refactoring. &lt;br /&gt;
*Favor unless over if for negative conditions.&lt;br /&gt;
*Operator = should be surrounded by a single space. &lt;br /&gt;
*Line is too long&lt;br /&gt;
*Extra empty line detected at method body beginning. &lt;br /&gt;
*Unnecessary spacing detected.&lt;br /&gt;
*Parameters should be whitelisted for mass assignment&lt;br /&gt;
*Avoid using update_attribute because it skips validations. &lt;br /&gt;
*end at 44, 4 is not aligned with def at 39, 2. &lt;br /&gt;
*Unsafe reflection method const_get called with parameter value &lt;br /&gt;
*TODO found&lt;br /&gt;
*Convert if nested inside else to elsif&lt;br /&gt;
*Similar blocks of code found in 3 locations. Consider refactoring&lt;br /&gt;
*User controlled method execution&lt;br /&gt;
*Extra blank line detected&lt;br /&gt;
*Use empty lines between method definitions. &lt;br /&gt;
*Prefer each over for&lt;br /&gt;
*Prefer Date or Time over DateTime.&lt;br /&gt;
*Omit parentheses for ternary conditions&lt;br /&gt;
*Do not place comments on the same line as the end keyword. &lt;br /&gt;
*Useless assignment to variable - controllers. Did you mean controller?&lt;br /&gt;
*end at 135, 2 is not aligned with class at 1, 0&lt;br /&gt;
*Put one space between the method name and the first argument. &lt;br /&gt;
*Space missing after colon. &lt;br /&gt;
*Use the new Ruby 1.9 hash syntax&lt;br /&gt;
*show, edit, update, destroy are not explicitly defined on the controller. &lt;br /&gt;
*Rename is_user_ta? to user_ta?&lt;br /&gt;
*Avoid comma after the last item of an array&lt;br /&gt;
*Move redirect_to view_student_teams_path student_id: student.id out of the conditional&lt;br /&gt;
&lt;br /&gt;
== '''Implementation''' ==&lt;br /&gt;
&lt;br /&gt;
There are many minor issues such as unnecessary spacing, extra blank line detected, extra parentheses used and so on. We're not going to show all these minor fixing in this section. The focus would be on some of the important issues listed above that we fixed.&lt;br /&gt;
&lt;br /&gt;
===Issue - Unprotected Mass Assignment===&lt;br /&gt;
Mass assignment is a feature of Rails which allows an application to create a record from the values of a hash. Protection for mass assignment is on by default. Query parameters must be explicitly whitelisted via permit in order to be used in mass assignment.This issue appears in different controller files. An example of how we fixed it in questions_controller.rb is shown below:&lt;br /&gt;
[[File:Mass_Assignment_Issue.png|center]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Use a guard clause instead of wrapping the code inside a conditional expression.=== &lt;br /&gt;
[[File:Guard clause.png|center]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Do not use Time.now without zone. Use one of Time.zone.now, Time.current, Time.now.in_time_zone, Time.now.utc, Time.now.getlocal, Time.now.iso8601, Time.now.jisx0301, Time.now.rfc3339, Time.now.to_i, Time.now.to_f instead.===&lt;br /&gt;
&lt;br /&gt;
===Issue - Move redirect_to &amp;quot;/&amp;quot; out of the conditional.===&lt;br /&gt;
&lt;br /&gt;
[[File:Time_zone_and_out_of_condition.png|center]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Avoid comparing a variable with multiple items in a conditional, use Array#include? Instead ===&lt;br /&gt;
&lt;br /&gt;
===Issue - Favor unless over if for negative conditions.===&lt;br /&gt;
&lt;br /&gt;
===Issue - Unsafe reflection method const_get called with parameter value===&lt;br /&gt;
&lt;br /&gt;
[[File:Unsafe const_get.png|center]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Avoid comma after the last item of an array===&lt;br /&gt;
[[File:Issue_36.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Rename is_user_ta? to user_ta?===&lt;br /&gt;
Renamed is_user_ta? to user_ta? to follow naming conventions enforced by Rubocop.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_35.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - show, edit, update, destroy are not explicitly defined on the controller.===&lt;br /&gt;
Show, edit, update and destroy have been explicitly defined to avoid confusion among filters between different controllers.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_32.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Use the new Ruby 1.9 hash syntax===&lt;br /&gt;
This ruby syntax has been deprecated as of the current ruby version(2.3.7) used in expertiza.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_33.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Space missing after colon===&lt;br /&gt;
[[File:Issue_30.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Put one space between the method name and the first argument.===&lt;br /&gt;
[[File:Issue_31.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Do not place comments on the same line as the end keyword.===&lt;br /&gt;
[[File:Issue_27.png]]&lt;br /&gt;
&lt;br /&gt;
== '''Testing''' ==&lt;br /&gt;
&lt;br /&gt;
The Expertiza project provides 77 rspec tests under expertiza/spec and 8 of them are related to our controllers files.  After modifying those 28 files, we want to make sure these tests could still pass. We passed all the Rspec tests except for &amp;quot;response_controller&amp;quot;. However, we were not requirement to fix the issues for this controllers.&lt;br /&gt;
&lt;br /&gt;
[[File:Testing pass.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:One_failure_testing.png]]&lt;br /&gt;
&lt;br /&gt;
===Reference===&lt;br /&gt;
*1:http://wiki.expertiza.ncsu.edu/index.php/CSC/ECE_517_Fall_2017/E1784_Fix_mass_assignments_reported_by_Brakeman.rb&lt;br /&gt;
*2: https://github.com/codeclimate/codeclimate/blob/master/README.md&lt;br /&gt;
*The Class GitHub Repository: https://github.com/expertiza/expertiza&lt;br /&gt;
*The Class Code Climate:https://codeclimate.com/github/expertiza/expertiza&lt;/div&gt;</summary>
		<author><name>Nkapadi</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2019_-_Project_E1917._Fix_Code_Climate_issues_in_controllers_with_names_beginning_with_P_through_Z&amp;diff=122374</id>
		<title>CSC/ECE 517 Spring 2019 - Project E1917. Fix Code Climate issues in controllers with names beginning with P through Z</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2019_-_Project_E1917._Fix_Code_Climate_issues_in_controllers_with_names_beginning_with_P_through_Z&amp;diff=122374"/>
		<updated>2019-03-26T01:01:20Z</updated>

		<summary type="html">&lt;p&gt;Nkapadi: /* Issue - show, edit, update, destroy are not explicitly defined on the controller. */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== '''About Expertiza''' ==&lt;br /&gt;
Expertiza is an open source project based on Ruby on Rails framework. Expertiza allows the instructor to create new assignments and customize new or existing assignments. It also allows the instructor to create a list of topics the students can sign up for. Students can form teams in Expertiza to work on various projects and assignments. Students can also peer review other students' submissions. Expertiza supports submission across various document types, including the URLs and wiki pages[1].&lt;br /&gt;
&lt;br /&gt;
== '''Code Climate Issues and Problem Statements''' ==&lt;br /&gt;
&lt;br /&gt;
Codeclimate is a command line interface for the Code Climate analysis platform [2]. It can detect code smells which violate ruby/rails best practices. The task is to fix certain code climate issues detected by Code Climate analysis platform in controllers with the name beginning with P through Z. These issues includes unsafe use of methods, inappropriate syntax, non-optimal code structure which violates the DRY principle and so on. There are 37 different types of issues fixed in this project.&lt;br /&gt;
&lt;br /&gt;
====List of Issues====&lt;br /&gt;
&lt;br /&gt;
*Unprotected mass assignment&lt;br /&gt;
*Use a guard clause instead of wrapping the code inside a conditional expression&lt;br /&gt;
*Do not use Time.now without zone. Use one of Time.zone.now, Time.current, Time.now.in_time_zone, Time.now.utc, Time.now.getlocal, Time.now.iso8601, Time.now.jisx0301, Time.now.rfc3339, Time.now.to_i, Time.now.to_f instead&lt;br /&gt;
*Move redirect_to &amp;quot;/&amp;quot; out of the conditional.&lt;br /&gt;
*Block has too many lines&lt;br /&gt;
*Useless assignment to variable - initheader.&lt;br /&gt;
*Replace class var @@assignment_id with a class instance var&lt;br /&gt;
*Avoid comparing a variable with multiple items in a conditional, use Array#include? Instead&lt;br /&gt;
*Identical blocks of code found in 2 locations. Consider refactoring. &lt;br /&gt;
*Favor unless over if for negative conditions.&lt;br /&gt;
*Operator = should be surrounded by a single space. &lt;br /&gt;
*Line is too long&lt;br /&gt;
*Extra empty line detected at method body beginning. &lt;br /&gt;
*Unnecessary spacing detected.&lt;br /&gt;
*Parameters should be whitelisted for mass assignment&lt;br /&gt;
*Avoid using update_attribute because it skips validations. &lt;br /&gt;
*end at 44, 4 is not aligned with def at 39, 2. &lt;br /&gt;
*Unsafe reflection method const_get called with parameter value &lt;br /&gt;
*TODO found&lt;br /&gt;
*Convert if nested inside else to elsif&lt;br /&gt;
*Similar blocks of code found in 3 locations. Consider refactoring&lt;br /&gt;
*User controlled method execution&lt;br /&gt;
*Extra blank line detected&lt;br /&gt;
*Use empty lines between method definitions. &lt;br /&gt;
*Prefer each over for&lt;br /&gt;
*Prefer Date or Time over DateTime.&lt;br /&gt;
*Omit parentheses for ternary conditions&lt;br /&gt;
*Do not place comments on the same line as the end keyword. &lt;br /&gt;
*Useless assignment to variable - controllers. Did you mean controller?&lt;br /&gt;
*end at 135, 2 is not aligned with class at 1, 0&lt;br /&gt;
*Put one space between the method name and the first argument. &lt;br /&gt;
*Space missing after colon. &lt;br /&gt;
*Use the new Ruby 1.9 hash syntax&lt;br /&gt;
*show, edit, update, destroy are not explicitly defined on the controller. &lt;br /&gt;
*Rename is_user_ta? to user_ta?&lt;br /&gt;
*Avoid comma after the last item of an array&lt;br /&gt;
*Move redirect_to view_student_teams_path student_id: student.id out of the conditional&lt;br /&gt;
&lt;br /&gt;
== '''Implementation''' ==&lt;br /&gt;
&lt;br /&gt;
There are many minor issues such as unnecessary spacing, extra blank line detected, extra parentheses used and so on. We're not going to show all these minor fixing in this section. The focus would be on some of the important issues listed above that we fixed.&lt;br /&gt;
&lt;br /&gt;
===Issue - Unprotected Mass Assignment===&lt;br /&gt;
Mass assignment is a feature of Rails which allows an application to create a record from the values of a hash. Protection for mass assignment is on by default. Query parameters must be explicitly whitelisted via permit in order to be used in mass assignment.This issue appears in different controller files. An example of how we fixed it in questions_controller.rb is shown below:&lt;br /&gt;
[[File:Mass_Assignment_Issue.png|center]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Use a guard clause instead of wrapping the code inside a conditional expression.=== &lt;br /&gt;
[[File:Guard clause.png|center]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Do not use Time.now without zone. Use one of Time.zone.now, Time.current, Time.now.in_time_zone, Time.now.utc, Time.now.getlocal, Time.now.iso8601, Time.now.jisx0301, Time.now.rfc3339, Time.now.to_i, Time.now.to_f instead.===&lt;br /&gt;
&lt;br /&gt;
===Issue - Move redirect_to &amp;quot;/&amp;quot; out of the conditional.===&lt;br /&gt;
&lt;br /&gt;
[[File:Time_zone_and_out_of_condition.png|center]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Avoid comparing a variable with multiple items in a conditional, use Array#include? Instead ===&lt;br /&gt;
&lt;br /&gt;
===Issue - Favor unless over if for negative conditions.===&lt;br /&gt;
&lt;br /&gt;
===Issue - Unsafe reflection method const_get called with parameter value===&lt;br /&gt;
&lt;br /&gt;
[[File:Unsafe const_get.png|center]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Avoid comma after the last item of an array===&lt;br /&gt;
[[File:Issue_36.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Rename is_user_ta? to user_ta?===&lt;br /&gt;
Renamed is_user_ta? to user_ta? to follow naming conventions enforced by Rubocop.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_35.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - show, edit, update, destroy are not explicitly defined on the controller.===&lt;br /&gt;
Show, edit, update and destroy have been explicitly defined to avoid confusion among filters between different controllers.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_32.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Use the new Ruby 1.9 hash syntax===&lt;br /&gt;
[[File:Issue_33.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Space missing after colon===&lt;br /&gt;
[[File:Issue_30.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Put one space between the method name and the first argument.===&lt;br /&gt;
[[File:Issue_31.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Do not place comments on the same line as the end keyword.===&lt;br /&gt;
[[File:Issue_27.png]]&lt;br /&gt;
&lt;br /&gt;
== '''Testing''' ==&lt;br /&gt;
&lt;br /&gt;
The Expertiza project provides 77 rspec tests under expertiza/spec and 8 of them are related to our controllers files.  After modifying those 28 files, we want to make sure these tests could still pass. We passed all the Rspec tests except for &amp;quot;response_controller&amp;quot;. However, we were not requirement to fix the issues for this controllers.&lt;br /&gt;
&lt;br /&gt;
[[File:Testing pass.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:One_failure_testing.png]]&lt;br /&gt;
&lt;br /&gt;
===Reference===&lt;br /&gt;
*1:http://wiki.expertiza.ncsu.edu/index.php/CSC/ECE_517_Fall_2017/E1784_Fix_mass_assignments_reported_by_Brakeman.rb&lt;br /&gt;
*2: https://github.com/codeclimate/codeclimate/blob/master/README.md&lt;br /&gt;
*The Class GitHub Repository: https://github.com/expertiza/expertiza&lt;br /&gt;
*The Class Code Climate:https://codeclimate.com/github/expertiza/expertiza&lt;/div&gt;</summary>
		<author><name>Nkapadi</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2019_-_Project_E1917._Fix_Code_Climate_issues_in_controllers_with_names_beginning_with_P_through_Z&amp;diff=122372</id>
		<title>CSC/ECE 517 Spring 2019 - Project E1917. Fix Code Climate issues in controllers with names beginning with P through Z</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2019_-_Project_E1917._Fix_Code_Climate_issues_in_controllers_with_names_beginning_with_P_through_Z&amp;diff=122372"/>
		<updated>2019-03-26T00:57:44Z</updated>

		<summary type="html">&lt;p&gt;Nkapadi: /* Issue - Rename is_user_ta? to user_ta? */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== '''About Expertiza''' ==&lt;br /&gt;
Expertiza is an open source project based on Ruby on Rails framework. Expertiza allows the instructor to create new assignments and customize new or existing assignments. It also allows the instructor to create a list of topics the students can sign up for. Students can form teams in Expertiza to work on various projects and assignments. Students can also peer review other students' submissions. Expertiza supports submission across various document types, including the URLs and wiki pages[1].&lt;br /&gt;
&lt;br /&gt;
== '''Code Climate Issues and Problem Statements''' ==&lt;br /&gt;
&lt;br /&gt;
Codeclimate is a command line interface for the Code Climate analysis platform [2]. It can detect code smells which violate ruby/rails best practices. The task is to fix certain code climate issues detected by Code Climate analysis platform in controllers with the name beginning with P through Z. These issues includes unsafe use of methods, inappropriate syntax, non-optimal code structure which violates the DRY principle and so on. There are 37 different types of issues fixed in this project.&lt;br /&gt;
&lt;br /&gt;
====List of Issues====&lt;br /&gt;
&lt;br /&gt;
*Unprotected mass assignment&lt;br /&gt;
*Use a guard clause instead of wrapping the code inside a conditional expression&lt;br /&gt;
*Do not use Time.now without zone. Use one of Time.zone.now, Time.current, Time.now.in_time_zone, Time.now.utc, Time.now.getlocal, Time.now.iso8601, Time.now.jisx0301, Time.now.rfc3339, Time.now.to_i, Time.now.to_f instead&lt;br /&gt;
*Move redirect_to &amp;quot;/&amp;quot; out of the conditional.&lt;br /&gt;
*Block has too many lines&lt;br /&gt;
*Useless assignment to variable - initheader.&lt;br /&gt;
*Replace class var @@assignment_id with a class instance var&lt;br /&gt;
*Avoid comparing a variable with multiple items in a conditional, use Array#include? Instead&lt;br /&gt;
*Identical blocks of code found in 2 locations. Consider refactoring. &lt;br /&gt;
*Favor unless over if for negative conditions.&lt;br /&gt;
*Operator = should be surrounded by a single space. &lt;br /&gt;
*Line is too long&lt;br /&gt;
*Extra empty line detected at method body beginning. &lt;br /&gt;
*Unnecessary spacing detected.&lt;br /&gt;
*Parameters should be whitelisted for mass assignment&lt;br /&gt;
*Avoid using update_attribute because it skips validations. &lt;br /&gt;
*end at 44, 4 is not aligned with def at 39, 2. &lt;br /&gt;
*Unsafe reflection method const_get called with parameter value &lt;br /&gt;
*TODO found&lt;br /&gt;
*Convert if nested inside else to elsif&lt;br /&gt;
*Similar blocks of code found in 3 locations. Consider refactoring&lt;br /&gt;
*User controlled method execution&lt;br /&gt;
*Extra blank line detected&lt;br /&gt;
*Use empty lines between method definitions. &lt;br /&gt;
*Prefer each over for&lt;br /&gt;
*Prefer Date or Time over DateTime.&lt;br /&gt;
*Omit parentheses for ternary conditions&lt;br /&gt;
*Do not place comments on the same line as the end keyword. &lt;br /&gt;
*Useless assignment to variable - controllers. Did you mean controller?&lt;br /&gt;
*end at 135, 2 is not aligned with class at 1, 0&lt;br /&gt;
*Put one space between the method name and the first argument. &lt;br /&gt;
*Space missing after colon. &lt;br /&gt;
*Use the new Ruby 1.9 hash syntax&lt;br /&gt;
*show, edit, update, destroy are not explicitly defined on the controller. &lt;br /&gt;
*Rename is_user_ta? to user_ta?&lt;br /&gt;
*Avoid comma after the last item of an array&lt;br /&gt;
*Move redirect_to view_student_teams_path student_id: student.id out of the conditional&lt;br /&gt;
&lt;br /&gt;
== '''Implementation''' ==&lt;br /&gt;
&lt;br /&gt;
There are many minor issues such as unnecessary spacing, extra blank line detected, extra parentheses used and so on. We're not going to show all these minor fixing in this section. The focus would be on some of the important issues listed above that we fixed.&lt;br /&gt;
&lt;br /&gt;
===Issue - Unprotected Mass Assignment===&lt;br /&gt;
Mass assignment is a feature of Rails which allows an application to create a record from the values of a hash. Protection for mass assignment is on by default. Query parameters must be explicitly whitelisted via permit in order to be used in mass assignment.This issue appears in different controller files. An example of how we fixed it in questions_controller.rb is shown below:&lt;br /&gt;
[[File:Mass_Assignment_Issue.png|center]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Use a guard clause instead of wrapping the code inside a conditional expression.=== &lt;br /&gt;
[[File:Guard clause.png|center]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Do not use Time.now without zone. Use one of Time.zone.now, Time.current, Time.now.in_time_zone, Time.now.utc, Time.now.getlocal, Time.now.iso8601, Time.now.jisx0301, Time.now.rfc3339, Time.now.to_i, Time.now.to_f instead.===&lt;br /&gt;
&lt;br /&gt;
===Issue - Move redirect_to &amp;quot;/&amp;quot; out of the conditional.===&lt;br /&gt;
&lt;br /&gt;
[[File:Time_zone_and_out_of_condition.png|center]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Avoid comparing a variable with multiple items in a conditional, use Array#include? Instead ===&lt;br /&gt;
&lt;br /&gt;
===Issue - Favor unless over if for negative conditions.===&lt;br /&gt;
&lt;br /&gt;
===Issue - Unsafe reflection method const_get called with parameter value===&lt;br /&gt;
&lt;br /&gt;
[[File:Unsafe const_get.png|center]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Avoid comma after the last item of an array===&lt;br /&gt;
[[File:Issue_36.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Rename is_user_ta? to user_ta?===&lt;br /&gt;
Renamed is_user_ta? to user_ta? to follow naming conventions enforced by Rubocop.&lt;br /&gt;
&lt;br /&gt;
[[File:Issue_35.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - show, edit, update, destroy are not explicitly defined on the controller.===&lt;br /&gt;
[[File:Issue_32.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Use the new Ruby 1.9 hash syntax===&lt;br /&gt;
[[File:Issue_33.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Space missing after colon===&lt;br /&gt;
[[File:Issue_30.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Put one space between the method name and the first argument.===&lt;br /&gt;
[[File:Issue_31.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Do not place comments on the same line as the end keyword.===&lt;br /&gt;
[[File:Issue_27.png]]&lt;br /&gt;
&lt;br /&gt;
== '''Testing''' ==&lt;br /&gt;
&lt;br /&gt;
The Expertiza project provides 77 rspec tests under expertiza/spec and 8 of them are related to our controllers files.  After modifying those 28 files, we want to make sure these tests could still pass. We passed all the Rspec tests except for &amp;quot;response_controller&amp;quot;. However, we were not requirement to fix the issues for this controllers.&lt;br /&gt;
&lt;br /&gt;
[[File:Testing pass.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:One_failure_testing.png]]&lt;br /&gt;
&lt;br /&gt;
===Reference===&lt;br /&gt;
*1:http://wiki.expertiza.ncsu.edu/index.php/CSC/ECE_517_Fall_2017/E1784_Fix_mass_assignments_reported_by_Brakeman.rb&lt;br /&gt;
*2: https://github.com/codeclimate/codeclimate/blob/master/README.md&lt;br /&gt;
*The Class GitHub Repository: https://github.com/expertiza/expertiza&lt;br /&gt;
*The Class Code Climate:https://codeclimate.com/github/expertiza/expertiza&lt;/div&gt;</summary>
		<author><name>Nkapadi</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2019_-_Project_E1917._Fix_Code_Climate_issues_in_controllers_with_names_beginning_with_P_through_Z&amp;diff=122371</id>
		<title>CSC/ECE 517 Spring 2019 - Project E1917. Fix Code Climate issues in controllers with names beginning with P through Z</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2019_-_Project_E1917._Fix_Code_Climate_issues_in_controllers_with_names_beginning_with_P_through_Z&amp;diff=122371"/>
		<updated>2019-03-26T00:57:36Z</updated>

		<summary type="html">&lt;p&gt;Nkapadi: /* Issue - Rename is_user_ta? to user_ta? */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== '''About Expertiza''' ==&lt;br /&gt;
Expertiza is an open source project based on Ruby on Rails framework. Expertiza allows the instructor to create new assignments and customize new or existing assignments. It also allows the instructor to create a list of topics the students can sign up for. Students can form teams in Expertiza to work on various projects and assignments. Students can also peer review other students' submissions. Expertiza supports submission across various document types, including the URLs and wiki pages[1].&lt;br /&gt;
&lt;br /&gt;
== '''Code Climate Issues and Problem Statements''' ==&lt;br /&gt;
&lt;br /&gt;
Codeclimate is a command line interface for the Code Climate analysis platform [2]. It can detect code smells which violate ruby/rails best practices. The task is to fix certain code climate issues detected by Code Climate analysis platform in controllers with the name beginning with P through Z. These issues includes unsafe use of methods, inappropriate syntax, non-optimal code structure which violates the DRY principle and so on. There are 37 different types of issues fixed in this project.&lt;br /&gt;
&lt;br /&gt;
====List of Issues====&lt;br /&gt;
&lt;br /&gt;
*Unprotected mass assignment&lt;br /&gt;
*Use a guard clause instead of wrapping the code inside a conditional expression&lt;br /&gt;
*Do not use Time.now without zone. Use one of Time.zone.now, Time.current, Time.now.in_time_zone, Time.now.utc, Time.now.getlocal, Time.now.iso8601, Time.now.jisx0301, Time.now.rfc3339, Time.now.to_i, Time.now.to_f instead&lt;br /&gt;
*Move redirect_to &amp;quot;/&amp;quot; out of the conditional.&lt;br /&gt;
*Block has too many lines&lt;br /&gt;
*Useless assignment to variable - initheader.&lt;br /&gt;
*Replace class var @@assignment_id with a class instance var&lt;br /&gt;
*Avoid comparing a variable with multiple items in a conditional, use Array#include? Instead&lt;br /&gt;
*Identical blocks of code found in 2 locations. Consider refactoring. &lt;br /&gt;
*Favor unless over if for negative conditions.&lt;br /&gt;
*Operator = should be surrounded by a single space. &lt;br /&gt;
*Line is too long&lt;br /&gt;
*Extra empty line detected at method body beginning. &lt;br /&gt;
*Unnecessary spacing detected.&lt;br /&gt;
*Parameters should be whitelisted for mass assignment&lt;br /&gt;
*Avoid using update_attribute because it skips validations. &lt;br /&gt;
*end at 44, 4 is not aligned with def at 39, 2. &lt;br /&gt;
*Unsafe reflection method const_get called with parameter value &lt;br /&gt;
*TODO found&lt;br /&gt;
*Convert if nested inside else to elsif&lt;br /&gt;
*Similar blocks of code found in 3 locations. Consider refactoring&lt;br /&gt;
*User controlled method execution&lt;br /&gt;
*Extra blank line detected&lt;br /&gt;
*Use empty lines between method definitions. &lt;br /&gt;
*Prefer each over for&lt;br /&gt;
*Prefer Date or Time over DateTime.&lt;br /&gt;
*Omit parentheses for ternary conditions&lt;br /&gt;
*Do not place comments on the same line as the end keyword. &lt;br /&gt;
*Useless assignment to variable - controllers. Did you mean controller?&lt;br /&gt;
*end at 135, 2 is not aligned with class at 1, 0&lt;br /&gt;
*Put one space between the method name and the first argument. &lt;br /&gt;
*Space missing after colon. &lt;br /&gt;
*Use the new Ruby 1.9 hash syntax&lt;br /&gt;
*show, edit, update, destroy are not explicitly defined on the controller. &lt;br /&gt;
*Rename is_user_ta? to user_ta?&lt;br /&gt;
*Avoid comma after the last item of an array&lt;br /&gt;
*Move redirect_to view_student_teams_path student_id: student.id out of the conditional&lt;br /&gt;
&lt;br /&gt;
== '''Implementation''' ==&lt;br /&gt;
&lt;br /&gt;
There are many minor issues such as unnecessary spacing, extra blank line detected, extra parentheses used and so on. We're not going to show all these minor fixing in this section. The focus would be on some of the important issues listed above that we fixed.&lt;br /&gt;
&lt;br /&gt;
===Issue - Unprotected Mass Assignment===&lt;br /&gt;
Mass assignment is a feature of Rails which allows an application to create a record from the values of a hash. Protection for mass assignment is on by default. Query parameters must be explicitly whitelisted via permit in order to be used in mass assignment.This issue appears in different controller files. An example of how we fixed it in questions_controller.rb is shown below:&lt;br /&gt;
[[File:Mass_Assignment_Issue.png|center]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Use a guard clause instead of wrapping the code inside a conditional expression.=== &lt;br /&gt;
[[File:Guard clause.png|center]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Do not use Time.now without zone. Use one of Time.zone.now, Time.current, Time.now.in_time_zone, Time.now.utc, Time.now.getlocal, Time.now.iso8601, Time.now.jisx0301, Time.now.rfc3339, Time.now.to_i, Time.now.to_f instead.===&lt;br /&gt;
&lt;br /&gt;
===Issue - Move redirect_to &amp;quot;/&amp;quot; out of the conditional.===&lt;br /&gt;
&lt;br /&gt;
[[File:Time_zone_and_out_of_condition.png|center]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Avoid comparing a variable with multiple items in a conditional, use Array#include? Instead ===&lt;br /&gt;
&lt;br /&gt;
===Issue - Favor unless over if for negative conditions.===&lt;br /&gt;
&lt;br /&gt;
===Issue - Unsafe reflection method const_get called with parameter value===&lt;br /&gt;
&lt;br /&gt;
[[File:Unsafe const_get.png|center]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Avoid comma after the last item of an array===&lt;br /&gt;
[[File:Issue_36.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Rename is_user_ta? to user_ta?===&lt;br /&gt;
Renamed is_user_ta? to user_ta? to follow naming conventions enforced by Rubocop.&lt;br /&gt;
[[File:Issue_35.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - show, edit, update, destroy are not explicitly defined on the controller.===&lt;br /&gt;
[[File:Issue_32.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Use the new Ruby 1.9 hash syntax===&lt;br /&gt;
[[File:Issue_33.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Space missing after colon===&lt;br /&gt;
[[File:Issue_30.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Put one space between the method name and the first argument.===&lt;br /&gt;
[[File:Issue_31.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Do not place comments on the same line as the end keyword.===&lt;br /&gt;
[[File:Issue_27.png]]&lt;br /&gt;
&lt;br /&gt;
== '''Testing''' ==&lt;br /&gt;
&lt;br /&gt;
The Expertiza project provides 77 rspec tests under expertiza/spec and 8 of them are related to our controllers files.  After modifying those 28 files, we want to make sure these tests could still pass. We passed all the Rspec tests except for &amp;quot;response_controller&amp;quot;. However, we were not requirement to fix the issues for this controllers.&lt;br /&gt;
&lt;br /&gt;
[[File:Testing pass.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:One_failure_testing.png]]&lt;br /&gt;
&lt;br /&gt;
===Reference===&lt;br /&gt;
*1:http://wiki.expertiza.ncsu.edu/index.php/CSC/ECE_517_Fall_2017/E1784_Fix_mass_assignments_reported_by_Brakeman.rb&lt;br /&gt;
*2: https://github.com/codeclimate/codeclimate/blob/master/README.md&lt;br /&gt;
*The Class GitHub Repository: https://github.com/expertiza/expertiza&lt;br /&gt;
*The Class Code Climate:https://codeclimate.com/github/expertiza/expertiza&lt;/div&gt;</summary>
		<author><name>Nkapadi</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2019_-_Project_E1917._Fix_Code_Climate_issues_in_controllers_with_names_beginning_with_P_through_Z&amp;diff=122363</id>
		<title>CSC/ECE 517 Spring 2019 - Project E1917. Fix Code Climate issues in controllers with names beginning with P through Z</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2019_-_Project_E1917._Fix_Code_Climate_issues_in_controllers_with_names_beginning_with_P_through_Z&amp;diff=122363"/>
		<updated>2019-03-26T00:54:31Z</updated>

		<summary type="html">&lt;p&gt;Nkapadi: /* Implementation */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== '''About Expertiza''' ==&lt;br /&gt;
Expertiza is an open source project based on Ruby on Rails framework. Expertiza allows the instructor to create new assignments and customize new or existing assignments. It also allows the instructor to create a list of topics the students can sign up for. Students can form teams in Expertiza to work on various projects and assignments. Students can also peer review other students' submissions. Expertiza supports submission across various document types, including the URLs and wiki pages[1].&lt;br /&gt;
&lt;br /&gt;
== '''Code Climate Issues and Problem Statements''' ==&lt;br /&gt;
&lt;br /&gt;
Codeclimate is a command line interface for the Code Climate analysis platform [2]. It can detect code smells which violate ruby/rails best practices. The task is to fix certain code climate issues detected by Code Climate analysis platform in controllers with the name beginning with P through Z. These issues includes unsafe use of methods, inappropriate syntax, non-optimal code structure which violates the DRY principle and so on. There are 37 different types of issues fixed in this project.&lt;br /&gt;
&lt;br /&gt;
====List of Issues====&lt;br /&gt;
&lt;br /&gt;
*Unprotected mass assignment&lt;br /&gt;
*Use a guard clause instead of wrapping the code inside a conditional expression&lt;br /&gt;
*Do not use Time.now without zone. Use one of Time.zone.now, Time.current, Time.now.in_time_zone, Time.now.utc, Time.now.getlocal, Time.now.iso8601, Time.now.jisx0301, Time.now.rfc3339, Time.now.to_i, Time.now.to_f instead&lt;br /&gt;
*Move redirect_to &amp;quot;/&amp;quot; out of the conditional.&lt;br /&gt;
*Block has too many lines&lt;br /&gt;
*Useless assignment to variable - initheader.&lt;br /&gt;
*Replace class var @@assignment_id with a class instance var&lt;br /&gt;
*Avoid comparing a variable with multiple items in a conditional, use Array#include? Instead&lt;br /&gt;
*Identical blocks of code found in 2 locations. Consider refactoring. &lt;br /&gt;
*Favor unless over if for negative conditions.&lt;br /&gt;
*Operator = should be surrounded by a single space. &lt;br /&gt;
*Line is too long&lt;br /&gt;
*Extra empty line detected at method body beginning. &lt;br /&gt;
*Unnecessary spacing detected.&lt;br /&gt;
*Parameters should be whitelisted for mass assignment&lt;br /&gt;
*Avoid using update_attribute because it skips validations. &lt;br /&gt;
*end at 44, 4 is not aligned with def at 39, 2. &lt;br /&gt;
*Unsafe reflection method const_get called with parameter value &lt;br /&gt;
*TODO found&lt;br /&gt;
*Convert if nested inside else to elsif&lt;br /&gt;
*Similar blocks of code found in 3 locations. Consider refactoring&lt;br /&gt;
*User controlled method execution&lt;br /&gt;
*Extra blank line detected&lt;br /&gt;
*Use empty lines between method definitions. &lt;br /&gt;
*Prefer each over for&lt;br /&gt;
*Prefer Date or Time over DateTime.&lt;br /&gt;
*Omit parentheses for ternary conditions&lt;br /&gt;
*Do not place comments on the same line as the end keyword. &lt;br /&gt;
*Useless assignment to variable - controllers. Did you mean controller?&lt;br /&gt;
*end at 135, 2 is not aligned with class at 1, 0&lt;br /&gt;
*Put one space between the method name and the first argument. &lt;br /&gt;
*Space missing after colon. &lt;br /&gt;
*Use the new Ruby 1.9 hash syntax&lt;br /&gt;
*show, edit, update, destroy are not explicitly defined on the controller. &lt;br /&gt;
*Rename is_user_ta? to user_ta?&lt;br /&gt;
*Avoid comma after the last item of an array&lt;br /&gt;
*Move redirect_to view_student_teams_path student_id: student.id out of the conditional&lt;br /&gt;
&lt;br /&gt;
== '''Implementation''' ==&lt;br /&gt;
&lt;br /&gt;
There are many minor issues such as unnecessary spacing, extra blank line detected, extra parentheses used and so on. We're not going to show all these minor fixing in this section. The focus would be on some of the important issues listed above that we fixed.&lt;br /&gt;
&lt;br /&gt;
===Issue - Unprotected Mass Assignment===&lt;br /&gt;
Mass assignment is a feature of Rails which allows an application to create a record from the values of a hash. Protection for mass assignment is on by default. Query parameters must be explicitly whitelisted via permit in order to be used in mass assignment.This issue appears in different controller files. An example of how we fixed it in questions_controller.rb is shown below:&lt;br /&gt;
[[File:Mass_Assignment_Issue.png|center]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Use a guard clause instead of wrapping the code inside a conditional expression.=== &lt;br /&gt;
[[File:Guard clause.png|center]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Do not use Time.now without zone. Use one of Time.zone.now, Time.current, Time.now.in_time_zone, Time.now.utc, Time.now.getlocal, Time.now.iso8601, Time.now.jisx0301, Time.now.rfc3339, Time.now.to_i, Time.now.to_f instead.===&lt;br /&gt;
&lt;br /&gt;
===Issue - Move redirect_to &amp;quot;/&amp;quot; out of the conditional.===&lt;br /&gt;
&lt;br /&gt;
[[File:Time_zone_and_out_of_condition.png|center]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Avoid comparing a variable with multiple items in a conditional, use Array#include? Instead ===&lt;br /&gt;
&lt;br /&gt;
===Issue - Favor unless over if for negative conditions.===&lt;br /&gt;
&lt;br /&gt;
===Issue - Unsafe reflection method const_get called with parameter value===&lt;br /&gt;
&lt;br /&gt;
[[File:Unsafe const_get.png|center]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Avoid comma after the last item of an array===&lt;br /&gt;
[[File:Issue_36.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Rename is_user_ta? to user_ta?===&lt;br /&gt;
[[File:Issue_35.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - show, edit, update, destroy are not explicitly defined on the controller.===&lt;br /&gt;
[[File:Issue_32.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Use the new Ruby 1.9 hash syntax===&lt;br /&gt;
[[File:Issue_33.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Space missing after colon===&lt;br /&gt;
[[File:Issue_30.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Put one space between the method name and the first argument.===&lt;br /&gt;
[[File:Issue_31.png]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Do not place comments on the same line as the end keyword.===&lt;br /&gt;
[[File:Issue_27.png]]&lt;br /&gt;
&lt;br /&gt;
== '''Testing''' ==&lt;br /&gt;
&lt;br /&gt;
The Expertiza project provides 77 rspec tests under expertiza/spec and 8 of them are related to our controllers files.  After modifying those 28 files, we want to make sure these tests could still pass. We passed all the Rspec tests except for &amp;quot;response_controller&amp;quot;. However, we were not requirement to fix the issues for this controllers.&lt;br /&gt;
&lt;br /&gt;
[[File:Testing pass.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:One_failure_testing.png]]&lt;br /&gt;
&lt;br /&gt;
===Reference===&lt;br /&gt;
*1:http://wiki.expertiza.ncsu.edu/index.php/CSC/ECE_517_Fall_2017/E1784_Fix_mass_assignments_reported_by_Brakeman.rb&lt;br /&gt;
*2: https://github.com/codeclimate/codeclimate/blob/master/README.md&lt;br /&gt;
*The Class GitHub Repository: https://github.com/expertiza/expertiza&lt;br /&gt;
*The Class Code Climate:https://codeclimate.com/github/expertiza/expertiza&lt;/div&gt;</summary>
		<author><name>Nkapadi</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=File:Issue_31.png&amp;diff=122357</id>
		<title>File:Issue 31.png</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=File:Issue_31.png&amp;diff=122357"/>
		<updated>2019-03-26T00:50:15Z</updated>

		<summary type="html">&lt;p&gt;Nkapadi: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Nkapadi</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=File:Issue_27.png&amp;diff=122356</id>
		<title>File:Issue 27.png</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=File:Issue_27.png&amp;diff=122356"/>
		<updated>2019-03-26T00:49:39Z</updated>

		<summary type="html">&lt;p&gt;Nkapadi: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Nkapadi</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=File:Issue_30.png&amp;diff=122354</id>
		<title>File:Issue 30.png</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=File:Issue_30.png&amp;diff=122354"/>
		<updated>2019-03-26T00:49:23Z</updated>

		<summary type="html">&lt;p&gt;Nkapadi: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Nkapadi</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=File:Issue_33.png&amp;diff=122353</id>
		<title>File:Issue 33.png</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=File:Issue_33.png&amp;diff=122353"/>
		<updated>2019-03-26T00:49:13Z</updated>

		<summary type="html">&lt;p&gt;Nkapadi: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Nkapadi</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=File:Issue_32.png&amp;diff=122352</id>
		<title>File:Issue 32.png</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=File:Issue_32.png&amp;diff=122352"/>
		<updated>2019-03-26T00:49:01Z</updated>

		<summary type="html">&lt;p&gt;Nkapadi: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Nkapadi</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=File:Issue_35.png&amp;diff=122349</id>
		<title>File:Issue 35.png</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=File:Issue_35.png&amp;diff=122349"/>
		<updated>2019-03-26T00:48:48Z</updated>

		<summary type="html">&lt;p&gt;Nkapadi: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Nkapadi</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2019_-_Project_E1917._Fix_Code_Climate_issues_in_controllers_with_names_beginning_with_P_through_Z&amp;diff=122328</id>
		<title>CSC/ECE 517 Spring 2019 - Project E1917. Fix Code Climate issues in controllers with names beginning with P through Z</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2019_-_Project_E1917._Fix_Code_Climate_issues_in_controllers_with_names_beginning_with_P_through_Z&amp;diff=122328"/>
		<updated>2019-03-26T00:21:47Z</updated>

		<summary type="html">&lt;p&gt;Nkapadi: /* Issue - Unprotected Mass Assignment */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== '''About Expertiza''' ==&lt;br /&gt;
Expertiza is an open source project based on Ruby on Rails framework. Expertiza allows the instructor to create new assignments and customize new or existing assignments. It also allows the instructor to create a list of topics the students can sign up for. Students can form teams in Expertiza to work on various projects and assignments. Students can also peer review other students' submissions. Expertiza supports submission across various document types, including the URLs and wiki pages[1].&lt;br /&gt;
&lt;br /&gt;
== '''Code Climate Issues and Problem Statements''' ==&lt;br /&gt;
&lt;br /&gt;
Codeclimate is a command line interface for the Code Climate analysis platform [2]. It can detect code smells which violate ruby/rails best practices. The task is to fix certain code climate issues detected by Code Climate analysis platform in controllers with the name beginning with P through Z. These issues includes unsafe use of methods, inappropriate syntax, non-optimal code structure which violates the DRY principle and so on. There are 37 different types of issues fixed in this project.&lt;br /&gt;
&lt;br /&gt;
====List of Issues====&lt;br /&gt;
&lt;br /&gt;
*Unprotected mass assignment&lt;br /&gt;
*Use a guard clause instead of wrapping the code inside a conditional expression&lt;br /&gt;
*Do not use Time.now without zone. Use one of Time.zone.now, Time.current, Time.now.in_time_zone, Time.now.utc, Time.now.getlocal, Time.now.iso8601, Time.now.jisx0301, Time.now.rfc3339, Time.now.to_i, Time.now.to_f instead&lt;br /&gt;
*Move redirect_to &amp;quot;/&amp;quot; out of the conditional.&lt;br /&gt;
*Block has too many lines&lt;br /&gt;
*Useless assignment to variable - initheader.&lt;br /&gt;
*Replace class var @@assignment_id with a class instance var&lt;br /&gt;
*Avoid comparing a variable with multiple items in a conditional, use Array#include? Instead&lt;br /&gt;
*Identical blocks of code found in 2 locations. Consider refactoring. &lt;br /&gt;
*Favor unless over if for negative conditions.&lt;br /&gt;
*Operator = should be surrounded by a single space. &lt;br /&gt;
*Line is too long&lt;br /&gt;
*Extra empty line detected at method body beginning. &lt;br /&gt;
*Unnecessary spacing detected.&lt;br /&gt;
*Parameters should be whitelisted for mass assignment&lt;br /&gt;
*Avoid using update_attribute because it skips validations. &lt;br /&gt;
*end at 44, 4 is not aligned with def at 39, 2. &lt;br /&gt;
*Unsafe reflection method const_get called with parameter value &lt;br /&gt;
*TODO found&lt;br /&gt;
*Convert if nested inside else to elsif&lt;br /&gt;
*Similar blocks of code found in 3 locations. Consider refactoring&lt;br /&gt;
*User controlled method execution&lt;br /&gt;
*Extra blank line detected&lt;br /&gt;
*Use empty lines between method definitions. &lt;br /&gt;
*Prefer each over for&lt;br /&gt;
*Prefer Date or Time over DateTime.&lt;br /&gt;
*Omit parentheses for ternary conditions&lt;br /&gt;
*Do not place comments on the same line as the end keyword. &lt;br /&gt;
*Useless assignment to variable - controllers. Did you mean controller?&lt;br /&gt;
*end at 135, 2 is not aligned with class at 1, 0&lt;br /&gt;
*Put one space between the method name and the first argument. &lt;br /&gt;
*Space missing after colon. &lt;br /&gt;
*Use the new Ruby 1.9 hash syntax&lt;br /&gt;
*show, edit, update, destroy are not explicitly defined on the controller. &lt;br /&gt;
*Rename is_user_ta? to user_ta?&lt;br /&gt;
*Avoid comma after the last item of an array&lt;br /&gt;
*Move redirect_to view_student_teams_path student_id: student.id out of the conditional&lt;br /&gt;
&lt;br /&gt;
== '''Implementation''' ==&lt;br /&gt;
&lt;br /&gt;
There are many minor issues such as unnecessary spacing, extra blank line detected, extra parentheses used and so on. We're not going to show all these minor fixing in this section. The focus would be on some of the important issues listed above that we fixed.&lt;br /&gt;
&lt;br /&gt;
===Issue - Unprotected Mass Assignment===&lt;br /&gt;
Mass assignment is a feature of Rails which allows an application to create a record from the values of a hash. Protection for mass assignment is on by default. Query parameters must be explicitly whitelisted via permit in order to be used in mass assignment.This issue appears in different controller files. An example of how we fixed it in questions_controller.rb is shown below:&lt;br /&gt;
[[File:Mass_Assignment_Issue.png|center]]&lt;br /&gt;
&lt;br /&gt;
===Issue - Use a guard clause instead of wrapping the code inside a conditional expression.=== &lt;br /&gt;
[[File:Guard clause.png|center]]&lt;br /&gt;
&lt;br /&gt;
== '''Testing''' ==&lt;br /&gt;
&lt;br /&gt;
The Expertiza project provides 77 rspec tests under expertiza/spec and 8 of them are related to our controllers files.  After modifying those 28 files, we want to make sure these tests could still pass. We passed all the Rspec tests except for &amp;quot;response_controller&amp;quot;. However, we were not requirement to fix the issues for this controllers.&lt;br /&gt;
&lt;br /&gt;
[[File:Testing pass.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:One_failure_testing.png]]&lt;br /&gt;
&lt;br /&gt;
===Reference===&lt;br /&gt;
*1:http://wiki.expertiza.ncsu.edu/index.php/CSC/ECE_517_Fall_2017/E1784_Fix_mass_assignments_reported_by_Brakeman.rb&lt;br /&gt;
*2: https://github.com/codeclimate/codeclimate/blob/master/README.md&lt;br /&gt;
*The Class GitHub Repository: https://github.com/expertiza/expertiza&lt;br /&gt;
*The Class Code Climate:https://codeclimate.com/github/expertiza/expertiza&lt;/div&gt;</summary>
		<author><name>Nkapadi</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=File:Issue_36.png&amp;diff=122327</id>
		<title>File:Issue 36.png</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=File:Issue_36.png&amp;diff=122327"/>
		<updated>2019-03-26T00:20:25Z</updated>

		<summary type="html">&lt;p&gt;Nkapadi: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Nkapadi</name></author>
	</entry>
</feed>