Archive for February, 2010
<html> <body> <a href="#test=test">testing</a> </body> </html>
So with Markus’s submission browse page, instead of having:
<span> <a href="#" onclick="ajax stuff">Next </a> </span>
We can have something like:
<span> <a href="#<PARAMS GO HERE>" onclick="ajax stuff">Next </a> </span>
However, that means with every AJAX call that flips the page on the table, will will also have to update all the links on the page as well.
The page number is not saved in the URL when flipping through pages.
At first we thought it was something to do with will_paginate. However, if you take a look at: http://railscasts.com/episodes/51-will-paginate . You will notice that will_paginate successfully puts the parameters into the URL. It’s not will_paginate; it’s the way we’re using will_paginate.
So now I am looking at where the Rail’s params are used. Markus does something differently with params compared to the simple website from the railscast. Additionally, I’m looking through all the AJAX calls we make on the submissions page. Finally, I am trying to understand how s_table_paginate is participating in pagination.
On a side note:
Mike gave me a nice console script to populate the submissions page for markers.
Just run script/console and place paste the following code ( ctrl shift v to paste into a terminal ):
a = Assignment.first Student.all.each do |student| student.create_group_for_working_alone_student(a.id) end
IRC log for this week’s meeting can be found here:
- Mainly supplementary status update
- See if anybody is having trouble with anything
- Chance to add to your punchline report
- Answer any questions
- Update on UI/UX work — Summary of Wednesday’s UI meeting
- Karen can’t make it for the (entire) meeting.
- Both Brian and Bryan also cannot make it for this week’s meeting.
- Everyone is to treat this course like one of your other courses. It requires just as much attention. The banked hours from the January code sprint have probably started to dry up for a few students. Keep working! 😀
- Machinist tests are working
UI/UX Update — Victoria & Farah
- At code sprint, we decided to split the group formation and assign graders functionality into two tabs. Rationale behind this decision is mainly because these two represent different concepts.
Group Formation Tab
- There will be a pane on the left-hand side containing a list of students.
- There will be a pane on the right-hand side containing a list of groups.
- To add members to a group, the instructor simply checks off the desired students from the left and clicks on an “Add” arrow to add these students to a group on the right-hand side.
- In between the list of unassigned students on the left and the list of groups on the right, there will be a left-to-right arrow for adding students and a right-to-left arrow for removing students from groups.
- Students that are assigned to a group will disappear from the list of unassigned students on the left.
- Student list (left pane) will have 3 tabs:
- All Students
- Unassigned Students (Default Tab)
- Assigned Students
- Group list (right pane) will have 3 tabs:
- All Groups (Default Tab)
- Valid Students
- Invalid Students
- As per Victoria’s discussion with Karen and Farah, some changes will be made to the existing prototypes:
- Some suggestions as to how we could make the UI easier for someone to understand.
- Replacing some text buttons with icons.
- Victoria will be making the changes mentioned above for paper prototypes that will be used for usability testing with Diane/Jen.
- Once these changes have been made, Victoria will also be posting these on the MarkUs project blog.
Unified Notes System — Robert
- Robert’s Punchline: “See if we want to have a unified notes system, or one that has tabs for each Notable type.”
- “Unified Notes System” refers to the Notes tab that displays all Notes across all Notables.
- 2 options:
(1) Notes combined in a stream under the Notes tab.
(2) Notes broken down by “notable” (Grouping, Assignment, Students..etc.)
- Karen likes the option (1) — the combined notes view.
- Details on Notables:
- Robert feels that the unified/combined approach would be simplest to implement, and if more granularity is necessary, we can have filters.
Memberships — Robert
- Wiki page on how memberships are dealt with?
- Membership is an association between a User and a Grouping.
- Taking a look at the schema might also help:
- Joseph and Robert will be meeting up to divide up the notables.
Grade Entry Form — Farah
- Farah will be starting to work on the changes Mike suggested.
- Farah liked Mike’s solution for the up-front cost problem.
Laval Update — Nelle
- Nelle met up with some teachers at her school to talk about deploying MarkUs at their school.
- Teachers had a few suggestions for new features — Nelle will be blogging about these.
- Their main goal is to prevent students from cheating.
- Nelle implemented the section restriction for group members and manually tested for it — it works properly.
- Nelle hasn’t tested anything yet — no unit tests, no functional test.
- This section restriction is not on ReviewBoard yet.
- The groupings unit tests are in bad shape; Nelle will be waiting until she finishes migrating them to Machinist.
- Nelle will be posting the patch on ReviewBoard anyway.
- Side Note: Nelle’s school only has Mac servers (to deploy MarkUs on) at the moment.
- Reading code related to the Notes system
- Reading Reviews/ other code as it comes around
- Full time offer from Amazon! (still have a couple interviews to go from other prospective employers.)
- Implement mock ups for Notes for Students and Assignments. See if we want to have a unified notes system, or one that has tabs for each Notable type.
- Implement new Notable types.
- As of today? None. It’s time to get to work!
- Pushed out MarkUs 0.6.1, and patch for 0.6.0 => 0.6.1
- Wrote / Pushed out TestDrive script
- Reviewed a bunch of code
- Keep reviewing more code, pushing for Machinist-based tests, and helping where I can
- Studying the background of ticket #418 (Changing an assignment’s due date doesn’t update the SubmissionRule’s cache). Read the requirements of flexible marking scheme, planing how to implement it.
- Solve 418 and implement flexible marking scheme
- Preparing for the festival
- Read through Mike’s comments about my changes
- Memorized how to write about 100 words in Simplified Chinese if I think of the word in English and other similarly awesome school work
- Fix Mike’s comments
- Still need to look at will_paginate
- Reading week – no roadblocks!
- Submitted a review request for the grades table (see http://review.markusproject.org/r/314/)
- Worked on and finished the functional tests for the table and
submitted a review request (see http://review.markusproject.org/r/381/)
- Went over the changes Mike suggested and started to familiarize myself with Machinist
- Implement the changes Mike suggested
- Convert my tests to use Machinist
- Student UI for the grades table
- None this week
- Finishing Ticket 531,571,512
- Read flexible schema proposal
- Start coding part of flexible schema proposal
The MarkUs team is proud to present 0.6.1! Great work everyone!
- Fixed trace on detailed CSV download for assignments
- Random TA assignment now applies only to selected groups
- Next/Previous Submission links in grader view no longer skip submissions marked “completed”
- The student edit form now accepts input properly
- New UI in students editor and grader view to manage grace credit penalties
- General bugfixes. Functional tests now all pass!
Java is a static-typed language, and every variable, method and class is explicitly defined. It’s very easy to find their definition with a little help from IDE.
When I started to program Markus in RoR, I still think in the Java way, and find something very confusing. Here is some code I saw in Assignment class:
# Are we past the due date for this assignment? class Assignment < ActiveRecord::Base # some code here def past_due_date? return !due_date.nil? &amp;amp;&amp;amp; Time.now > due_date end # some code here end
I was curious of what “due_date” is, so I naturally did an “Open Declaration” in Eclipse IDE, which gave me no feedback at all. This happens because RoR types are dynamic, and type information is not available until run-time.
Then I searched for “due_date” across the whole project, and found some references of “due_date” but no definition of it at all.
What is it? Is it an instance variable? No, the name of an instance variable always begins with “@”. Is it a local variable? No, local variable should be initialised before being used. It should be a method. Yes, it’s a method, but where is it defined?
After turning to Mike and Severin, I eventually understood that “due_date” was not defined explicitly. It was created by ActiveRecord. ActiveRecord noticed that “due_date” was a column in the database table associated with Assignment, and therefore creates the “due_date” method (getter and setter) automatically. [The database schema]
This seems incredible to a Java programmer. In Java, a method should be explicitly defined before you use it. But in RoR, you don’t necessarily have to define a method to use it – methods can be created at run-time. Finally I realised this is why we call RoR “dynamic”. And for the first time I see the benefit of being dynamic: the chunky data-object mapping code is eliminated by the magic of dynamic!
Next time, when you cannot find the definition of something, don’t be panic, but think “dynamic”.
The IRC log can be found at: http://www.cs.toronto.edu/~mconley/irc/markus/markus20100205_pg1.html
Brian Xu fixed three bugs:
512 – UI: Show the graders name in the graders drop down —- http://review.markusproject.org/r/370/
531 – Graders need a way of “un-setting” Criteria —- http://review.markusproject.org/r/369/
571 – Edit Student: “Cancel” button links to something wrong —- http://review.markusproject.org/r/371/
Bryan Shen closed: #393. multi-level folder not allowed. Bryan also plans to blog about some things he has learned from working on Markus.
Brian Xu and Bryan Shen plan to get together and discuss how they are going to complete the flexible grading scheme.
Farah plans to return to working on the grade entry. She will update the review board so we can make comments on the code. The functional tests are still in the works.
Joseph has completed 564 – Validate files with a path with a space and check configuration on startup —- http://review.markusproject.org/r/358/. He hopes to get some time next week to look at will_paginate.
jerboaa figure out that urgent issue that arrived on February 4th.
Mike, feel free to assign this bug to someone else. Everyone else, feel free to jump on it. 🙂
The Download Detailed Criteria produces a stack trace when grace days are allowed. It works when there are no grace days.
undefined method `find_by_rubric_criterion_id’ for #<Class:0xb6e475f8>
Application Trace | Framework Trace | Full Trace
Robert finished off the tests for the random Grader assignment. He plans to work on issue 569 – Investigate possible Grader Assignment problem by manually hammering on the grader assignments to see if they always update correctly onscreen.
He also plans to work on 559 – Allow Rubric Weightings to be 0 or negative. However, Karen would like to discuss how it should be done with Byron. Mike believes that Byron will be able to use the Flexible Criteria if we push hard enough.
Mike will be running next week’s meeting. Additionally, Karen would like to have a meeting on the reading week’s Friday Feb 19th.
- Shipped fix for 510 for release 0.6
- Invited down to California for Facebook interviews. [Yay!]
- Kept up with discussion on reviews.
- Determine if my fix for 510 also resolves issue 569 for occasional non updates of grader assignments.
- Find more time to work on MarkUs. This should arrive next Thursday, and during reading week.
- Lack of time due to interviews and other classes. 4 interviews with Amazon this week.
- Unable to conduct code reviews on many changes this week.
- Reviewed a bunch of code
- Wrote a handy-dandy script that lets me test drive diffs-for-review quickly and easily. See http://mikeconley.ca/blog/2010/02/02/pre-commit-code-review-in-markus-development/ towards the bottom. I’m going to polish this tool up and upload it somewhere if people are interested in using it.
- Answered some emails, commented on the blog, tried to be helpful
- Look into Details CSV Report issue that Karen and Byron are having
- Upon (hopefully) fixing above, prepare patch (possibly including other fixes for 0.6 that have been committed)
- Review more code.
- Answer any more questions that people have. Fire away!
- These past two weeks have been super busy. I have a feeling my two courses this semester are synchronized to bring the pain simultaneously. 🙁 Coming up to a rest point though.
- Wrote my first unit tests!
- Closed #393 (“Repository folder does not allow paths such as “test/path1”, 393)
- Reviewed some code
- Work on #418: Changing an assignment’s due date doesn’t update the SubmissionRule’s cache
- Write a blog to share my newbie experiences
- Gain more RoR knowledge
- There was an essay that took me almost two days!
- Completed MarkUs Usability and Interface Design Plan.
- Start prototyping for the group formation tab.
- I completed all the requests from the review. We are not longer
escaping the validate script for the user. I have figured out a way to
check for a validate script that does not have the spaces escaped by
looking at the error code from p.open and then $?
- I found a second bug that I will write a blog post about so I can
get into details and give code examples with pretty highlights
- Check-in the stuff I talked about above
- Still need to look at will_paginate
- Next week is an extremely busy week
- Didn’t get much time to work on MarkUs this week because I had three assignments due
- Will spend extra time on MarkUs this weekend and next week
- Finish functional tests for the grades table and submit a review request
- Work on the student UI
- My other courses took up most of my time this week
- Ticket 531,571,512 done
- Start to work on UI issue now
- finish test cases of above ticket
- write a blog to summary up a few discoveries
- Intensive reading of papers
Section A: Project-wide
Topic A1: Upload/Download CSV file – Replace Accordion Menu with Button + Modal Dialogue
Description: To replace the current accordion menu upload/download options with upload and download buttons running along the top of the view. Let’s call these “Action Buttons”.
- These action buttons will spawn a modal dialogue (similar to the interface we currently have for adding a new student to a group in the Groups & Graders view), where the user can specify the location of the CSV file to upload or download.
- To avoid confusion and maintain consistency, will have to apply this migration throughout the entire project.
Rationale: Having the accordion menu on the side will greatly affect the readability of the 2-pane Assign Graders view. Also, the accordion menu has caused confusion amongst users in the past, so switching to modal dialogues may improve the usability of MarkUs as a whole.
Topic A2: Reorganize Action Links & Action Buttons
Note: “Action Links” refer to the action items to the right of the page header located at the top of every view.
Description: Current prototype inherits action links from the existing release of MarkUs. However, if we were to replace the accordion menu with action buttons running along the top of the view (right-to-left), these may interfere with the existing action links we already have running from the left to the right.
Next Steps: Compile a list of action links and buttons that we will have for each view. Analyze the list and see how we can categorize, trim down, or reorganize the layout of these options.
Rationale: As mentioned in the description, the left-to-right action links may potentially interfere with the right-to-left action buttons.