Virtual Programming Lab

Activities ::: mod_vpl
Maintained by Juan Carlos Rodríguez-del-Pino
VPL is an activity module to manage programming assignments

Virtual Programming Lab 3.4.3+

Moodle 3.5, 3.6, 3.7, 3.8, 3.9, 3.10, 3.11
Released: Wednesday, May 26, 2021, 2:22 AM

Release of VPL 3.4.3+

VPL Logo

Build Status

This is the update of VPL 3.4.3 to support Moodle 3.11 by replacing obsolete functions and i18n strings. This update does not include fixes or new features.


  • Moodle 3.5 or higher
  • PHP 7.2 or higher

New features of VPL 3.4

General functionalities

  • Supports the General Data Protection Regulation (GDPR)
  • To protect you from accidentally lost work when saving files, the system now asks for confirmation when you want to save a submission or configuration older than the current saved.
  • Adds Chinese (simplified) translation thanks to the Computer Science Education group of Beijing Technology and Business University
  • To improve the identification of directories when downloading student's submissions add the username field to the user directory name.


  • Icons have been added to easier access to menus and options.
  • Users can select themes for the editor and terminal.
  • Terminal can be size reduced.
  • Edition is available when running.
  • The "Submissions list" now includes an "action menu" to the right of each row. The "action menu" of the heading allows accessing "Assessment report", "Download submissions", etc. The "action menu" of each submission allows access to "Submission view", "Previous submissions list", "Grade" and "Copy submission".
  • The variation edition interface now allows using the HTML editor.
  • Charts are now using the new Moodle API.

Programming languages

  • Adds support for Kotlin adding a default run script. Kotlin is detected when using files with the kt file extension. Notice that the Jail servers do not support Snap packages, you must install Kotlin compiler manually or use jail server installer 2.7 or higher.
  • Adds support for Minizinc adding a default run script. Minizinc is detected when using files with the mzn file extension.
  • Adds support for Groovy adding a default run script. Groovy is detected when using files with the groovy file extension.
  • Adds support for error messages from PHP and Perl.
  • Adds new indexes to speedup DB access.
  • Adds 'dll' extension to the list of binary file extensions.

Updating from versions previous

  • VPL 3.4 is fully compatible with previous versions. For versions previous to VPL 3.3 see also V3.3 release note.
  • Notice that in some cases, after the upgrade, the browser may not show the editor. Often, this is due to the browser cache system, leading to still use the old code, instead of the new one. To resolve this issue, you must hold the Ctrl key and click the Reload button on the navigation toolbar. This action will instruct the browser to fully reload the page, updating the cache.

Fixes and improves from version 3.4.2

  • Fixes output type regular expression processing that avoids using '/' inside regular expressions.
  • Fixes regular expression that avoids showing the full compilation result when "running".
  • Adds icons to activity description.
  • Removes hiding the evaluation action to teachers.
  • Replaces obsolete function print_error.
  • Avoid updating from no version. No action taken if the previous version number equals '0'.
  • Adds the 'he' language code conversion from Moodle to Linux locale.

Fixes from 3.4.1

  • Fixes spurious problem loading VNC code that avoids showing the editor.
  • Reverts to previous behavior allowing non-alphanum chars in variation identification field.
  • Fixes bug in variations logging
  • Fixes import and drag and drop files on the editor

Fixes from 3.4.0

  • Fixes a bug that prevents teachers from downloading all students' submissions as a zip file.

Fixes from 3.3.8

  • The teachers with privileges can see the Jail server URL path, now the path is not shown.
  • Detects if ws/wss protocol is not available at jail server to selects the correct one.
  • Fixes error deleting variations.
  • Avoid assigning variations on group activity.

From VPL 3.3.8

  • Cron. The cron function is deprecated and has been replaced with a cron task.
  • Similarity. This version resolves bugs in the normalization phase of code tokenizer of C, Java, and Python languages. Thanks to LennardF1989 at Github.
  • Logs. This version resolves a bug in the URL in Logs. Thanks to Leônidas Brandão at Moodle.
  • Submissions. This version resolves a bug in sharing the same files in different submissions that avoid sharing the first file.

From VPL 3.3.7

