Here’s a development update, covering everything that’s changed since November.
Most of my work has been on adding LTI 1.3 support to the Numbas LTI provider. We hope to have that ready to use by the summer, in time for the next academic year.
The rest of the development work has been mainly bug fixes, with a couple of new features in the Numbas runtime.
Numbas runtime
I’ve tagged v7.3 of the Numbas runtime on GitHub.
- Laura added a new JME function
jme_string
to get a string representing any value as JME code. (issue, documentation) - Fixed a bug when automatically converting complex
number
values todecimal
. (code) - Utility functions in the default theme have moved to a new file,
display-util.js
, to reduce duplication of code in the worksheet theme. (code, issue) - The task to build the JME unit tests from the documentation now forces the content to be decoded as utf8, to avoid a bug on Windows. (code)
- On the results page, empty cells are filled in when question scores aren’t shown. (code, issue)
- Fixed a bug in the worksheet theme to restore page breaks. (code)
- The entire sidebar scrolls on short viewports (code)
- When viewing the introduction during the exam, its entry in the sidebar list is marked as “current” to assistive technology. (code)
- The worksheet theme no longer overrides the styling of checkboxes. (code, issue)
- JavaScript:
Numbas
is put in theglobalThis
namespace ifwindow
is undefined. (code) - Worksheet theme: exam intro text uses the full width. (code)
- In printed exams, dropdowns are rendered as a box showing all options. (code, issue)
- In the worksheet theme, the “page break between questions” option applies to answer sheets. (code)
- Improved the implementation of the question CSS preamble so it only applies to that question. (code, issue)
- Values returned by the diagnostic algorithm are automatically cast to the expected types. (code, issue)
- Extension parts have a base marking script, so they can be used to provide parts with marks available but no answer input in worksheet exams. (code)
- Adaptive marking: the warning “part must be answered” is shown in the warnings box. (code, issue)
- There’s new syntax for list comprehensions: a shorthand for
map()
andfilter()
, inspired by Python:expr for: name of: range where: condition
(code, documentation) - List items have a maximum width, to help readability. (code)
- Questions and info pages scroll independently. (code)
- When rewriting unknown function names to multiplication, the system remembers that the “argument” was bracketed. (code, issue)
- The nav bar at the bottom of questions is now inside the question element, so it’s inside the same scrolling context. (code)
siground
rounds to 0 when within1e-15
. (code)- The question preamble can return a promise, which will be awaited. (code, example question)
- There’s a new JavaScript function,
Numbas.jme.makeFast
, which “compiles” a JME expression to a faster plain JavaScript function. The motivation for this was to use it in JSXGraph’s function plotter, which needs to evaluate the function several thousand times per frame. (code) - The routine for remaking variables adaptively, used in adaptive marking and explore mode, deals with destructured variable definitions. (code, issue)
- Stu Wilmur added options to toggle whether questions and advice are shown when printing a finished exam. (code, issue, documentation)
- Fixed a layout bug which made the front page have a horizontal scroll bar. (code)
- Explore mode: when moving back to a part, the view scrolls back to the top. (code, issue)
- The sidebar has a “close” button on narrow screens. (code, issue)
- In order to save space, the suspend data doesn’t wrap numbers in
with_precision()
when they don’t have any precision information. (code) - There’s a new JME function
imprecise(n)
for marking numbers with no precision information. (code) - Fixed a bug in resuming diagnostic mode exams. (code)
- When a part produces no feedback messages, any feedback from previous submissions is removed. (code, issue)
- When “show score feedback icon” is off, only neutral feedback messages are shown. (code, issue)
- I’ve rejigged how warnings are positioned, trying to ensure they appear in the right place without obscuring too much other content. (code)
- The “match choices with answers” grid has striped rows and dashes between columns to improve readability. (code)
- The “mathematical expression” part gives a better error message when the expression can’t be parsed. (code, issue)
- I’ve added a SECURITY file to the repository, describing how to report security vulnerabilities. Thanks to Matheus Alexandre for suggesting this.
GeoGebra extension
- Fixed a typo in an example in the documentation. (code)
JSXGraph extension
- I’ve updated JSXGraph to version 1.7.0 (code, announcement)
- The function plotter uses the new
Numbas.jme.makeFast
function, which is hugely faster. (code)
Polynomials extension
- When rendering a polynomial as LaTeX, the standard routine for representing numbers is used for coefficients and exponents. (code)
Programming extension
- I’ve updated to use WebR version 0.2.1. (code, announcement for 0.2.0, announcement for 0.2.1)
- There’s a new function
Numbas.extensions.programming.preload
to start loading a code runner as soon as the question is generated, instead of waiting for the student to submit an answer. (code, documentation) - The JME value
nothing
is represented in Python asNone
. (code)
Spreadsheets extension
- The spreadsheet is now compiled in production mode, so will be faster and produce no debug information in the console. (code)
- Fixed a bug where parts are incorrectly marked as changed. (code)
- Cells have the
inputmode
attribute set, so mobile devices will use an appropriate keyboard for numeric cells. To make use of this, there’s a new JME functioncell_type
to set the type of cells. (code, documentation) - Number cells with invalid numbers are encoded as
""
instead of"ERR"
. (code) - All cell styles are correctly encoded, so you can display a spreadsheet in part feedback correctly. (code)
Numbas editor
I’ve tagged v7.3 of the Numbas editor on GitHub.
- Only items that the user can view are shown in the “other versions” tab. (code, issue)
- Fixed a bug in the auto-saver, so it only saves 1000ms after the last change. (code, issue)
- In the question editor: if generating variables didn’t finish last time the page was open, they’re not automatically generated. This can help you get back in to fix a question where variable generation hangs. (code, issue)
- Documentation: I’ve added some new items in the “how do I…” page, and documented the spreadsheets extension. (code)
- The question editor now copes with bad variable replacement definitions when loading. (code)
- The code editor highlights JME operator keywords. (code)
- Fixed a security vulnerability in editable packages (themes and extensions): the editor only allows reading or editing files inside the package’s directory. Thanks to Matheus Alexandre for reporting this. (code)
Numbas LTI provider
I’ve tagged v3.5 of the Numbas LTI provider on GitHub.
- The SCORM API sends back times with timezone info. (code, issue)
- An AttemptLaunch is correctly created when the user is anonymous. (code)
- SCORM data is loaded through a background request by the client instead of embedding it in the page. This fixes a problem where the student’s browser would reload the page from its cache, seemingly starting the attempt again from scratch. (code, issue)
- When force-sending SCORM data to the fallback due to the resource becoming unavailable, the attempt is only marked as complete if it really was complete. (code, issue)
- Access changes can override the lockdown app setting. (code, issue, documentation)
- Added a helpful error message which is shown when launching an invalid Safe Exam Browser link. This can happen when re-opening Safe Exam Browser independently after launching it from an LTI link. (code)
I’ve been working on adding support for LTI 1.3 to the Numbas LTI provider. It’s at the point where we’re just about to start testing it in our Canvas environment. We aim to have it in production use by this summer, ready for the next academic year.
If you’d like to test the new version with your learning environment, please email us.