WeBWorK Main Forum

Preliminary Release 2.14 of WeBWorK is ready

Preliminary Release 2.14 of WeBWorK is ready

by Michael Gage -
Number of replies: 15
The release notes, including installation and upgrade instructions are at


The release notes are on a wiki so feel free to make corrections or add clarifying notes. There is a history/versioning feature which allows us to back up to previous versions if there is a mistake so it's hard to do anything that will mess things up.

Notable features:

  1. A Docker "WeBWorK in a Box" which can be installed on your laptop or desktop machine to create a development version of a WeBWorK site. This was possible in 2.13 but with 2.14 the "WeBWorK in a Box" also includes an R server so that you can test out those statistics problems using R.
  2. Better compatibility via LTI with Canvas, Blackboard and Moodle
  3. Compatibility with PreTeXt (PTX)
  4. Smaller improvements and bug fixes -- including bug fix updates for Geogebra and Sage applets.


In reply to Michael Gage

Re: Preliminary Release 2.14 of WeBWorK is ready

by Alex Jordan -
After merging the release branch into my production branch, I'm getting these errors pertaining to LTI:

Warning messages

  • database reference is not defined at /opt/webwork/webwork2/lib/WeBWorK/Authen/LTIAdvanced/SubmitGrade.pm line 50.

Error messages

Could not create WeBWorK::Authen::LTIAdvanced::SubmitGrade object, missing items from request at /opt/webwork/webwork2/lib/WeBWorK/ContentGenerator.pm line 174.

Does anyone have insight into how to address this? I have investigated the files mentioned in the error message, but I'm not finding a solution.
In reply to Alex Jordan

Re: Preliminary Release 2.14 of WeBWorK is ready

by Michael Gage -
Two quick questions. Did you upgrade your course?

When is this warning issued? I assume you are connecting your course to D2L?
Is it during the initial connection? when grades are posted back? When starting up the webwork course?

It's worth posting this as an issue on github.com/openwebwork/webwork2 as well. Attention @dsteinmo (he works with D2L compatibility)

I'm about to leave for a short weekend camping trip so might not get to this today but will look into it when I get back Sunday if it's not resolved.

- Mike
In reply to Michael Gage

Re: Preliminary Release 2.14 of WeBWorK is ready

by tim Payer -
Will this LTI error possibly exist for Webwork Subscribers?

The MAA has yet to upload to Version 2.14, and we are in Week 1 of our Fall semester. It would be good to know if there is an LTI issue on the horizon.

It would also be good to know when the MAA intends on upgrading the subscribers to version 2.14.

Is there an intended launch date for 2.14?

Tim
In reply to tim Payer

Re: Preliminary Release 2.14 of WeBWorK is ready

by Alex Jordan -
Hi Tim,

It is entirely possible that the issue I am seeing is particular to my server (and my LMS?). I don't know enough about it yet to say. Since it is an issue just trying to reach the course listings page, I would think others would have seen it if it were going to be an issue for everyone.

I posted about it on GitHub: https://github.com/openwebwork/webwork2/issues/878

Alex
In reply to Michael Gage

Re: Preliminary Release 2.14 of WeBWorK is ready

by Alex Jordan -
I see this if I even just try to visit
webwork.pcc.edu/webwork2