The bugs fixed and features improve are:

  • Gradebook. The patch removes ghost empty grades appearing in the gradebook.
  • Navigation. The action menu now appears in many of the activity settings.
  • Non-editing teacher role. The patch fixes the allowed functionalities for the "non-editing teacher" role. If you are updating VPL from a previous version to 3.3.6, you must edit the definition of the "non-editing teacher" role setting the "Allow" value at the capability "mod/vpl:submit".
  • Activity grade report. The grade reports Improve showing also the automatic evaluation.
  • Similarity. The patch fixes the similarity search in group activities.
  • Default evaluation program. The patch removes a compilation warning. The warning is harmless but uglies the evaluation output.
  • Java. The default java scripts improve by searching and add the jar files to the CLASSPATH. This makes easy the use of java frameworks packed as jar files. The 3.3.7 version fixes a regression bug introduced in V3.3.6 with this feature.
  • PHP. The patch fixes the use of the CLI version of PHP. This allows testing PHP programs for the console.
  • Python. The patch fixes the detection and use of the tkinter library.
  • Scala. The patch fixes a bug running scala programs.

From VPL 3.3.5

The main fixes and small features added are:

  • Adds support for MathJax
  • Fixes empty grading problem
  • Fixes maximum similarity background-color
  • Fixes Webservice
  • Adds languages scripts from v3.4dev
  • Fixes evaluation program
  • Improves str i18n with parameter
  • Fixes based-on localjailservers order
  • Increases default memory to 128Mb (if updating, increase it manually)
  • Increases default and maximum number of process to 200 (if updating, increase it manually)

Update notes:

  • It is highly recommended to increase default memory to 128Mb
  • It is highly recommended to increases the default and maximum number of process to 200 and 400
  • If you are getting a hidden menu problem in full window mode. Please, clear your browser cache by doing a hard reload on the editing page. Ctl+Shit+R or Hold Shift and click the Reload button.

From VPL 3.3.4

  • The full regular screen mode has been updated to the new standard Boost theme. The new code has been tested on Boost, Clear, More, and Essential themes.
  • Fixes an error in background-color of similarity report.
  • Tries to reduce terminal high load problem and blinking accuracy.
  • Fixes a bug when resetting VPL instances.
  • Adds check of directory and file creation. The plugin throws an exception if a file or directory cannot be created.
  • Adds PHP file extension to similarity checks. The plugin uses the CPP parser to checks PHP. This is not a full solution, but it is better than nothing.
  • The default running and debugging scripts of many programming languages have been fixes to select the first source file of the submission correctly.

Known issues

  • Has been found a problem with the change of the grade hide/show state. If you hide the grade in the grade book and then unhide the grade in the VPL plugin, the activity grade state is changed to show, but the state for every student grade is still hidden. As a workaround, you can hide/show grades in the grade book or at the activity setting, do not mix this setting.
  • Sometimes the terminal breaks the connection if it receives a huge number of newlines, e.g., running a program with an infinite loop printing newlines.
  • There are some minor problems showing source code files using the Essential theme. These problems are about aesthetic decoration and do not reduce the functionalities.

From VPL 3.3.3

This is a bug fix release of VPL3.3.2. The fixes are:

  • The evaluation process now asks for accepting certificates if the connection fails.
  • Has been fixed a problem with grade form. This problem that appears in some themes and browser combinations leads to a continuous increase in the width of the text area field.
  • Has been fixed a bug in the grade setting update. The problem was that VPL does not change the grade hide/show state. As a workaround, the changes would be done in the grade book.

From VPL 3.3.2

VPL 3.3.2 includes fixes for VPL 3.3 and adds a new feature.

This release fixes a bug that prevents the default evaluation program from using a maximum grade value different than the default (10 ).

Now you can let the system autodetects the programming language to use based on the filenames extension, or you can select the programming language or debugger to use. For example, you can select from python 2 or python 3, C ANSI or C ISO 11, etc.

From VPL 3.3.1.

This release includes fixes for VPL 3.3 and support for the Safe Exam Browser.

The Safe Exam Browser (SEB) allows a controlled environment for exams. VPL activities now can require the use of SEB and/or the use of SEB with specific configuration by the "Browser Exam Key". See

Has been fixes different bugs in the use of “group work” activities introduced in the V3.3. If you are using V3.3 and “group work” it is recommended to upgrade to V3.3.1.

New and improved features in VPL 3.3

Syntax highlighter

The server-based syntax highlighter has been removed, now all syntax highlighting is done in the browser using the Ace editor. This change extends to more than 50 the number of programming languages supported. This improvement also will reduce the CPU load on the server. It has also been developed the syntax highlighter for the test cases definition file.

Code editor

The editor has been updated using the last Ace code. This update will allow using basic autocompleting in all languages, snipes in many, and syntax checking in a few as PHP, JavaScript, and CSS.

  • Now it’s possible to select the editor theme in the plugin setting.
  • The menu has now a button to unfold and fold less used options.
  • Now, it is possible to delete multiple files using the new multi-delete button.
  • Now you can select the code font size. The size selected will be saved as a user preference.
  • The activity description is now shown in a “Description” tab. The student can read the activity description while writing code in one window.
  • The countdown timer can’t be hidden when the time left is less than five minutes.
  • The evaluate button now gives information about the number of automatic evaluations done and the grade reduction definition.

