testmycode / testmycode/tmc-server
Add support for callback hooks for when submission is graded
Nobody has claimed this yet.
- Dominant language
- Ruby
- Stars
- 51
- Forks
- 42
- Avg merge
- 1h 27m
- Merged PRs (30d)
- 1
Description
Initial draft/idea
Ideally we could have 2 places to list multiple callback urls.
- Per course setting, configured among other course parameters
- Callback url given when submission is created, persisted into db (array?)
And after submission is graded and saved here: https://github.com/testmycode/tmc-server/blob/master/lib/sandbox_results_saver.rb#L59 we would call all of the callback urls provided.
This would make the callbacks to take place during the the http post received from tmc-sandbox, but it shouldn't be a problem tmc-sandbox won't really mind if it takes any longer.
Other option would be to store the callbacks in db and extend the current background tasker to make these callbacks. Eventually this would better allow to retry failing callbacks. But the
Use case
Integration with various services, e.g. A+ and Artos random web apps.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with lib/sandbox_results_saver.rb around line 59, where the submission is graded and saved. Compare the proposed per-course callback setting with callback URLs supplied at submission creation, then resolve whether callbacks run during the HTTP request or through the background tasker; the work is done when both configuration paths and callback execution behavior are defined and implemented.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- ruby
- Domain
- api, backend
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 30/100