Skip to content
epai edited this page Jun 15, 2017 · 6 revisions

Features

ok-client has many features, some of which are designed to work with the corresponding server.

  • Test Unlocking: This is a feature designed to have students think through what the outcome of a test is before they are allowed to use it to test their project solutions
  • Analytics: We collect analytics about the students in each class so staff can figure out how their students are doing. The analytics are on our server.
  • Autograding: We do student side autograding, so that students can see which bugs still lie in their code. In addition, the server supports server side autograding (which runs a grading script you provide) for scoring purposes.
  • Submission downloading from our server, so that you can easily get all student's final submissions for an assignment if desired.
  • The client currently supports multiple languages Python 3, Scheme, SQL and support for other languages can be added.

Installing OK

OK is registered on PyPi, the Python package index. The preferred way to install is using a virtual environment:

  1. Create a virtual environment with virtualenv

  2. Install OK with pip:

     pip install okpy
    

    You can also add okpy in a requirements.txt file with its latest version number. For example, requirements.txt might include this line:

     okpy==v1.3.6
    

    You can then update this version number as necessary and install requirements with

     pip install -r requirements.txt
    

Command line utilities

Installing OK provides a number of command line utilities:

  • ok: runs OK as if it had been compiled. All the options available in the compiled version of OK are also present.
  • ok-publish: compiles a version of OK as a ZIP archive in the current directory. This can be distributed to students. This utility also accepts an optional flag -d DEST, which can be used to specify a destination for the published result -- the default is the current directory.
    • If you get No site packages directory found. abort error, make sure okpy is not installed outside your virtualenv (pip uninstall it if it is).
  • ok-lock: Locks all the tests specified by config.json.

Setting up an assignment

Every assignment requires a file called config.json, which holds information about a particular assignment. See Configuration for more details.

OK is able to handle different types of test formats. See the following for details on each type of test format.

Clone this wiki locally