|
25 | 25 | <tr><th>Keywords</th><td> <%== showIcon($results->{metadata}{KEYWORDS}) %> </td></tr> |
26 | 26 | </table> |
27 | 27 |
|
28 | | -<h3>You done good with the following</h3> |
29 | | - |
| 28 | +% my $pos = $results->{positive}; |
| 29 | +% if ($pos->{PGML} || $pos->{solution} || $pos->{hint}) { |
| 30 | +<h3>Good aspects of this problems are the following</h3> |
| 31 | +% } |
30 | 32 | <table class="table table-bordered"> |
31 | 33 | <tbody> |
32 | | -% if ($results->{good}{PGML}) { |
| 34 | +% if ($pos->{PGML}) { |
33 | 35 | <tr><th>PGML</th><td>This problem uses PGML, the current preferred way to write problem (text), solution and hint |
34 | 36 | blocks.</td></tr> |
35 | | -%} |
36 | | -% if ($results->{good}{solution}) { |
| 37 | +% } |
| 38 | +% if ($pos->{solution}) { |
37 | 39 | <tr><th>Solutions</th><td>This problem has a solution block. Every problem should have solutions that the |
38 | 40 | student can view after the answer data. </td></tr> |
39 | | -%} |
40 | | -% if ($results->{good}{hint}) { |
| 41 | +% } |
| 42 | +% if ($pos->{hint}) { |
41 | 43 | <tr><th>Hints</th><td>This problem has a hint. This can be helpful for students after attempting the problem |
42 | 44 | a few times (this can be set by the instructor). |
43 | | -%} |
| 45 | +% } |
| 46 | +% # list of the positive contexts: |
| 47 | +% my @good_contexts = grep { $pos->{contexts}{$_} } keys %{$pos->{parsers}}; |
| 48 | +% if (@good_contexts) { |
| 49 | + <tr><th>Modern Contexts</th><td>This problem uses the following modern contexts: |
| 50 | + <%= join(', ', @good_contexts) %> </td> |
| 51 | +% } |
| 52 | +% my @good_parsers = grep { $pos->{parsers}->{$_} } keys %{$pos->{parsers}}; |
| 53 | +% if (@good_parsers) { |
| 54 | + <tr><th>Modern Parsers</th><td>This problem uses features of the following modern parsers: |
| 55 | + <%= join(', ', @good_parsers) %> </td> |
| 56 | +% } |
| 57 | +% my @good_macros = grep { $pos->{macros}->{$_} } keys %{$pos->{macros}}; |
| 58 | +% if (@good_macros) { |
| 59 | + <tr><th>Modern Macros</th><td>This problem uses functionality from the following modern macros: |
| 60 | + <%= join(', ', @good_macros) %> </td> |
| 61 | +% } |
44 | 62 | </tbody> |
45 | 63 | </table> |
46 | 64 |
|
|
55 | 73 | % } |
56 | 74 |
|
57 | 75 | % my $has_bad_features = 0; |
58 | | -% $has_bad_features += $results->{bad}{$_} for (keys %{$results->{bad}}); |
| 76 | +% $has_bad_features += $results->{negative}{$_} for (keys %{$results->{negative}}); |
59 | 77 |
|
60 | | -% if ($has_bad_features || !$results->{good}{solution}) { |
| 78 | +% if ($has_bad_features || !$pos->{solution}) { |
61 | 79 | <h3>You can improve on the following:</h3> |
62 | 80 | <p> There are features in this problem that contain old or deprecated features. The following |
63 | 81 | list gives feedback of how the problem can be improved. </p> |
64 | 82 | %} |
65 | 83 |
|
66 | 84 | <ul> |
67 | | -% if ($results->{bad}{BEGIN_TEXT}) { |
| 85 | +% if ($results->{negative}{BEGIN_TEXT}) { |
68 | 86 | <li>This problem contains older formatting blocks like BEGIN_TEXT. Consider use PGML. |
69 | 87 | In the <em>Format Code</em> section of the PG Editor, the "Convert to PGML" should be used |
70 | 88 | as a start to get the problem switched. |
71 | 89 | </li> |
72 | 90 | %} |
73 | | -% if ($results->{bad}{beginproblem}) { |
| 91 | +% if ($results->{negative}{beginproblem}) { |
74 | 92 | <li>This problem contains the line <tt>TEXT(beginproblem())</tt>. This is no longer necessary and should be removed. </li> |
75 | 93 | %} |
76 | | -% if ($results->{bad}{context_texstrings}) { |
| 94 | +% if ($results->{negative}{context_texstrings}) { |
77 | 95 | <li>This problem contains the line <tt>Context()->texStrings;</tt>. This is no longer necessary and should be removed. </li> |
78 | 96 | %} |
79 | | -% if ($results->{bad}{oldtable}) { |
| 97 | +% if ($results->{negative}{oldtable}) { |
80 | 98 | <li>This problem contains the deprecated <tt>begintable</tt> command. This is not assessible and often cannot be |
81 | 99 | converted to hardcopy. This table should be written using <tt>nicetables</tt> or a PGML table. </li> |
82 | 100 | %} |
83 | | -% if ($results->{bad}{showPartialCorrect}) { |
| 101 | +% if ($results->{negative}{showPartialCorrect}) { |
84 | 102 | <li>This problem contains the line <tt>$showPartialCorrectAnswers = 1</tt>. This is enabled by default and needed only |
85 | 103 | if set to 0.</li> |
86 | 104 | % } |
87 | | -% if (!$results->{good}{solution}) { |
| 105 | +% if (!$pos->{solution}) { |
88 | 106 | <li>This problem does not have a solution. Consider adding one.</li> |
89 | 107 | % } |
90 | | -% if ($results->{bad}{fun_cmp} || $results->{bad}{str_cmp} || $results->{bad}{num_cmp}) { |
| 108 | +% if ($results->{negative}{fun_cmp} || $results->{negative}{str_cmp} || $results->{negative}{num_cmp}) { |
91 | 109 | <li>This problem contains the functioins <tt>num_cmp</tt>, <tt>str_cmp</tt> or <tt>fun_cmp</tt>. |
92 | 110 | These are old ways of checking answers. These should be converted to MathObjects. |
93 | 111 | % } |
94 | | -% if ($results->{bad}{multiple_loadmacros}) { |
| 112 | +% if ($results->{negative}{multiple_loadmacros}) { |
95 | 113 | <li>This problem contains two <tt>loadMacros</tt> function call. Combine the function |
96 | 114 | calls and make sure that all macros are needed for your problem. </li> |
97 | 115 | % } |
98 | | -% if ($results->{bad}{old_multiple_choice}) { |
| 116 | +% if ($results->{negative}{macros}{PGchoicemacros}) { |
99 | 117 | <li>This problem contains old versions of multiple choice. The sample problems |
100 | | - <a href="https://openwebwork.github.io/pg-docs/sample-problems/Misc/MultipleChoiceCheckbox.html"> |
101 | | - Multiple Choice with Checkbox</a>, <a href="https://openwebwork.github.io/pg-docs/sample-problems/Misc/MultipleChoicePopup.html"> |
102 | | - Multiple Choice with Popup</a> and <a href="https://openwebwork.github.io/pg-docs/sample-problems/Misc/MultipleChoiceRadio.html"> |
| 118 | + <a target="_blank" href="https://openwebwork.github.io/pg-docs/sample-problems/Misc/MultipleChoiceCheckbox.html"> |
| 119 | + Multiple Choice with Checkbox</a>, <a target="_blank" href="https://openwebwork.github.io/pg-docs/sample-problems/Misc/MultipleChoicePopup.html"> |
| 120 | + Multiple Choice with Popup</a> and <a target="_blank" href="https://openwebwork.github.io/pg-docs/sample-problems/Misc/MultipleChoiceRadio.html"> |
103 | 121 | Multiple Choice with Radio Buttons</a> should be examined as well the macros: |
104 | | - <a href="https://openwebwork.github.io/pg-docs/pod/pg/macros/parsers/parserPopUp.html">parserPopUp.pl</a>, |
105 | | - <a href="https://openwebwork.github.io/pg-docs/pod/pg/macros/parsers/parserCheckboxList.html">parserCheckboxList.pl</a> and |
106 | | - <a href="https://openwebwork.github.io/pg-docs/pod/pg/macros/parsers/parserRadioButtons.html">parserRadioButtons.pl</a>. |
| 122 | + <a target="_blank" href="https://openwebwork.github.io/pg-docs/pod/pg/macros/parsers/parserPopUp.html">parserPopUp.pl</a>, |
| 123 | + <a target="_blank" href="https://openwebwork.github.io/pg-docs/pod/pg/macros/parsers/parserCheckboxList.html">parserCheckboxList.pl</a> and |
| 124 | + <a target="_blank" href="https://openwebwork.github.io/pg-docs/pod/pg/macros/parsers/parserRadioButtons.html">parserRadioButtons.pl</a>. |
107 | 125 |
|
108 | 126 | </li> |
109 | 127 | % } |
110 | | -% if ($results->{bad}{lines_below_enddocument}) { |
| 128 | +% if ($results->{negative}{macros}{PGgraphmacros}) { |
| 129 | + <li>This problem uses <tt>PGgraphmacros</tt> a old plotting library. Consider using |
| 130 | + <a target="_blank" href="https://openwebwork.github.io/pg-docs/pod/pg/macros/graph/plots.html"><tt>Plots.pl</tt></a> |
| 131 | + or <a target="_blank" href="https://openwebwork.github.io/pg-docs/pod/pg/macros/graph/PGtikz.html"><tt>PGtikz.pl</tt></a> |
| 132 | +%} |
| 133 | +% if ($results->{negative}{lines_below_enddocument}) { |
111 | 134 | <li>There is content (code or other text), below the <tt>ENDDOCUMENT()</tt> line. Although this |
112 | 135 | is ignored, there shouldn't be content in this area.</li> |
113 | 136 | % } |
|
0 commit comments