All Projects → datacamp → pythonwhat

datacamp / pythonwhat

Licence: AGPL-3.0 license
Verify Python code submissions and auto-generate meaningful feedback messages.

Programming Languages

python
139335 projects - #7 most used programming language
Makefile
30231 projects

Projects that are alternatives of or similar to pythonwhat

testwhat
Write Submission Correctness Tests for R exercises
Stars: ✭ 32 (-41.82%)
Mutual labels:  fs, le
vue-fs
A Vue file management client, complete with a node/express/FS backend.
Stars: ✭ 40 (-27.27%)
Mutual labels:  fs
MeowDB.js
Database in JSON (Node.JS Library)
Stars: ✭ 12 (-78.18%)
Mutual labels:  fs
Minis
Mini Projects in some languages . Good for beginners and for Pull Requests !
Stars: ✭ 16 (-70.91%)
Mutual labels:  learn
trezorLuks
A wrapper around "cryptsetup" to use a key from a Trezor device instead of a password
Stars: ✭ 20 (-63.64%)
Mutual labels:  fs
is-directory
Extends `stats.isDirectory()`, returns `true` if a filepath is a directory.
Stars: ✭ 28 (-49.09%)
Mutual labels:  fs
zAnalysis
zAnalysis是基于Pascal语言编写的大型统计学开源库
Stars: ✭ 52 (-5.45%)
Mutual labels:  learn
pate
Modern and light-fast CLI app that scans all the desired files of a certain folder and returns a list with the name of the files which contain a certain RegEx pattern
Stars: ✭ 23 (-58.18%)
Mutual labels:  fs
diwa
A Deliberately Insecure Web Application
Stars: ✭ 32 (-41.82%)
Mutual labels:  learn
node-fs
node-fs
Stars: ✭ 55 (+0%)
Mutual labels:  fs
sandboxed-fs
Sandboxed Wrapper for Node.js File System API
Stars: ✭ 41 (-25.45%)
Mutual labels:  fs
glob-fs
file globbing for node.js. speedy and powerful alternative to node-glob. This library is experimental and does not work on windows!
Stars: ✭ 54 (-1.82%)
Mutual labels:  fs
Awesome Python Scripts
🚀 Curated collection of Awesome Python Scripts which will make you go wow. Dive into this world of 360+ scripts. Feel free to contribute. Show your support by ✨this repository.
Stars: ✭ 198 (+260%)
Mutual labels:  learn
godot recipes
Lessons, tutorials, and guides for game development using the Godot game engine.
Stars: ✭ 135 (+145.45%)
Mutual labels:  learn
fs
Reactive filesystem powered by @vue/reactivity
Stars: ✭ 45 (-18.18%)
Mutual labels:  fs
app
Feedback collecting web service.
Stars: ✭ 40 (-27.27%)
Mutual labels:  feedback-system
awesome-course
Create awesome courses that let your audience learn by coding ⌨️
Stars: ✭ 224 (+307.27%)
Mutual labels:  learn
home
厦门大学攻略大全 Import files, learning materials and useful links of XMU to help XMUers live and learn better.
Stars: ✭ 67 (+21.82%)
Mutual labels:  learn
azureselected
Azure Selected content localization.
Stars: ✭ 17 (-69.09%)
Mutual labels:  learn
dev doctor
Free, opensource, serverless learning platform
Stars: ✭ 34 (-38.18%)
Mutual labels:  learn

pythonwhat

Build Status PyPI version Documentation Status FOSSA Status

Verify Python code submissions and auto-generate meaningful feedback messages. Originally developed for Python exercises on DataCamp for so-called Submission Correctness Tests, but can also be used independently.

Installation

# latest stable version from PyPi
pip install pythonwhat

# latest development version from GitHub
pip install git+https://github.com/datacamp/pythonwhat

Demo

To experiment locally, you can use setup_state() and write SCTs interactively. The code throws an error when the underlying checks fail.

# make all checking functions available
from pythonwhat.test_exercise import prep_context
_, ctxt = prep_context()
globals().update(ctxt)

# initialize state with student and solution submission
from pythonwhat.test_exercise import setup_state
setup_state(stu_code = "x = 5", sol_code = "x = 4")

Ex().check_object('x')
# No error: x is defined in both student and solution process

Ex().check_object('x').has_equal_value()
# TestFail: Did you correctly define the variable `x`? Expected `4`, but got `5`.

# Debugging state
Ex()._state               # access state object
dir(Ex()._state)          # list all elements available in the state object
Ex()._state.student_code  # access student_code of state object

To learn how to include an SCT in a DataCamp course, visit https://instructor-support.datacamp.com.

Run tests

pyenv local 3.9.6
pip3.9 install -r requirements.txt
pip3.9 install -e .
pytest

Contributing

Bugs? Questions? Suggestions? Create an issue, or contact us!

License

FOSSA Status

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].