(You won't see it now, because I reverted webwork2 to before the merge.)

I'll post to the GH issue tracker. Have a nice trip!
In reply to Michael Gage

Re: Preliminary Release 2.14 of WeBWorK is ready

by Murphy Waggoner -
Michael, what do you mean by “update your course”? Thanks
In reply to Murphy Waggoner

Re: Preliminary Release 2.14 of WeBWorK is ready

by Michael Gage -
When you update the software at a site in such a way that there are changes in the database then you have to "update" or "upgrade" your courses -- this basically adds new fields to the database records of old courses so that they are compatible with the new software. The site administrator does this from the "admin" course page of the site. Forgetting to do this is a common error.

In this case that was probably not the problem -- looking at the code it seems that the reference to the entire dataBase object was not being provided when constructing the SubmitGrade object. It wasn't just a matter of a missing field.
I still don't know why the db object is missing. It works on my machine :-).
That often means some kind of configuration glitch, but it could be something else.
In reply to Michael Gage

Re: Preliminary Release 2.14 of WeBWorK is ready

by Murphy Waggoner -
Thanks about the upgrade reminder. I either didn’t know or forgot, and we ran into that issue one one of my courses. Fixed now after the upgrade.
In reply to Michael Gage

Re: Preliminary Release 2.14 of WeBWorK is ready

by Danny Glin -
To clarify, this error only occurs if you have LTI grade pass back enabled on your site.

I just upgraded our production site to 2.14, and I see the same behaviour when I enable grade pass back.

On my server, it appears the only page that has this problem is the main webwork landing page (/webwork2). If you navigate directly to a course then everything works fine for me. This would make sense, since the landing page never creates a db object as there is no db interaction for that page.
In reply to Danny Glin

Re: Preliminary Release 2.14 of WeBWorK is ready

by Alex Jordan -
Thanks Danny,

I'm coming back to this later this evening to try again to complete my upgrade. Does what you found suggest a fix? Could the line that references grade passback get a conditional in front of it to check that a db object exists first?

Alex
In reply to Danny Glin

Re: Preliminary Release 2.14 of WeBWorK is ready

by Alex Jordan -
I'm trying to see if I can patch this issue so I can keep grade passback turned on.

In exploring, I see line 48 of webwork2/lib/WeBWorK/Authen/LTIAdvanced/SubmitGrade.pm may have a typo, but my Perl is not strong enough to be sure. What I see there is:

48 unless (ref($ce//'') and ref($db)//'') {

I suspect it should be:

48 unless (ref($ce//'') and ref($db//'')) {

I think the idea is that you definitely want the ref()'s to be fed something that is defined, and so it is either $db if that is defined or the empty string if not. Is that right?

This isn't going to help the issue with grade passback. For that, I have changed line 172 of to:
172 if ($ce->{LTIGradeMode} and defined($r->{db})) {

where there is the extra check that $r->{db} is defined. This does make the error messages go away. However I am unsure that I am not simply causing the conditional to always evaluate to false and skip the code below that causes the problem all the time. Is "defined($r->{db})" the right thing to test on here?

In reply to Alex Jordan

Re: Preliminary Release 2.14 of WeBWorK is ready

by Michael Gage -
Thanks to Danny's comment I can now duplicate this.

The reason I couldn't see the error is because I only configure a few classes for using LTI and Canvas -- never the whole site. (see http://webwork.maa.org/wiki/LTI-Advanced_Authentication#Make_LTI_connections_for_a_single_course)

You are correct -- line 48 has a typo.

I think your suggested fix will work -- it worked on my machine but I used
ref($r->{db}//'') to be consistent with the subsequent check. I'll submit a pull request for 2.14.
In reply to Michael Gage

Re: Preliminary Release 2.14 of WeBWorK is ready

by Benjamin Walter -
What exactly is the fix for this? I've got the same error, and I'm trying to repair it, but I haven't gotten it to work.

I tried adding an extra conditional

if ($ce->{LTIGradeMode} and defined($r->{db})) {

at line 172 of

https://github.com/openwebwork/webwork2/blob/rel-ww2.14/lib/WeBWorK/Authen/LTIAdvanced/SubmitGrade.pm

so that it reads

if ($userSet->assignment_type() =~ /gateway/) {
$score = grade_gateway($db,$userSet,$userSet->set_id,$userID);
} else {
if ($ce->{LTIGradeMode} and defined($r->{db})) {
$score = grade_set($db,$userSet,$userSet->set_id,$userID,0);
}
}

But this is clearly not right. :(