Grading environment with specific Python version in path.
Includes following extra packages:
Images are tagged with Python and grading-base versions in format <Python>-<grading-base>.
Version tag can also include uN meaning update N where N is an increasing number.
The update part is used to indicate updates to the image, where software versions did not change.
For an example, 3.5-2.0u1 includes Python 3.5 on top of grading-base 2.0 and has one update after first release.
Newer tags include the version of Python grader-utils in the middle of the tag.
For example, 3.7-3.3-3.1 includes Python 3.7 and Python grader-utils 3.3 on top of grading-base 3.1.
There is also few additional versions of the image:
math-*includes Python packages matplotlib, scipy, numpy and bokeh on top of the base and in addition, openpyxl, xlrd and xlwt for Excel file parsingml-*includes Python packages pandas, scikit-learn and numpy on top of the math layerjupyter-*includes Python packages nbconvert and ipython on top of the ml layerrdf-*includes Python package rdflib on top of the basexls-*includes Python packages xlrd and xlwt on top of the base for parsing Excel filesply-*includes the Python package PLY (parser and lexer generator)smt-*includes pysmt and dd on top of the ply layery2-*(for the Basic Course in Programming Y2 course) includes Python packages pyqt6, coverage, networkx and pyvirtualdisplay on top of the basemec-*(for the Mechatronic Machine Design course) includes Python packages requests, bs4 and validators on top of the math layerpsql-*includes PostgreSQL server and the Python package psycopg2comp-*(for the Competitive Programming course) includes Python packages requests, bs4, pandas, lxml and html5lib on top of the base
In addition to grading-base, this container provides following utilities.
-
graderutils [--use-iotester] [--use-rpyc] [--novalidate] [--container] [--show-config] [--develop-mode] [--exercise-path <absolute-path>] -- [<test-config-absolute-path>]-
--use-iotesterCreate the necessary directory structure with the correct permissions required by iotester.
-
--use-rpycUse RPyC (Remote Python Call) to import and call student code running in a separate process.
-
--novalidateSkip validation of test config.
-
--containerThis flag can be used when running graderutils inside docker container based on apluslms/grading-base to raise and print exceptions that occur in graderutils itself to stderr (normally not used).
-
--show-configPrint test configuration into warnings.
-
--develop-modeDisplay all unhandled exceptions unformatted. Also implies
--show-config. By default, exceptions related to improperly configured tests are caught and hidden behind a generic error message. This is to prevent unwanted leaking of grader test details, which might reveal e.g. parts of the model solution, if one is used -
--exercise-pathChange the directory where grader tests are run. Default is
/exercise. Personalized programming exercises can set this to/personalized_exercise.
Executes
graderutils.main(orgraderutils.__main__when--use-rpycflag is set) Python module usingcapturewrapper (check grading-base). Provided arguments, except for--use-iotester,--use-rpyc, and--exercise-path, are passed to the Python module. If there are no arguments, then the module is executed with/exercise/test_config.yamlas the first argument. In other words, if you define graderutils configuration intest_config.yaml, you only need to havegraderutilsin the config.yamlcmdfield. -
-
unittestAlias for
python3 -m unittest. Adds/exercisetoPYTHONPATH. -
unittest-captureWrapper around
captureandunittestPython module. Adds/exercisetoPYTHONPATH. Does executeerr-to-outif there is no errors. -
unittest-testcase [-t title] [-p points] [-s skip] [unittest arguments]Wrapper around
testcaseandunittestPython module. Adds/exercisetoPYTHONPATH. Arguments are passed totestcaseand unittest arguments for the Python module. Checktestcasedocumentation in grading-base. -
python-compile-allAlias for
python3 -m compileall. Use it to validate Python syntax of input files before tests. -
run-all-unittests [-S] [-p points_per_test_class]Command to do it all. Can replace
run.shin trivial cases.First, script validates syntax, unless
-Sis provided. If syntax is not valid, no tests are run. Second, script finds all files matching*test*.pypattern from submission and exercise paths. Then, it runs every class that directly inheritsunittest.TestCaseusingtestcaseandunittest. Testcase will givepoints_per_test_classmany points per successful execution of unittest.