From: Sam H. <sh...@ma...> - 2004-10-20 19:52:40
|
Fairly new on the wiki: http://devel.webwork.rochester.edu/twiki/bin/view/Webwork/ CodingStandards Please read, comment, disagree, etc. -sam |
From: John J. <jj...@as...> - 2004-10-22 21:00:37
|
Sam Hathaway wrote: > Fairly new on the wiki: > > http://devel.webwork.rochester.edu/twiki/bin/view/Webwork/ > CodingStandards > > Please read, comment, disagree, etc. It looks pretty good. I don't know if this would be a change, or just an addition, but I would follow a different convention when commenting out a chunk of code (as opposed to a single line). Then, I prefer commenting everything with # in the first column (by everything, I include previously commented lines and blank lines). It leaves the old indentation in tact so it is easy to read what was there, and it is easy to scan past to see where the commenting starts and ends. It is also what emacs's comment-region does by default (which was written by people who like to debate things like code formatting). John |
From: Sam H. <sh...@ma...> - 2004-10-22 21:06:41
|
On Oct 22, 2004, at 4:30 PM, John Jones wrote: > Sam Hathaway wrote: > >> Fairly new on the wiki: >> >> http://devel.webwork.rochester.edu/twiki/bin/view/Webwork/ >> CodingStandards >> >> Please read, comment, disagree, etc. > > It looks pretty good. > I don't know if this would be a change, or just an addition, but I > would follow a different convention when commenting out a chunk of > code (as opposed to a single line). Then, I prefer commenting > everything with # in the first column (by everything, I include > previously commented lines and blank lines). It leaves the old > indentation in tact so it is easy to read what was there, and it is > easy to scan past to see where the commenting starts and ends. It is > also what emacs's comment-region does by default (which was written by > people who like to debate things like code formatting). I also preserve existing comment characters when commenting-out a block of code, but I indent the comment characters as far as the least-indented line of the block. For really long blocks, POD's "=for comment" construct can be useful. -sam |
From: John J. <jj...@as...> - 2004-11-11 18:00:06
|
Hi, I just had an e-mail with two feature requests from one of our instructors (Chris from the subject line). First, I am not sure what the best venue is for entering them. There is the webwork discussion board. Posting there has the advantage that you can gauge reactions from lots of people (they can say "me too"). Or, it can be put into bugzilla, but then it has a very limited audience. I opted for here as an intermediate level. I guess the discussion could move to either of the other places if that seems more appropriate. Also, I am not 100% enamored with either of the ideas below. But I promised to pass them on. First, Chris asked for the ability to have totals of all sets being scored automatically put into scoring files (maybe signalled by another checkbox). Second, he wanted a way to send a message to people currently active. The professor could enter a message. Then, the next time any student in the course did something, the message would come up. Future actions by the same student would not trigger that message again. The system would only have to track the most recent message. He wants it to say things like "I am currently at my computer so I can respond to e-mail questions right away" and then "I am no longer at my computer". He doesn't want to use course motd for this because it only appears on some screens. I don't know if this is a great idea, but I thought some about how to do it, so I thought I would throw that in as well. By "message would come up", he suggested a pop-up. I think a true pop-up is not so good because so many people have pop-up blocking. The message could replace the next webwork screen (and have a continue button), but that strikes me as annoying from the student perspective. The method which would appeal to me is to make it another element of the template can-professor-message. It would be located at the top of the main panel with a special background to make it stand out. Behind the scenes, I would envision implimenting this as an extra field in the database. In the user table, add a (long) text field for professor_message. When a professor adds a message, webwork replaces this field for each student in the course. If webwork hits can-professor-message in the template, it checks to see if this field is non-empty for the given user. If empty, do nothing. If non-empty, give the message and set the database field to empty for that student. Anyway, if we do it, off hand that's how I would envision doing it. John |
From: Sam H. <sh...@ma...> - 2004-11-11 19:02:38
|
On Nov 11, 2004, at 12:58 PM, John Jones wrote: > First, Chris asked for the ability to have totals of all sets being > scored automatically put into scoring files (maybe signalled by > another checkbox). I'm not that familiar with the scoring module, so I'll let someone else comment on that. > Second, he wanted a way to send a message to people currently active. > The professor could enter a message. Then, the next time any student > in the course did something, the message would come up. Future > actions by the same student would not trigger that message again. The > system would only have to track the most recent message. He wants it > to say things like "I am currently at my computer so I can respond to > e-mail questions right away" and then "I am no longer at my computer". > He doesn't want to use course motd for this because it only appears > on some screens. > > I don't know if this is a great idea, but I thought some about how to > do it, so I thought I would throw that in as well. While the simple "status message" functionality above is probably useful, I think we should consider a full-blown messaging system. This is something that most CMSs do, so I don't think it would be unreasonable for WW to do it. And soon it will be easy to implement (see below). > Behind the scenes, I would envision implimenting this as an extra > field in the database. In the user table, add a (long) text field for > professor_message. When a professor adds a message, webwork replaces > this field for each student in the course. If webwork hits > can-professor-message in the template, it checks to see if this field > is non-empty for the given user. If empty, do nothing. If non-empty, > give the message and set the database field to empty for that student. > > Anyway, if we do it, off hand that's how I would envision doing it. We might want to wait for WWDBv3 (the SQL-only database system I'm working on) to implement this. At that point, we could *easily* add a `message` table that could support sending multiple messages to each user, accumulating multiple messages, sending messages to offline users, etc. An addition like this would be a good test case for the automatic-upgrade feature of WWDBv3. > By "message would come up", he suggested a pop-up. I think a true > pop-up is not so good because so many people have pop-up blocking. > The message could replace the next webwork screen (and have a continue > button), but that strikes me as annoying from the student perspective. > The method which would appeal to me is to make it another element of > the template can-professor-message. It would be located at the top of > the main panel with a special background to make it stand out. That sounds like the best implementation to me. If we do multiple messages, we should probably have an escape that prints "you have messages" instead of showing them on the screen. -sam |