Final round of commits for weighted scoring

Final round of bug fixes to get the test cases to pass.