Adding Support for other programming languages

Adding Support for other programming languages

by Howdududu ? -
Number of replies: 3

Hi,

We are creating a pre-onboarding platform for our organization and are using VPL for assignment evaluation. Wanted to know how I can add unavailable languages like Ruby or Oracle db. Can I even evaluate multiple languages in a single program. Is creating a VM the correct way to execute it? Can I create evaluation scripts directly in the plugin to achieve the same or web services would be a solution. Any instruction documentation would be great.

Average of ratings: -
In reply to Howdududu ?

Re: Adding Support for other programming languages

by Juan Carlos Rodríguez-del-Pino -
Picture of Particularly helpful Moodlers Picture of Plugin developers
  • Q1 Wanted to know how I can add unavailable languages like Ruby or Oracle db.
  • A1 You can install the compiler/interpreter into your execution server and write an execution script. You can know the available languages by creating a file with ".all" extension and running it.
  • Due that VPL is a stateless execution system, may be difficult to develop scripts to execute Oracle queries inside VPL due to the need of keeping Oracle security/passwords and its and own users.
  • Q2 Can I even evaluate multiple languages in a single program. Is creating a VM the correct way to execute it?
  • A2 The I/O test system is independent of the programming language. The system detects the language used based on the filename extensión. If you want the student to write a program using a mix of languages you need to write your own scripts.
  • Q3 Can I create evaluation scripts directly in the plugin to achieve the same or web services would be a solution.
  • A3 Yes, you can customize the system. But notice that all executions will be done in the execution server.
  • Q4 Any instruction documentation would be great.
  • A4 Sorry for the poor documentation. You may search for similar questions in the old forum. https://moodle.org/mod/forum/discuss.php?d=154988


Best regards,

Juan Carlos.
Average of ratings: Useful (1)
In reply to Juan Carlos Rodríguez-del-Pino

Re: Adding Support for other programming languages

by Howdududu ? -
Thank you for your reply.
Wanted to know if there are any examples or demonstrated steps to install unavailable languages in vpl.
In reply to Howdududu ?

Re: Adding Support for other programming languages

by Juan Carlos Rodríguez-del-Pino -
Picture of Particularly helpful Moodlers Picture of Plugin developers

You can review the supported language scripts ([lang]_run.sh)  at 

https://github.com/jcrodriguez-dis/moodle-mod_vpl/tree/v3.3.8/jail/default_scripts

These scripts check, compile or prepare the source code to be run. Their aim is to generate the programs/script named vpl_execution or vpl_wexection that really will be run.


Notice that to customize an activity you must go to "advanced features"> "execution files" and write your own vpl_run.sh script, the system will use your vpl_run.sh for your activity instead of any [lang]_run.sh applicable. To easily replicating customization you may go to "execution option" and use the "based on" feature ".


Best regards,

Juan Carlos.

Average of ratings: Useful (1)