PyKubeGrader 0.1.15__tar.gz → 0.1.16__tar.gz
Sign up to get free protection for your applications and to get access to all the features.
- {pykubegrader-0.1.15/src/PyKubeGrader.egg-info → pykubegrader-0.1.16}/PKG-INFO +1 -1
- {pykubegrader-0.1.15 → pykubegrader-0.1.16/src/PyKubeGrader.egg-info}/PKG-INFO +1 -1
- {pykubegrader-0.1.15 → pykubegrader-0.1.16}/src/pykubegrader/initialize.py +1 -0
- {pykubegrader-0.1.15 → pykubegrader-0.1.16}/src/pykubegrader/widgets_base/multi_select.py +12 -1
- {pykubegrader-0.1.15 → pykubegrader-0.1.16}/src/pykubegrader/widgets_base/select.py +3 -12
- {pykubegrader-0.1.15 → pykubegrader-0.1.16}/.coveragerc +0 -0
- {pykubegrader-0.1.15 → pykubegrader-0.1.16}/.github/workflows/main.yml +0 -0
- {pykubegrader-0.1.15 → pykubegrader-0.1.16}/.gitignore +0 -0
- {pykubegrader-0.1.15 → pykubegrader-0.1.16}/.readthedocs.yml +0 -0
- {pykubegrader-0.1.15 → pykubegrader-0.1.16}/AUTHORS.rst +0 -0
- {pykubegrader-0.1.15 → pykubegrader-0.1.16}/CHANGELOG.rst +0 -0
- {pykubegrader-0.1.15 → pykubegrader-0.1.16}/CONTRIBUTING.rst +0 -0
- {pykubegrader-0.1.15 → pykubegrader-0.1.16}/LICENSE.txt +0 -0
- {pykubegrader-0.1.15 → pykubegrader-0.1.16}/README.rst +0 -0
- {pykubegrader-0.1.15 → pykubegrader-0.1.16}/docs/Makefile +0 -0
- {pykubegrader-0.1.15 → pykubegrader-0.1.16}/docs/_static/Drexel_blue_Logo_square_Dark.png +0 -0
- {pykubegrader-0.1.15 → pykubegrader-0.1.16}/docs/_static/Drexel_blue_Logo_square_Light.png +0 -0
- {pykubegrader-0.1.15 → pykubegrader-0.1.16}/docs/_static/custom.css +0 -0
- {pykubegrader-0.1.15 → pykubegrader-0.1.16}/docs/authors.rst +0 -0
- {pykubegrader-0.1.15 → pykubegrader-0.1.16}/docs/changelog.rst +0 -0
- {pykubegrader-0.1.15 → pykubegrader-0.1.16}/docs/conf.py +0 -0
- {pykubegrader-0.1.15 → pykubegrader-0.1.16}/docs/contributing.rst +0 -0
- {pykubegrader-0.1.15 → pykubegrader-0.1.16}/docs/index.rst +0 -0
- {pykubegrader-0.1.15 → pykubegrader-0.1.16}/docs/license.rst +0 -0
- {pykubegrader-0.1.15 → pykubegrader-0.1.16}/docs/readme.rst +0 -0
- {pykubegrader-0.1.15 → pykubegrader-0.1.16}/docs/requirements.txt +0 -0
- {pykubegrader-0.1.15 → pykubegrader-0.1.16}/examples/.responses.json +0 -0
- {pykubegrader-0.1.15 → pykubegrader-0.1.16}/examples/true_false.ipynb +0 -0
- {pykubegrader-0.1.15 → pykubegrader-0.1.16}/pyproject.toml +0 -0
- {pykubegrader-0.1.15 → pykubegrader-0.1.16}/setup.cfg +0 -0
- {pykubegrader-0.1.15 → pykubegrader-0.1.16}/setup.py +0 -0
- {pykubegrader-0.1.15 → pykubegrader-0.1.16}/src/PyKubeGrader.egg-info/SOURCES.txt +0 -0
- {pykubegrader-0.1.15 → pykubegrader-0.1.16}/src/PyKubeGrader.egg-info/dependency_links.txt +0 -0
- {pykubegrader-0.1.15 → pykubegrader-0.1.16}/src/PyKubeGrader.egg-info/entry_points.txt +0 -0
- {pykubegrader-0.1.15 → pykubegrader-0.1.16}/src/PyKubeGrader.egg-info/not-zip-safe +0 -0
- {pykubegrader-0.1.15 → pykubegrader-0.1.16}/src/PyKubeGrader.egg-info/requires.txt +0 -0
- {pykubegrader-0.1.15 → pykubegrader-0.1.16}/src/PyKubeGrader.egg-info/top_level.txt +0 -0
- {pykubegrader-0.1.15 → pykubegrader-0.1.16}/src/pykubegrader/__init__.py +0 -0
- {pykubegrader-0.1.15 → pykubegrader-0.1.16}/src/pykubegrader/build/api_notebook_builder.py +0 -0
- {pykubegrader-0.1.15 → pykubegrader-0.1.16}/src/pykubegrader/build/build_folder.py +0 -0
- {pykubegrader-0.1.15 → pykubegrader-0.1.16}/src/pykubegrader/log_parser/parse.ipynb +0 -0
- {pykubegrader-0.1.15 → pykubegrader-0.1.16}/src/pykubegrader/log_parser/parse.py +0 -0
- {pykubegrader-0.1.15 → pykubegrader-0.1.16}/src/pykubegrader/telemetry.py +0 -0
- {pykubegrader-0.1.15 → pykubegrader-0.1.16}/src/pykubegrader/utils.py +0 -0
- {pykubegrader-0.1.15 → pykubegrader-0.1.16}/src/pykubegrader/validate.py +0 -0
- {pykubegrader-0.1.15 → pykubegrader-0.1.16}/src/pykubegrader/widgets/__init__.py +0 -0
- {pykubegrader-0.1.15 → pykubegrader-0.1.16}/src/pykubegrader/widgets/multiple_choice.py +0 -0
- {pykubegrader-0.1.15 → pykubegrader-0.1.16}/src/pykubegrader/widgets/reading_question.py +0 -0
- {pykubegrader-0.1.15 → pykubegrader-0.1.16}/src/pykubegrader/widgets/select_many.py +0 -0
- {pykubegrader-0.1.15 → pykubegrader-0.1.16}/src/pykubegrader/widgets/student_info.py +0 -0
- {pykubegrader-0.1.15 → pykubegrader-0.1.16}/src/pykubegrader/widgets/style.py +0 -0
- {pykubegrader-0.1.15 → pykubegrader-0.1.16}/src/pykubegrader/widgets/true_false.py +0 -0
- {pykubegrader-0.1.15 → pykubegrader-0.1.16}/src/pykubegrader/widgets/types_question.py +0 -0
- {pykubegrader-0.1.15 → pykubegrader-0.1.16}/src/pykubegrader/widgets_base/__init__.py +0 -0
- {pykubegrader-0.1.15 → pykubegrader-0.1.16}/src/pykubegrader/widgets_base/reading.py +0 -0
- {pykubegrader-0.1.15 → pykubegrader-0.1.16}/tests/conftest.py +0 -0
- {pykubegrader-0.1.15 → pykubegrader-0.1.16}/tests/import_test.py +0 -0
- {pykubegrader-0.1.15 → pykubegrader-0.1.16}/tox.ini +0 -0
@@ -50,6 +50,7 @@ def initialize_assignment(
|
|
50
50
|
update_responses(key="assignment", value=name)
|
51
51
|
update_responses(key="jhub_user", value=jhub_user)
|
52
52
|
|
53
|
+
# TODO: Check whether this is called correctly
|
53
54
|
log_variable("Student Info", jhub_user, seed)
|
54
55
|
|
55
56
|
responses = ensure_responses()
|
@@ -34,6 +34,8 @@ class MultiSelectQuestion:
|
|
34
34
|
self.question_number = question_number
|
35
35
|
self.style = style
|
36
36
|
|
37
|
+
self.true_keys = keys # Debugging; update later
|
38
|
+
|
37
39
|
flat_index = 0
|
38
40
|
self.keys: list[str] = []
|
39
41
|
for i, _ in enumerate(keys):
|
@@ -79,9 +81,11 @@ class MultiSelectQuestion:
|
|
79
81
|
def submit(self, _) -> None:
|
80
82
|
responses_flat: list[bool] = []
|
81
83
|
self.responses_nested: list[list[bool]] = []
|
84
|
+
self.names_nested: list[list[str]] = [] # Debugging; update later
|
82
85
|
|
83
86
|
for row in self.widgets:
|
84
|
-
next_selections = []
|
87
|
+
next_selections: list[bool] = []
|
88
|
+
next_names: list[str] = [] # Debugging; update later
|
85
89
|
|
86
90
|
for widget in row.objects:
|
87
91
|
# Skip HTML widgets
|
@@ -90,10 +94,13 @@ class MultiSelectQuestion:
|
|
90
94
|
|
91
95
|
if isinstance(widget, pn.widgets.Checkbox):
|
92
96
|
next_selections.append(widget.value)
|
97
|
+
if widget.value:
|
98
|
+
next_names.append(widget.name) # Debugging; update later
|
93
99
|
responses_flat.append(widget.value) # For flat list of responses
|
94
100
|
|
95
101
|
# Append all responses for this widget at once, forming a list of lists
|
96
102
|
self.responses_nested.append(next_selections)
|
103
|
+
self.names_nested.append(next_names) # Debugging; update later
|
97
104
|
|
98
105
|
self.record_responses(responses_flat)
|
99
106
|
|
@@ -101,6 +108,10 @@ class MultiSelectQuestion:
|
|
101
108
|
for key, value in zip(self.keys, responses_flat):
|
102
109
|
update_responses(key, value)
|
103
110
|
|
111
|
+
# Debugging; update later
|
112
|
+
for k, v in zip(self.true_keys, self.names_nested):
|
113
|
+
update_responses(k, v)
|
114
|
+
|
104
115
|
self.submit_button.name = "Responses Submitted"
|
105
116
|
time.sleep(1)
|
106
117
|
self.submit_button.name = "Submit"
|
@@ -7,7 +7,7 @@ from ..telemetry import ensure_responses, update_responses
|
|
7
7
|
from ..utils import shuffle_questions
|
8
8
|
from ..widgets.style import drexel_colors
|
9
9
|
|
10
|
-
# Pass
|
10
|
+
# Pass custom CSS to Panel
|
11
11
|
pn.extension(design="material", global_css=[drexel_colors])
|
12
12
|
|
13
13
|
|
@@ -39,7 +39,7 @@ class SelectQuestion:
|
|
39
39
|
"You must submit your student info before starting the exam"
|
40
40
|
)
|
41
41
|
|
42
|
-
# Dynamically
|
42
|
+
# Dynamically assign attributes based on keys, with default values from responses
|
43
43
|
for key in self.keys:
|
44
44
|
setattr(self, key, responses.get(key, None))
|
45
45
|
|
@@ -71,19 +71,10 @@ class SelectQuestion:
|
|
71
71
|
for key, value in selections.items():
|
72
72
|
update_responses(key, value)
|
73
73
|
|
74
|
+
# Temporarily change button text to indicate submission
|
74
75
|
self.submit_button.name = "Responses Submitted"
|
75
76
|
time.sleep(1)
|
76
77
|
self.submit_button.name = "Submit"
|
77
78
|
|
78
|
-
# # Display the message with a unique display_id
|
79
|
-
# display_id = "temp_message"
|
80
|
-
# display("Responses recorded successfully", display_id=display_id)
|
81
|
-
|
82
|
-
# # Wait for 1 second
|
83
|
-
# time.sleep(1)
|
84
|
-
|
85
|
-
# # Update the display with an empty string to clear it
|
86
|
-
# update_display('', display_id=display_id)
|
87
|
-
|
88
79
|
def show(self):
|
89
80
|
return self.layout
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|