Log of /branches/rel-2-2-dev/webwork-modperl/lib/WeBWorK/ContentGenerator/Hardcopy.pm
Parent Directory
Revision
3996 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Wed Feb 1 00:23:47 2006 UTC (7 years, 3 months ago) by
sh002i
File length: 31841 byte(s)
Diff to
previous 3972
Use File::Path::mkpath to create the hardcopy directory. mkpath()
functions like ``mkdir -p'' in that it will create multiple directory
elements if needed. Closes bug #950.
Use the standard File::Temp::tempdir function instead of
makeTempDirectory() to create the actual working directory.
Add spaces after the "[edit]" links when PG errors are reported.
Revision
3972 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Wed Jan 25 23:12:05 2006 UTC (7 years, 3 months ago) by
sh002i
File length: 31678 byte(s)
Diff to
previous 3879
update copyright date range -- 2000-2006. this is probably overkill,
since there are some files that were created after 2000 and some files
that were last modified before 2006.
Revision
3750 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Tue Nov 8 20:47:12 2005 UTC (7 years, 6 months ago) by
sh002i
Original Path:
trunk/webwork-modperl/lib/WeBWorK/ContentGenerator/Hardcopy.pm
File length: 31520 byte(s)
Diff to
previous 3749
this commit fixes quite possible the stupidest thing i've ever done.
wondering where messages like this
$GlobalSets[1] (ID Sec9.2ParametricEq) not defined -- skipping
at /ww/webwork/webwork2/lib/WeBWorK/ContentGenerator/Hardcopy.pm
line 286.
were coming from?
the answer is:
$GlobalSets[1] = undef;
which is a line i put in there for testing and never removed. i am very
sorry. :-(
Revision
3666 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Thu Sep 29 01:25:20 2005 UTC (7 years, 7 months ago) by
gage
Original Path:
trunk/webwork-modperl/lib/WeBWorK/ContentGenerator/Hardcopy.pm
File length: 29409 byte(s)
Diff to
previous 3663
Simplified the interface for users (who can only download one set at a time and can only download one user).
It could be made slightly more general -- it currently implicitly assumes that either one can edit both
multiple sets and multiple users or one can edit only a single user and a single set.
Removed an error in the [edit] link when there is an error. The anchor HTML tags were wrapped two layers deep
around the reference.
Can probably still use some more tweaks in the interface.
-- Mike
Revision
3663 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Wed Sep 28 21:46:26 2005 UTC (7 years, 7 months ago) by
sh002i
Original Path:
trunk/webwork-modperl/lib/WeBWorK/ContentGenerator/Hardcopy.pm
File length: 28633 byte(s)
Diff to
previous 3659
fixed problem with `!' in set IDs, improved error reporting.
the `!' poblem was caused by passing UserSets to ScrollingRecordList
instead of passing GlobalSets. UserSets have a two-part key (user ID and
set ID), and ScrollingRecordList concatenates them with a `!' to create
the value names. This is a desireable behavior, but not one that I
remembered. Whoops.
Revision
3649 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Fri Sep 23 23:26:35 2005 UTC (7 years, 8 months ago) by
sh002i
Original Path:
trunk/webwork-modperl/lib/WeBWorK/ContentGenerator/Hardcopy.pm
File length: 26292 byte(s)
Diff to
previous 3618
Extensive refactor/rewrite.
There are probably going to be bugs here that we squished in the old
version of Hardcopy, but it seems to be pretty robust after an evening
of testing. Alert me if you see problems.
Features:
* standard ScrollingRecordLists are used for user and set selection.
* TeX source is written incrementally instead of being accumulated in
memory.
* arguments to shell commands are now quoted using String::ShellQuote
* modular design allows adding additional formats easily (i.e. dvi, ps)
* error reporting code is simplified.
* if errors/warnings occur, user will see them on screen instead of
getting the hardcopy file.
* on the error screen, user can click to get (possibly broken) hardcopy
if it exists.
* on the error screen, user can click to get interesting temporary
files. (for PDF format these are hardcopy.{tex,log,aux} and
pdflatex.std{out,err}.)
* on the error screen, if an error concerns a particular problem, an
"edit problem" link is included.
* probably more stuff i'm forgetting
Revision
3609 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Fri Sep 9 20:51:21 2005 UTC (7 years, 8 months ago) by
gage
Original Path:
trunk/webwork-modperl/lib/WeBWorK/ContentGenerator/Hardcopy.pm
File length: 31684 byte(s)
Diff to
previous 3586
Fixed a bug in which, if the Hardcopy call was the first one to
need to create the directory at (e.g.) /ww/htdocs/tmp/myCourse
then the creation of myCourse would fail. If /ww/htdocs/tmp/myCourse/gif already
existed things would go fine.
I think that more has to be done here. We need to look at how myCourse is
created when storing a gif or html is the first action and handle these
all the same. One of the difficulties is that the tmp directory might
be located anywhere -- it is not guaranteed to be under /ww/webwork/webwork2/htdocs
-- at least as we have defined it at the moment.
Revision
3432 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Sat Jul 30 01:49:44 2005 UTC (7 years, 9 months ago) by
gage
Original Path:
trunk/webwork-modperl/lib/WeBWorK/ContentGenerator/Hardcopy.pm
File length: 31958 byte(s)
Diff to
previous 3377
I've changed errorOutput($error,$details) to accept a reference to a string
or to an array for $details. These are automatically converted to the proper form.
References should be used when the $details points to a large number of bytes, such
as the contents of a file.
This version is not faster than the original method where $details was always a
string, sometimes a very long string. It does seem to save memory however.
Further savings in memory could be obtained by print directly, but there are a few instances
which call errorOutput and then do further formatting before printing.
At the moment it doesn't seem to be worth it to make the change from return to print.
Revision
3377 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Thu Jul 14 13:15:27 2005 UTC (7 years, 10 months ago) by
glarose
Original Path:
trunk/webwork-modperl/lib/WeBWorK/ContentGenerator/Hardcopy.pm
File length: 30148 byte(s)
Diff to
previous 3357
Preliminary commit of changes to add Gateway module.
This adds to WeBWorK
- the ability to create versioned, timed problem sets ("gateway tests")
for which all problems are displayed on a single page ("versioned"
means that students can get multiple versions of the problem set),
- the ability to create sets that draw problems from groups of
problems, and
- the ability to create sets that require a proctor login to start
and grade.
Sets can be defined as gateway tests or proctored gateway tests from
the ProblemSetDetail page.
Not quite bug-free yet. Known bugs include handling of problem values
on the Student Progress page (I think this may be a problem with
changing from sql database format where all entries were 'text' to
sql_single in ver 2.1, where they are integer), and a division by zero
error on the grades page (which may be the same problem).
Tests with a number of attempts per version greater than one haven't
been carefully tested, nor has scoring of gateway tests.
Revision
2394 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Thu Jun 24 21:06:22 2004 UTC (8 years, 10 months ago) by
dpvc
Original Path:
trunk/webwork-modperl/lib/WeBWorK/ContentGenerator/Hardcopy.pm
File length: 26155 byte(s)
Diff to
previous 1892
Moved problem-separation snippet to ABOVE the problem (to get the
line above the first problem and simultaneously avoid having to check
for being the last problem).
Also put the correct answers in verbatim mode to avoid having to make
and-hoc adjustments to the answer string (the result will be exactly
what the instructor typed, no matter what).
This also avoids a problem when the correct answer begins with "[",
where LaTeX would think this was part of an optional parameter to
\item and either eat the answer (up to the "]") or fail to run
entirely (if the answer were "[1,infinity)" for example).
If you don't like the verbatim, you can take it out, but then add {}
or \relax after the \item to avoid this problem.
Revision
1878 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Sat Mar 13 05:09:20 2004 UTC (9 years, 2 months ago) by
gage
Original Path:
trunk/webwork-modperl/lib/WeBWorK/ContentGenerator/Hardcopy.pm
File length: 25257 byte(s)
Diff to
previous 1841
Temporary fix for problem with hardcopy.
#my $singleSet = $r->urlpath->args("setID");
my $singleSet; #FIXME trace down how sets are being passed to hardcopy.
$singleSet was receiving the notion 1/8
@sets was getting the correct value of the number of the set.
Looks like $singleSet is receivinv a hash??
The calling code needs to be checked over and reconciled with the responding code.
Revision
1663 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Tue Dec 9 01:12:32 2003 UTC (9 years, 5 months ago) by
sh002i
Original Path:
trunk/webwork-modperl/lib/WeBWorK/ContentGenerator/Hardcopy.pm
File length: 24979 byte(s)
Diff to
previous 1636
Normalized headers. All files now contain the text below as a header.
This is important since all files now (a) use the full name of the
package, (b) assign copyright to "The WeBWorK Project", (c) give the
full path of the file (relative to CVSROOT) instead of simply the file
name, and (d) include license and warranty information.
Here is the new header:
################################################################################
# WeBWorK Online Homework Delivery System
# Copyright © 2000-2003 The WeBWorK Projcct, http://openwebwork.sf.net/
# $CVSHeader$
#
# This program is free software; you can redistribute it and/or modify it under
# the terms of either: (a) the GNU General Public License as published by the
# Free Software Foundation; either version 2, or (at your option) any later
# version, or (b) the "Artistic License" which comes with this package.
#
# This program is distributed in the hope that it will be useful, but WITHOUT
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
# FOR A PARTICULAR PURPOSE. See either the GNU General Public License or the
# Artistic License for more details.
################################################################################
Revision
1180 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Tue Jun 17 02:20:15 2003 UTC (9 years, 11 months ago) by
gage
Original Path:
trunk/webwork-modperl/lib/WeBWorK/ContentGenerator/Hardcopy.pm
File length: 23522 byte(s)
Diff to
previous 1176
Hardcopy now moves the pdf file to the tempDir/hardcopy
and sends the browser a redirect to pick it up.
Cleaned up the logic of latex2pdf and generateHardcopy to
some extent. More remains to be done. In particular
tempDir can be generated within latex2pdf. Possibly
it could be passed a file name as well, rather than a tex
string.
this process is a good candidate for testing the timing
mechanisms once they are done. How much faster is
redirect? How much faster is passing a long tex string
rather than a pointer? etc.
--Mike
Revision
1113 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Wed Jun 11 02:04:13 2003 UTC (9 years, 11 months ago) by
gage
Original Path:
trunk/webwork-modperl/lib/WeBWorK/ContentGenerator/Hardcopy.pm
File length: 16681 byte(s)
Diff to
previous 973
(1) Moved order in which snippets are assembled. Only one preamble and one postamble are used
for a single download (also a single run of TeX). The postamble ends the document and nothing
else in the file will be read by TeX.
(2) Modified the getSetTeX and getProblemTeX subroutines to include a username (for sets)
and a user object (for problems) so that problems and sets can be made for different students.
The new identifier is the first arguement.
$self->getSetTeX($effectiveUserName, $setName);
and
$self->getProblemTeX($effectiveUser,$setName, 0, $setHeader);
It seems to work pretty well, but perhaps a bit slow still.
--Mike
Revision
562 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Fri Sep 27 23:53:42 2002 UTC (10 years, 7 months ago) by
sh002i
Original Path:
trunk/webwork-modperl/lib/WeBWorK/ContentGenerator/Hardcopy.pm
File length: 7054 byte(s)
Diff to
previous 547
- created macros/IO.pl, which is loaded with no opmask by PG.pm. It is a copy
of WeBWorK::PG::IO.pm, with some changes to make it work as a macro package.
The translator no longer shares IO.pm's functions with the safe compartment.
This is a BAD THING, and should be reconsidered when the Translator is
revised.
- Changed many (but not all) checks for HTML or HTML_tth modes to match /^HTML/
in the macros.
- changed &header to &head in Problem.pm
- Added problem environment variables for gif2eps and png2eps and modified
&dangerousMacros::alias to use them
- fixed MOST of the harmless warnings in the system. there's still the "Use
of uninitialized value in null operation" warning in template(), tho.
Still to come:
- make images in PDFs work
- fix TTH mode character encodings on mac (maybe)
- have logout button invalidate key
- Pretty die messages (from outside of the translator)
- Feedback - need nice modular way of sending email
- Options - email address and password
This form allows you to request diffs between any two revisions of this file.
For each of the two "sides" of the diff,
enter a numeric revision.