Default evaluation program

The default evaluation program has been improved, trying to accomplish the common requests of the users of VPL. The new instructions are:

  • Fail message. This instruction sets the text to show when the case fails. The input and output information is omitted.
  • Program to run: This instruction allows to replace, for this case, the student’s program for another one. For example, you can use this instruction to run a static/dynamic analysis of the student code.
  • Program arguments. This instruction allows sending information to the student program (or “program to run”) as command-line arguments. Notice that this instruction can be used with the input instruction.
  • Expected exit code. This instruction sets the expected exit code of the program case execution. The test case is passed if the exit code match. Notice that the test case can also be passed if an output matches.

Reducing grading marks by the number of automatic evaluations

The grading system has been enhanced with a penalization by automatic evaluation requests. The number of free evaluations can also be configured. Once the student uses free evaluations, the grading system will start to reduce its current mark. The reduction value can be a fixed number or a percent. Every new evaluation will apply a further reduction to the current grade. These reductions are applied to manual and automatic assessments.

Group/team VPL activities redesigned

The pre v3.3 design of the team’s activities has a different drawback that needs to be resolved. The main problem is that if you change a student group after submissions, the submissions may be moved to another group with the student. In the new design, the submissions belong to the group and not to a student. Now it is safe to remove or add students to a group at any moment, and the submissions will remain in the group. The grade is assigned to the members of the group at the moment of been graded.

Check execution servers

Check execution servers now show the actual servers, including the locals, and based on ones. The report now also shows the list of current processes running in the course.

Diff files

The diff files code has been rewritten to support the Ace editor as the way to show files side by side.

Download submissions

The “download submissions” button has been moved to the “submission list” report. It has been added a new button to download all submissions, including old versions. The zip file format has changed to give more information, including the full name of the student, time of submission, and evaluation details.

Reducing the size of space used by submission

Due to how the submitted files are managed: created or deleted but not modified, this version includes the reuse of files of the previous submission. This is achieved by reusing (linking) files of the last submission with the same contents as new ones.

Using GUI programs

If you are planning to use languages with GUI capabilities as Java, C#, PHP, etc. it is highly recommended to use vncaccel to reduce the start time of the programs (see the release of execution server 2.2.2)

Testing VPL

VPL is now tested using travis-ci. The tests include PHP Lint, PHP Mess Detector, Moodle Code Checker, CSS Lint, JSHint, PHPUnit tests, and specific tests for the default Student's program tester. These tests alone do not correct bugs in the code but are a first step to detect them.


Has been added the Brazilian translation thanks to Gabriel P. Silva UFRJ

Bug fixes

  • Adds timemodified field for compatibility with Moodle.
  • Fixes drop and paste problems.
  • Uses own copy of Jquery and Jquery-UI, this removes version problems.
  • Fixes issues reordering files.
  • Removes for students to view the hints of grade reduction at the end of the title line of grader comments. The students could see clues in HTML before JavaScript processes it.
  • Fixes the problem that avoids saving new submissions when the name of requested files is changed.
  • Has been modified the table vpl_jailservers to remove the key of the server URL. This key with a field of 255 chars generates an error that aborts the installation of VPL due to problems for reaching the limits of key size in MySQL with some charsets.

Updating VPL from a version previous to V3.3

IMPORTANT NOTE!: If you update or restore activities to VPL 3.3 or higher from a previous version and this action include teams’ activities with submissions, you need to go to the list of “Virtual Programming Lab” activities and click on the “Check all” button (at the bottom of the report). This process will assign groups to the submissions.

Version information

Version build number
Version release name
Stable version
MD5 Sum
Supported software
Moodle 3.5, Moodle 3.6, Moodle 3.7, Moodle 3.8, Moodle 3.9, Moodle 3.10, Moodle 3.11
  • Latest release for Moodle 3.5
  • Latest release for Moodle 3.6
  • Latest release for Moodle 3.7
  • Latest release for Moodle 3.8
  • Latest release for Moodle 3.9
  • Latest release for Moodle 3.10
  • Latest release for Moodle 3.11

Version control information

Version control system (VCS)
VCS repository URL
VCS tag

Default installation instructions for plugins of the type Activities

  1. Make sure you have all the required versions.
  2. Download and unpack the module.
  3. Place the folder (eg "assignment") in the "mod" subdirectory.
  4. Visit to finish the installation