WeBWorK Main Forum

One WW course can't access the library

One WW course can't access the library

by Murphy Waggoner -
Number of replies: 3
We have 4 active webwork courses right now, 2 for me and 2 for another professor.  One of his WW courses can't access the library, and so problems in problem sets that come from the OPL don't display and when he goes to add problems from the OPL he can see any.  

Here are the various error messages.  Does anyone understand why this problem is happening for only one course?

When the professor logs on as himself and goes to the Library Browser he gets this message:  You are missing the directory templates/Library, which is needed for the Problem Library to function. It should be a link pointing to/opt/webwork/libraries/webwork-open-problem-library/OpenProblemLibrary, which you set in conf/site.conf. I tried to make the link for you, but that failed. Check the permissions in your templates directory.

When a student tries to access a question that comes from the OPL he or she gets this page.
WeBWorK::Utils::readFile(/opt/webwork/courses/Borchers-Math-130-Fall-2015/templates/Library/CollegeOfIdaho/setAlgebra_01_02_OperationsWithRealNumbers/12IntAlg_25_OperationsWithReals.pg) says: failed to read file /opt/webwork/courses/Borchers-Math-130-Fall-2015/templates/Library/CollegeOfIdaho/setAlgebra_01_02_OperationsWithRealNumbers/12IntAlg_25_OperationsWithReals.pg: No such file or directory at /opt/webwork/webwork2/lib/WeBWorK/Utils.pm line 162.

WeBWorK Error

WeBWorK has encountered a software error while attempting to process this problem. It is likely that there is an error in the problem itself. If you are a student, report this error message to your professor to have it corrected. If you are a professor, please consult the error output below for more information.

Error messages

Failed to read the problem source file.

Error details

You do not have permission to view the details of this error.

Request information

TimeTue Sep 08 10:46:52 2015
HTTP Headers
Accept-Encodinggzip, deflate, sdch
CookieWeBWorKCourseAuthen.Waggoner-Math-251-Spring-2015=murphy.waggoner%09wMxgY2SN5tkDdj3bhHT1SBak3fjYcp6U%091441051949; WeBWorKCourseAuthen.Practice=murphy.waggoner%09DrxCaBP0N1yNo5xved3qYeMnsNIHyfHK%091441056015; WeBWorKCourseAuthen.Waggoner-Math-131-Summer-2011=murphy.waggoner%09NquesZ8idpXVg5jwKZhAAftP9nq9Pfkg%091441057591; WeBWorKCourseAuthen.Czarneski-Math-151-Spring-2015=debra.czarneski%09tVeOvtC6vs8NxLpNa224QnTENpKrop4T%091441058500; WeBWorKCourseAuthen.Waggoner-Math-251-Fall-2015=murphy.waggoner%09Q0UjclztbksZWgbE50hW98EQJHcv4Ig0%091441205213; WeBWorKCourseAuthen.Borchers-Math-151-Fall-2015=brian.borchers%09WJqQeznlc5HjwF9umojtvDluEF6TGcZE%091441401143; WeBWorKCourseAuthen.admin=admin%09EXw0YUzqPxwaO1xRMLZvVePKEKXtUeWD%091441403101; WeBWorKCourseAuthen.Waggoner-Math-131-Fall-2015=murphy.waggoner%09kXUH6Ea1FXR34hA1UyAwFBGsVTIeeXAF%091441725134; WeBWorKCourseAuthen.Borchers-Math-130-Fall-2015=murphy.waggoner%09z8HkcZzt9cCFFA6j9P0rq3CYTDbNlE0u%091441727209; _ga=GA1.2.927040621.1438028145
User-AgentMozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/45.0.2454.85 Safari/537.36

You have attempted this problem 0 times.
You have unlimited attempts remaining.

PG question failed to render

Unable to obtain error messages from within the PG question.

WeBWorK Warnings

WeBWorK has encountered warnings while processing your request. If this occured when viewing a problem, it was likely caused by an error or ambiguity in that problem. Otherwise, it may indicate a problem with the WeBWorK system itself. If you are a student, report these warnings to your professor to have them corrected. If you are a professor, please consult the warning output below for more information.

Warning messages

  • Processing of this PG problem was not completed. Probably because of a syntax error.
  • The translator died prematurely and no PG warning messages were transmitted. at /opt/webwork/webwork2/lib/WeBWorK/ContentGenerator/Problem.pm line 700.

Request information

TimeTue Sep 08 10:46:52 2015

In reply to Murphy Waggoner

Re: One WW course can't access the library

by Michael Gage -
This probably requires command line access to the server to fix. There is an alias "Library" in the templates directory of the course in question which is not properly pointing to the OpenProblemLibrary. (If it's a course that is being reused it might have been pointing to the NationalProblemLibrary which has been replaced.)

It's possible that the instructor can use the FileManager to delete the Library link (don't worry it only deletes the link not the library itself).   Then go to the LibraryBrowser which will try to create the link properly.   It's possible that you won't be able to do all this from the web and will need to ask someone with command line access to the server to set the library link properly using unix commands.

In reply to Michael Gage

Re: One WW course can't access the library

by Murphy Waggoner -
The course was unarchived from one from before we updated to point to the OPL.  That would explain why it is that course and not the other three.

I deleted the link Library@, went to the Library browser, and MAGIC! it all works fine now.  No command line work needed.

In reply to Murphy Waggoner

Re: One WW course can't access the library

by Danny Glin -
One possible explanation for why this course does not have the Library link while others do is that when the course was created, it may have been modelled on a different course than the others.  When you create a course, you choose from where to copy templates.  It's possible that the other courses had templates copied from somewhere that had the Library link, while this one had templates copied from a course that did not (or templates weren't copied).

Regarding the error message you saw, it usually has one of two causes:
  1. There is an existing Library link pointing to the wrong place, which is what Mike described.
  2. There is no Library link, and the web server does not have permission to create one.
Mike provided instructions on how to handle the former.  For the latter, you would need command line access to the server.  You could then follow the permissions instructions at http://webwork.maa.org/wiki/Installation_Manual_for_2.10_on_Ubuntu_14.04#Setting_Permissions to re-set the permissions.  You can also verify if there are permission issues by trying to save a problem from within the course.  If you get errors, then this is likely the cause.