Skip to content
This repository was archived by the owner on Jun 7, 2023. It is now read-only.

Commit 5dbca3d

Browse files
committed
Merge branch 'master' into peer_support
2 parents 77c7418 + c9ffe4e commit 5dbca3d

12 files changed

Lines changed: 76 additions & 38 deletions

File tree

index.rst

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,9 @@ Components
2626
runestone/*/toctree
2727
runestone/__init__.py
2828
runestone/__main__.py
29+
runestone/conftest.py
30+
runestone/shared_conftest.py
31+
runestone/unittest_base.py
2932

3033

3134
Packaging
@@ -36,6 +39,7 @@ Packaging
3639
setup.py
3740
setup.cfg
3841
MANIFEST.in
42+
webpack.config.js
3943

4044
Misc
4145
====
@@ -47,11 +51,11 @@ Misc
4751
runestone/conftest.py
4852
runestone/shared_conftest.py
4953
.gitignore
54+
.github/workflows/python-package.yml
5055
.readthedocs.yml
5156
conf.py
5257
codechat_config.yaml
5358
requirements-dev.in
5459
requirements.in
55-
webpack.config.js
5660
public/index.html
5761
makeRelease.sh

runestone/activecode/toctree.rst

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
*************************************************
2-
ActiveCode
2+
ActiveCode - Run code in the browser
33
*************************************************
4+
See the `overview <https://runestone.academy/runestone/books/published/overview/ActiveCode/toctree.html>`_.
5+
46
.. toctree::
57
:maxdepth: 1
68
:glob:

runestone/assignment/__init__.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,7 @@
1+
# ***********************************************
2+
# |docname| - Define the ``assignment`` directive
3+
# ***********************************************
4+
#
15
# Copyright (C) 2015 Paul Resnick
26
#
37
# This program is free software: you can redistribute it and/or modify

runestone/assignment/toctree.rst

Lines changed: 4 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,7 @@
1-
*************************************************
2-
Accessibility
3-
*************************************************
1+
**************************************************
2+
Assignment - directives for creating an assignment
3+
**************************************************
44
.. toctree::
55
:maxdepth: 1
6-
:glob:
76

8-
*.py
9-
js/*.js
10-
css/*.css
11-
test/test_*.py
7+
__init__.py

runestone/blockly/toctree.rst

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
1-
*************************************************
2-
Accessibility
3-
*************************************************
1+
********************************************************
2+
Blockly - Embed block-based code generation in Runestone
3+
********************************************************
4+
Warning: This component is deprecated. Do not use it in new books.
5+
46
.. toctree::
57
:maxdepth: 1
68
:glob:
79

10+
README
811
*.py
9-
js/*.js
10-
css/*.css
11-
test/test_*.py

runestone/fitb/fitb.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
# *********
2-
# |docname|
3-
# *********
1+
# ******************************************************************
2+
# |docname| - Provide Sphinx support for fill-in-the-blank questions
3+
# ******************************************************************
44
#
55
# .. Copyright (C) 2013 Bradley N. Miller
66
#

runestone/fitb/js/fitb.js

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -199,7 +199,9 @@ export default class FITB extends RunestoneBase {
199199
// Grade locally if we can't ask the server to grade.
200200
if (this.feedbackArray) {
201201
this.evaluateAnswers();
202-
this.renderFeedback();
202+
if (!this.isTimed) {
203+
this.renderFeedback();
204+
}
203205
}
204206
}
205207

@@ -234,7 +236,9 @@ export default class FITB extends RunestoneBase {
234236
this.correct = data.correct;
235237
this.displayFeed = data.displayFeed;
236238
this.isCorrectArray = data.isCorrectArray;
237-
this.renderFeedback();
239+
if (!this.isTimed) {
240+
this.renderFeedback();
241+
}
238242
}
239243
return data;
240244
}

runestone/lp/lp_common_lib.py

Lines changed: 10 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -16,18 +16,22 @@
1616
import os.path
1717

1818

19-
# Given a file, return the inline comment token based on the file extension.
19+
# Given a file, return the inline comment token based on the file extension. Default to an empty string if we can't find the the provided language.
2020
def commentForExt(file_name):
2121
return {
22-
".py": "# ",
2322
".c": "// ",
23+
".css": "/* ", # Will need some hand editing...
2424
".h": "// ",
25+
".ini": "; ",
2526
".js": "// ",
26-
".s": "; ",
27+
".py": "# ",
28+
# Rust.
29+
".rs": "// ",
2730
".rst": "",
28-
".css": "/* ", # Will need some hand editing...
29-
".ini": "; ",
30-
}[os.path.splitext(file_name)[1]]
31+
".s": "; ",
32+
# ARM assembly.
33+
".S": "@ ",
34+
}.get(os.path.splitext(file_name)[1], "")
3135

3236

3337
# Relative to the Sphinx output directory, the path to student source (which has all feedback and code solutions removed).

runestone/mchoice/assess.py

Lines changed: 19 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -85,15 +85,25 @@ def run(self):
8585

8686

8787
class QuestionNumber(RunestoneDirective):
88-
"""Set Parameters for Question Numbering
89-
.. qnum::
90-
'prefix': character prefix before the number
91-
'suffix': character prefix after the number
92-
'start': start numbering with this value
93-
94-
.. qnum::
95-
:prefix: turtle-
96-
:start: 10
88+
"""
89+
Set Parameters for Question Numbering:
90+
91+
.. code-block:: rst
92+
:linenos:
93+
94+
.. qnum::
95+
'prefix': character prefix before the number
96+
'suffix': character prefix after the number
97+
'start': start numbering with this value
98+
99+
For example:
100+
101+
.. code-block:: rst
102+
:linenos:
103+
104+
.. qnum::
105+
:prefix: turtle-
106+
:start: 10
97107
"""
98108

99109
required_arguments = 0
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
*************************************************
2+
Dynamic Questions
3+
*************************************************
4+
See the `overview book <https://runestone.academy/runestone/books/published/overview/Containers/dynamic.html>`_ for user documentation.
5+
6+
.. toctree::
7+
:maxdepth: 1
8+
:glob:
9+
10+
*.py
11+
js/*.js
12+
css/*.css

0 commit comments

Comments
 (0)