{"id":20448534,"url":"https://github.com/datacamp/pythonwhat","last_synced_at":"2025-04-13T02:10:39.700Z","repository":{"id":44645386,"uuid":"51361383","full_name":"datacamp/pythonwhat","owner":"datacamp","description":"Verify Python code submissions and auto-generate meaningful feedback messages.","archived":false,"fork":false,"pushed_at":"2025-03-28T16:13:06.000Z","size":3298,"stargazers_count":72,"open_issues_count":39,"forks_count":31,"subscribers_count":29,"default_branch":"master","last_synced_at":"2025-04-04T05:05:33.355Z","etag":null,"topics":["feedback-system","fs","le","learn","learn-squad"],"latest_commit_sha":null,"homepage":"http://pythonwhat.readthedocs.io/","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"agpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/datacamp.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2016-02-09T10:53:56.000Z","updated_at":"2025-03-28T16:09:21.000Z","dependencies_parsed_at":"2024-12-11T08:03:27.862Z","dependency_job_id":"945bf0b8-e704-408f-9de8-ecad46ecbf58","html_url":"https://github.com/datacamp/pythonwhat","commit_stats":{"total_commits":780,"total_committers":15,"mean_commits":52.0,"dds":0.7384615384615385,"last_synced_commit":"44805725bdeaf7d8d1843d1058387eb10ac521da"},"previous_names":[],"tags_count":104,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/datacamp%2Fpythonwhat","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/datacamp%2Fpythonwhat/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/datacamp%2Fpythonwhat/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/datacamp%2Fpythonwhat/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/datacamp","download_url":"https://codeload.github.com/datacamp/pythonwhat/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248654090,"owners_count":21140236,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["feedback-system","fs","le","learn","learn-squad"],"created_at":"2024-11-15T10:35:37.000Z","updated_at":"2025-04-13T02:10:39.681Z","avatar_url":"https://github.com/datacamp.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# pythonwhat\n\n[![Build Status](https://travis-ci.org/datacamp/pythonwhat.svg?branch=master)](https://travis-ci.org/datacamp/pythonwhat)\n[![PyPI version](https://badge.fury.io/py/pythonwhat.svg)](https://badge.fury.io/py/pythonwhat)\n[![Documentation Status](https://readthedocs.org/projects/pythonwhat/badge/?version=stable)](http://pythonwhat.readthedocs.io/en/stable/?badge=stable)\n[![FOSSA Status](https://app.fossa.io/api/projects/git%2Bgithub.com%2Fdatacamp%2Fpythonwhat.svg?type=shield)](https://app.fossa.io/projects/git%2Bgithub.com%2Fdatacamp%2Fpythonwhat?ref=badge_shield)\n\nVerify 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.\n\n- New to teaching on DataCamp? Check out https://instructor-support.datacamp.com\n- To learn what SCTs are and how they work, visit [this article](https://instructor-support.datacamp.com/courses/course-development/submission-correctness-tests) specifically.\n- For a complete overview of all functionality inside pythonwhat and articles about what to use when, consult https://pythonwhat.readthedocs.io.\n\n## Installation\n\n```bash\n# latest stable version from PyPi\npip install pythonwhat\n\n# latest development version from GitHub\npip install git+https://github.com/datacamp/pythonwhat\n```\n\n## Demo\n\nTo experiment locally, you can use `setup_state()` and write SCTs interactively.\nThe code throws an error when the underlying checks fail.\n\n```python\n# make all checking functions available\nfrom pythonwhat.test_exercise import prep_context\n_, ctxt = prep_context()\nglobals().update(ctxt)\n\n# initialize state with student and solution submission\nfrom pythonwhat.test_exercise import setup_state\nsetup_state(stu_code = \"x = 5\", sol_code = \"x = 4\")\n\nEx().check_object('x')\n# No error: x is defined in both student and solution process\n\nEx().check_object('x').has_equal_value()\n# TestFail: Did you correctly define the variable `x`? Expected `4`, but got `5`.\n\n# Debugging state\nEx()._state               # access state object\ndir(Ex()._state)          # list all elements available in the state object\nEx()._state.student_code  # access student_code of state object\n```\n\nTo learn how to include an SCT in a DataCamp course, visit https://instructor-support.datacamp.com.\n\n## Run tests\n\n```bash\npyenv local 3.9.6\npip3.9 install -r requirements-test.txt\npip3.9 install -e .\npytest\n```\n\n## Contributing\n\nBugs? Questions? Suggestions? [Create an issue](https://github.com/datacamp/pythonwhat/issues/new), or [contact us](mailto:content-engineering@datacamp.com)!\n\n\n## License\n\n[![FOSSA Status](https://app.fossa.io/api/projects/git%2Bgithub.com%2Fdatacamp%2Fpythonwhat.svg?type=large)](https://app.fossa.io/projects/git%2Bgithub.com%2Fdatacamp%2Fpythonwhat?ref=badge_large)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdatacamp%2Fpythonwhat","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdatacamp%2Fpythonwhat","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdatacamp%2Fpythonwhat/lists"}