Perl 6 - the future is here, just unevenly distributed

IRC log for #webwork, 2013-04-08

| Channels | #webwork index | Today | | Search | Google Search | Plain-Text | summary

All times shown according to UTC.

Time Nick Message
01:17 mgage_ joined #webwork
01:41 mgage_ joined #webwork
01:53 Paul_Pearson joined #webwork
01:54 Paul_Pearson mgage are you there and are you busy?
01:54 mgage_ I'm here -- what's up?
01:54 Paul_Pearson writing slides for a ww consultant workshop
01:55 Paul_Pearson wondering what's actively under development with ww
01:55 mgage_ sounds good
01:55 Paul_Pearson here's what I've got
01:55 Paul_Pearson math achievements
01:55 mgage_ yep
01:55 Paul_Pearson GUI improvements
01:55 Paul_Pearson extend interactive 2D and 3D graphics capabilities
01:55 mgage_ pretty much those are done and in both release/2.6 and release/2.7
01:56 Paul_Pearson integrate with SAGE, R, PDL
01:56 mgage_ incremental guy improvements in release/2.7 -- peter's full blown homework manager is in develop branch now -- but still needs work
01:56 Paul_Pearson What about Moodle and CMS stuff?
01:57 mgage_ the integrate things are all at the proof of concept stage -- someone has done it, but getting it to work reliably so that you can just hand it to someone and it will work -- that's still a ways off.
01:57 Paul_Pearson What else should be listed as under active development?
01:58 mgage_ There are connections with both Moodle and with LTI links to blackboard -- the moodle connections have been around for 5 plus years -- not a lot of new things there. LTI works but also requires some set up
01:59 mgage_ among the new integrated things   John Travis has the Safe single cell insertions reasonably stable.
01:59 Paul_Pearson Safe = SAGE?
02:00 mgage_ The CSU folks have developed many more flash applets -- and they have moved beyond proof of concept to valuable questions
02:00 mgage_ yes I meant SAGE
02:01 mgage_ you can set up your own webwork server on amazon cloud -- some refinements to the instructions are still needed.  Takes half an hour if you know what you are doing .  it's a good way to set up a development server.
02:02 mgage_ posts at http://michaelgage.blogspot.com/2013/03/the-webwork-raleigh-code-camp-march-7.html
02:02 mgage_ http://michaelgage.blogspot.com/2013/04/answers-themes-and-essays-oh-my.html
02:02 mgage_ http://michaelgage.blogspot.com/2013/02/math-achievements-and-webwork.html
02:02 Paul_Pearson I guess I should just read your blog :)
02:03 mgage_ and http://michaelgage.blogspot.com/2012/09/hello-everyone-geoff-goehle-here.html
02:03 Paul_Pearson Cool.  Thanks!
02:03 mgage_ actually Geoff is writing a bunch of the best of these posts -- he doesn't want to get his own
02:03 mgage_ blog for some reason.
02:04 mgage_ keep track of http://webwork.maa.org/planet/
02:05 Paul_Pearson Ah, the math4 theme :)
02:06 mgage_ that's in develop right at the moment -- I don't know if I can disentangle a subset of those updates to put safely into release/2.7 or not
02:07 mgage_ I spent the day trying to clean up rough edges  of homeworkseteditor2.
02:07 mgage_ You'll notice that librarybrowser1 looks slightly different and runs faster (thanks to John Jones)
02:09 Paul_Pearson Sounds great.  For my presentation, I want to get across the fact that development is active, new features should be available in the fall, and we could always use more help.
02:10 mgage_ all true -- I hope to have 2.7 polished by the end of June and 3.0 with peter's front end ready for adventurers before next fall
02:13 mgage_ which consultant workshop is this? (when, where?)
02:17 Paul_Pearson Michigan MAA sectional on May 4 at Lake Superior State University.
02:17 mgage_ cool -- you know about the one at UM at the end of may?
02:18 Paul_Pearson Yes, I'm an organizer!
02:19 mgage_ that's what I thought -- I was just going to look it up.  It's getting so that I can't keep track anymore.  :-)
02:19 mgage_ that's a good thing actually.
02:52 mgage_ Paul_Pearson:  plus everything works reasonably well on the iPad.
02:52 mgage_ we haven't done much explicitly for that it just does
02:52 Paul_Pearson joined #webwork
02:53 Paul_Pearson Good point :)
02:54 mgage_ also if you have  release/2.7  try using theme 4 -- it looks strikingly different -- don't know if there are glitches in it yet or not
02:54 mgage_ just change it in course configuration page
02:55 Paul_Pearson I'm on testcourses.webwork.maa.org only, which I think is 2.5.1.??
02:56 mgage_ yes -- that's become release/2.6   try https://hosted2.webwork.rochester.edu/webwork2/maa104/
02:56 mgage_ with the usual profa/profa login
02:56 mgage_ it's got essay questions also
03:01 Paul_Pearson Perhaps it's time to upgrade to the color scheme to complement the nice blue buttons :)
03:03 mgage_ the neat thing is that one can make most of these changes just by adjusting the theme folder
03:03 mgage_ still aways to go to make this really easy (need to start cascading the style sheets I think)
03:55 mgage_ joined #webwork
04:44 rbeezer joined #webwork
04:55 rbeezer joined #webwork
06:40 djun joined #webwork
12:29 mgage joined #webwork
12:58 Pbelley joined #webwork
12:59 Pbelley hi
14:05 rbeezer joined #webwork
14:21 mgage joined #webwork
14:31 Paul_Pearson joined #webwork
15:00 goehle joined #webwork
15:00 goehle gora
15:07 goehle hey mgage
15:20 Paul_Pearson joined #webwork
16:21 mgage goehle: hi
16:21 goehle hey
16:22 goehle I was wondering if it would be worth the effort for me to try an split up the things I did last week into different commits
16:22 mgage how are things?
16:23 mgage I was just looking at the "bunch o things" commit -- most of that could go into /2.7 -- the changes in the paths to javaScripts needs to wait for develop  -- and the reorganization of the js directory that peter started.
16:24 mgage I've got release/2.7 running on hosted2   (you can checkout one of the maa10x courses to see how it works)
16:24 mgage it seems that I haven't even lost data from past answers in the switch over to the new past_answer tables -- I'm not sure why yet
16:24 mgage is it searching both past answer tables?
16:25 goehle huh
16:25 goehle how do you mean
16:25 goehle switiching over to per course past_answers wont delete the old past answer table
16:26 goehle if you look in your mysql database you should see both of them
16:26 mgage anyway -- I'm busy the rest of the day -- I was going to see if I could separate out the "bunch o... " commit into a part that could be offered to 2.7 this evening
16:26 goehle do you mean that something like "Show Past Answers" is returning past answers from *both* tables?
16:26 mgage in my one quick test it looked like I still had essay data from answers I submitted before I made the upgrade
16:27 mgage haven't yet figured out why -- or even verifide that that was what was happenin -- yet
16:27 mgage verified
16:27 goehle huh, thats wierd.  I'll try to upgrade oru test server here and see if thats still the case
16:27 goehle and you upgraded the tables?  thats strange, although not impossible
16:27 mgage you can do some experiments on hosted2 if you wish
16:28 mgage I did upgrade the tables (I think)
16:28 goehle table selection happens automatically in the database code
16:28 mgage not sure of anything yet -- but the math4 theme in 2.7 looks striking -- I'll pound on it more looking for bugs.
16:28 goehle nice
16:29 mgage https://hosted2.webwork.rochester.edu/webwork2/goehle_course/  will have the latest upgrades
16:29 goehle I"ll take a look
16:29 goehle and I'll try it out on our test server, which as some existing past answers stuff
16:29 mgage advising faire is starting ---- ttyl
16:30 mgage I set your course to math4 theme just for the fun of it.
16:30 goehle it does look nice
16:31 mgage it is running off my repo for release/2.7 which is very slightly ahead of openwebwork -- I'll sync them up tonight
16:31 goehle are you running chrome
16:34 goehle i'm getting a database error on hosted2
16:41 goehle ah I think I know whats going on
16:41 goehle you are seeing the previous answer for a student when you load up the problem
16:41 goehle because that answer is actually stored in the user-problem object
16:41 goehle go to show past answers or the grader
16:53 goehle hey does anyone know why I would be getting "Cannot allocate memory" errors when trying to read in the database.conf.dist file?
17:54 mgage back for one second before class -- I didn't upgrade goehle_course on hosted2
17:54 Paul_Pearson joined #webwork
17:54 mgage I'll try to do that in the next 2 minutes
17:55 mgage cannot allocate memory sounds like an infinite loop -- you getting that on your server?
17:55 goehle yeah on my server
17:55 goehle but it happens irregularly
17:55 goehle and now I am seeing it every once in a while with defaults.conf when I am on non admin pages
17:56 goehle the server its low on memory (but not swap)
17:56 goehle so maybe thats the cause
17:57 mgage your goehle_course is upgraded no
17:57 mgage now
17:57 mgage off to class again -- back around 5
17:59 goehle kk
17:59 goehle It looks like you haven't upgraded pg yet
17:59 goehle wait nm
19:59 Paul_Pearson joined #webwork
21:11 aubreyja left #webwork
21:32 mgage pg is at 2.6   -- there wasn't enough difference to make a pg 2.7 --- is that what you mean?
21:32 mgage goehle: hi
21:33 goehle hey
21:33 goehle it was my mistake
21:33 goehle I forgot that hosted is on 2.7 and didn't include the upgrades I made last week
21:34 mgage hi -- you read 2.6 on the bottom?   -- eventually I'll get these evened out
21:34 mgage right -- I haven't added that patch yet.
21:35 mgage It seemed to me like I could add the patch with the backticks and some of the updates to math4 --- and as long as I left out all of the redefining of javaScript paths the update could be applied to 2.7 -- is that what it looks like to you?
21:36 goehle definitely
21:36 mgage I don't want feature creep to take over 2.7 -- but we already have most of math4 and of essay answers so we might as well add the fixes that make those two things work smoothly
21:36 goehle in "bunch of things" I changed 13 files
21:36 mgage next question -- do you want to do this? or should i try?
21:37 goehle how does this work with git?
21:37 goehle actually I had probably better
21:38 mgage what I would do is to take the patch applied to develop and apply it to 2.7 instead -- then back out of those files where the javaScript paths were changed.
21:38 goehle unless you want me to walk you through the chagnes via chat
21:38 goehle some of the changes affect both things
21:38 mgage you are in a bit better position to recognize which changes should be included and which ones should not be
21:38 goehle yeah
21:39 goehle actuall this might not be so bad
21:39 goehle ok
21:39 mgage my only advantage is that I've been playing with git a bit more ---- if you really understand what you are doing there are some clever ways to split these things out -- unfortunately I understand only some of them and will end up doing a good deal of the fix by hand
21:39 goehle so I need a new version of the 2.7 branch
21:39 mgage if you are willing I'll suggest that you do it
21:39 goehle I still have fresh2.7 around
21:40 mgage grab a new version of the 2.7 branch,
21:40 mgage you can  do  git pull origin   to catch it up with any changes since you forked fresh 2.7
21:40 mgage (or just      git pull    will work also)
21:41 goehle ok up to date with 2.7
21:41 goehle now I *dont* want to pull from my master
21:41 goehle because that has all sorts of develop craziness
21:41 goehle I just want the one commit
21:42 mgage then manually change the files in this 2.7 branch with the changes you made in that one commit -- I think in most cases you can just copy the file over or not.  -- in a few cases you may have to copy only a few changes in the file.
21:42 goehle copy the file over from where?
21:42 goehle can I get a single file from another branch somehow?
21:42 mgage there are clever git ways of doing this which I don't quite know
21:43 mgage what I would do to get something done quickly -- is just look at the develop -- copy out the files that I know I want to change into an outside directory -- switch back to pure 2.7
21:43 mgage and replace those files.
21:44 mgage if you go to https://github.com/openwebwork/webwork2/commit/461138565050fb9f3c76198bd559c899c08fbb7f
21:44 goehle yeah
21:45 goehle I was looking at that page
21:45 mgage you can see exactly which changes you made --
21:45 goehle I was hoping to use that somehow to make my life easier
21:45 goehle but I think copying the files is best
21:46 mgage I'm sure that an expert git user would tear their hair out --- "there is an automatic way to do this using git" -- but by the time I figured it out it would take longer than just copying the files.
21:47 goehle I had to disable the facebook feature
21:47 mgage I do try to use git to accomplish this sometimes because eventually I'd like to have git make this consolidation business easier --- but I don't know nearly enough to teach someone else :-)
21:47 goehle (mostly)
21:48 mgage I think you (since you wrote the code) can look through the page above and pretty quickly divide it into changes that should be pushed to 2.7 and ones that require changes that are in develop
21:48 goehle yeah
21:48 goehle its not too bad
21:49 goehle penance for not using git commits properly in the first place
21:49 mgage in general -- if the change isn't needed/ or is likely to cause bugs -- leave it out.
21:49 mgage we're all learning
21:49 goehle what about bug fixes to the achievement stuff?
21:49 mgage I'd leave that in -- achievements are already in the master branch and in use -- so we want to fix bugs for that
21:50 mgage when you have a version that seems to work push it to your github an branch name 2.7additions  or something like that and issue a pull request.
21:50 mgage I'll check it out and also put it up on hosted2 so that you and beezer can check it out as well.
21:51 mgage if it lasts well for a week I might try to get it to work for my class after next week -- we'll see how brave I feel. :-)
21:58 mgage headed home ---- ttyl
22:48 goehle hey mgage
22:49 goehle I've got a uqestion for when you get home
22:50 goehle left #webwork
23:11 goehle joined #webwork
23:11 goehle back
23:11 goehle mgage
23:16 mgage_ joined #webwork
23:18 goehle hey mgage_
23:18 goehle so I ran into an issue
23:18 mgage_ hi
23:18 mgage_ just got done with dinner -- catching up with your commits
23:18 mgage_ what's up
23:18 goehle or lack there uv
23:18 goehle of
23:18 goehle I was having git trouble
23:19 goehle :P
23:19 goehle my issue is with jquery though
23:19 goehle jquery has to be loaded before bootstrap.js
23:19 goehle and if its loaded again after bootstrap.js then bootstrap breaks
23:19 mgage_ ok
23:19 goehle so the problem is with SetListEditor2
23:20 goehle that has to load jquery in order for the date/time stuff to work
23:20 goehle currently the perl includes html which loads jquery
23:20 goehle but that gets loaded after jquery/bootstrap in system.template breaking things
23:20 mgage_ I see.
23:20 goehle if I commen tout that part of the perl code then math4 works
23:20 goehle but it breaks math3
23:21 goehle I cant load the code JS calls *before* jquery/bootstrap because other pages depend on jquery/bootstrap being there
23:21 mgage_ right -- let me think
23:22 mgage_ can we add lines to the system.template in math3 and math2 that loads jquery/bootstrap?
23:22 mgage_ if someone upgrades those themes will be upgraded automatically
23:22 mgage_ some custom themes might break, but I don't think there are many of those.
23:23 mgage_ incidentally your less commit merges cleanly to develop.
23:23 mgage_ were you trying to make pull requests to release/2.7?
23:23 goehle I ahd them
23:23 goehle but I closed all of them because of htis
23:24 mgage_ got it -- I'm closing the pull request again -- I just opened it to see what it looked like.
23:24 goehle I could definitely add jquery to system.template for the other themes
23:25 goehle (I wouldn't even have to add bootstrap necessarily)
23:25 mgage_ if that fixes the problem then I think that is ok.
23:25 mgage_ it's a pretty minor and easily understandable change
23:25 goehle I would also need to go through the code and ocmment out any perl loads of jquery
23:25 mgage_ just looking at your commit to 2.7 now
23:26 mgage_ and I think that is ok --- because we are heading that way in any case -- besides which I think the code for loading jquery is in only one or two places.
23:27 mgage_ the changes in the commit to release/2.7 look pretty clean to me.
23:28 goehle hmmm
23:28 goehle another soluiotn
23:28 goehle would be to, for those things that use jquery
23:28 mgage_ just have to make sure they work now.   I've not seen errors on hosted2 yet -- which change is it that causes the bootstrab/jquery collision? changes to ProblemSetsList.pm?
23:28 goehle use a output_jquery_js command
23:29 goehle like the output_jquery_ui_css command
23:29 mgage_ I don't know how that works but I'll take your word for it.
23:30 mgage_ is it HomeworksetsEditor2  that causes the trouble with bootstrap/jquery?
23:30 goehle yeah
23:30 mgage_ I've been making some changes in the dateTimePicker on that but I was going to wait until your stuff was done before adding that.
23:31 goehle its also a problem wiht GatewayQuz.pm
23:31 goehle Problem.pm
23:31 goehle SetMaker
23:31 goehle UserList
23:31 goehle and some others
23:32 mgage_ so are you seeing this break on your course on hosted2?
23:33 mgage_ what ares the symptoms.  how can I trigger it
23:33 goehle I cant see it on hosted2
23:33 goehle there are a lot of pages double loading jquery
23:34 goehle but its not always a problem
23:35 goehle http://agora.cs.wcu.edu:8080/webwork2/myTestCourse/
23:35 goehle go there
23:35 goehle and log in with
23:35 goehle admin / admin
23:35 goehle and check out HomeworkSetsEditor2
23:36 mgage_ it's ok so far -- just looking at the page
23:37 mgage_ I just added the set foobar
23:37 mgage_ I'm using Chrome/macOS if that makes a difference
23:37 goehle oh, I mean it works fine
23:38 goehle but when you first go to the page notice how none of the tabs is selected
23:38 goehle now go to the classlist editor
23:38 goehle when you go to that page one of hte tabs is selected
23:38 mgage_ I see
23:38 goehle if you look at the js console for HomeworkSetsEditor2
23:38 goehle you will see an error about the function "tab" not being defined.  Thats because of hte jquery problem
23:39 mgage_ I see it
23:40 goehle I have kind of a stupid hacky solution
23:40 goehle which is to load jquery/bootstrap twice in system.template
23:40 goehle once before output_js is called and again after
23:40 mgage_ I'd prefer not to reload query a lot in any case.  It seems to me that calls for that can almost always be placed either in the system template or in ContentGenerator.pm and then inherited in the other content modules
23:41 goehle yeah
23:41 goehle thats the proper way to do it
23:41 goehle but there are about half a dozen pages that use jquery, and all of the themes would have to be modified
23:41 goehle so it may qualify as feature creep
23:41 mgage_ let me get the timing again  when are bootstrap and jqueryy needed
23:42 goehle well for math 4
23:42 goehle and PGProblemEditor4 needs both
23:42 goehle (and doesn't work correctly if you are not in math4, which is bit of an issue)
23:43 goehle PGProblemEditor3 rather
23:43 goehle and a lot of the other big ones use jquery.  LibraryBrowser,  UserList3 HomeworkSeteditor2, Problem.pm
23:43 mgage_ PGProblemEditor3 didn't work very well in any other theme so I'm not very concerned about that
23:43 goehle (sorry, I'm mixing up the webwork name and the perl module names for these)
23:44 mgage_ np
23:45 mgage_ so we need to load bootstrap and then jquery  in that order.     When do these have to be loaded? before the page is read or can it be loaded at the end of the page (the current best practice as I understand it)
23:45 goehle to further complicate things, different .pm files call for different versions of jquery
23:46 goehle but its *probably* fine if we just move everything to the most current version
23:46 goehle it can be at the end
23:46 goehle but it has to before the output_js call
23:46 mgage_ yep -- that's what I would do.  I consider that cleaning up the current 2.7 release
23:46 mgage_ also try to call those things just in one place
23:47 goehle since in general (especially moving forward) the page specific .js pages in apps will probably assume that jquery is there
23:47 mgage_ can it be placed in the output_js call?
23:47 goehle so output_js gets the content from the perl module
23:48 goehle each module can have different output, and a few of them, but certainly not all, out put a jquery line
23:52 mgage_ I could put output_JS() in ContentGenerator.pm -- which is the super class of all the content generator modules.   It could output bootstrap and jquery and then local versions of output_JS() could call the SUPER output_JS() and then add any js of their own
23:53 goehle The problem is we are at a bit of a crossroads where pages are either assuming that jquery is always present, or that it may not be
23:53 goehle so for some pages output_js assumes no jquery/bootstrap has been loaded
23:53 mgage_ and loads again I assume?
23:53 goehle then *all* of the .pm files would have to be changed
23:54 goehle right
23:54 goehle As I see it there are a few solutions.  The only one that doesn't impact multiple files and *all* of the themes is my hackey version
23:54 mgage_ minor change --- just to call SUPER before it outputs it's own scripts
23:54 goehle The other solution is to change output_js the way you describe
23:55 goehle and the third is to put bootstrap/jquery stright into the system.template files
23:55 mgage_ and that change sets things up for more uniform handling of javaScript in the future.
23:55 goehle The question then is, where do you want your webpages to get their formatting
23:55 mgage_ so in choosing between the last two I need more advice.  That last one seems the easiest
23:56 goehle I guess the other other way
23:56 goehle well, nm, thats too much work
23:56 goehle ... :P
23:57 mgage_ it's an incremental shift -- they have been getting their formatting from with in the content generator modules but that has been shifting more and more toward using the templates and js files -- I think that is the way it should go
23:57 mgage_ with peter and david's scheme almost all of the formatting takes place in client side js
23:57 mgage_ that also maximizes responsiveness
23:58 mgage_ what we're working on here is a halfway step in that direction
23:58 mgage_ have you tried just putting the bootstrap/jquery calls in math4 and commenting them out in
23:59 mgage_ various output_JS sections?
23:59 goehle in that case, as far as I understand it, you would then put the js calls in system template with the idea that the perl just outputs the raw content and any postprocessing is done afterwards.  But we are pretty far away from that right now
23:59 mgage_ if that works well with math4 -- then we can see what changes are needed to math3 to make it work there as well -- I wouldn't think it would be too bad.

| Channels | #webwork index | Today | | Search | Google Search | Plain-Text | summary