• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

source-academy / py-slang / 30367171085
86%

Build:
DEFAULT BRANCH: main
Ran 28 Jul 2026 02:29PM UTC
Jobs 1
Files 118
Run time 1min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

28 Jul 2026 02:11PM UTC coverage: 86.159% (+0.02%) from 86.135%
30367171085

push

github

web-flow
Add draw_data builtin (Data Visualizer support) (#365)

* Wire data-visualizer Context plumbing and Python adapter

Adds context.dataVisualizer (typed against the external BaseDataVisualizerRunnerPlugin<Value> abstract base, not the local concrete subclass — matches how conductor/evaluator are already typed by interface). PyCseEvaluatorBase registers PythonDataVisualizerRunnerPlugin and loads its host bundle in the constructor, guarded by variant >= 2 (draw_data doesn't exist as a builtin below that), next to the existing csePlugin registration. evaluateChunk stashes the plugin onto context alongside conductor/evaluator, and resetRun() is called in the same per-run reset block that clears breakpointSteps/changepointSteps.

toDataVisualizerNode.ts is the actual thin adapter: dispatches on Value.type, recurses into list elements, reuses toPythonString (the same stringifier print/repr already use) for leaf/function display values. No cycle-detection or classification here — that's entirely host-side per the shared-logic decision.

Note: @sourceacademy/common-data-visualizer and @sourceacademy/runner-data-visualizer aren't published yet (this PR's sibling work in the plugins repo), so yarn.lock won't actually resolve them until that lands — same bootstrapping situation every cross-repo Conductor dependency in this epic goes through before its own upstream PR merges. Verified locally via a temporary portal: link (not committed).

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_011JmkCBZfioraGKf1tR6K3n

* Add draw_data builtin

DataVisualizerBuiltins.draw_data: @Validate(2, null, ...) matching python_2_specs.md's own documented signature (value1, value2, *values — diverges from js-slang's minimum of 1), calls context.dataVisualizer?.sendDrawing(args) and returns None. Registered as its own GroupName.DATA_VISUALIZER group (mirrors how list/pairmutator/stream are each their own group despite all being lis... (continued)

4428 of 5532 branches covered (80.04%)

Branch coverage included in aggregate %.

27 of 29 new or added lines in 4 files covered. (93.1%)

9590 of 10738 relevant lines covered (89.31%)

179915.99 hits per line

Uncovered Changes

Lines Coverage ∆ File
2
87.5
src/conductor/dataVisualizer/toDataVisualizerNode.ts
Jobs
ID Job ID Ran Files Coverage
1 30367171085.1 28 Jul 2026 02:29PM UTC 118
86.16
GitHub Action Run
Source Files on build 30367171085
  • Tree
  • List 118
  • Changed 2
  • Source Changed 2
  • Coverage Changed 2
Coverage ∆ File Lines Relevant Covered Missed Hits/Line Branch Hits Branch Misses
  • Back to Repo
  • Github Actions Build #30367171085
  • 63acf326 on github
  • Prev Build on main (#30329954597)
  • Next Build on main (#30410611527)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE TRIAL · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc