google / google/codeworld

Better documented and clean debugger API and UI for CodeWorld programs

Open
#695 1 comment 1 reaction 0 assignees View on GitHub
discussion
Dominant language
Haskell
Stars
1.3k
Forks
201
PR merge metrics
No merged PRs in 30d

Description

We currently have a haphazard collection of debugging features in CodeWorld. These fall into two basic categories: the inspect window, and the on-screen controls. Both of these are powerful, but they follow completely different design choices, and have two different UI and API systems. This adds too much complexity, both for the user, and in the code.

* The inspect window UI is implemented in JavaScript, and communicates with the running program via a set of callbacks and global functions set up in JavaScript. It's implemented inside of `runInspect`, and generalizes the standard CodeWorld model with arbitrary event delivery so it can talk to the JavaScript UI.
* The on-screen controls are implemented entirely in Haskell with the CodeWorld API. They wrap the underlying program so that the entire program, including debugging, acts like a single CodeWorld program.

Ideally, the entire debugging UI would be implemented in one place -- most likely, in JavaScript and DOM since it's a more powerful UI system. There would be a single API based on message passing that's implemented in a generic way and documented so that it's easy to develop against.

(@kammitama5: Don't worry, this is a long-term goal. The current system is fine for now, and you should keep developing with it for Summer of Code.)

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.