- VS Code
^1.74.0 - Node.js + npm
- Java and/or Python project/workspace with
.java/.pyfiles
- Clone and enter repo.
- Install dependencies:
npm install
- Compile:
npm run compile
- Launch extension host from VS Code with
F5.
Codescape currently supports two user-visible locations:
- Explorer sidebar view:
- In VS Code explorer, open Codescape City (
codescape.Cityview).
- Editor panel view:
- Run command Create Panel (
codescape.createPanel) from command palette. - This opens a tab titled
Codescape.
Placement options in VS Code:
- Tab: default open behavior.
- Split pane: drag tab or use split editor command.
- Bottom panel: with Codescape tab focused, run View: Move Editor into Panel.
- Building = parsed Java or Python entity (
ClassInfo). - Building height = complexity proxy (
methods + fields, min 1). - Building color = relationship signal (intended UX) and currently implemented as stable per-class palette assignment.
- Related classes = computed in backend (
relations.ts) for incremental updates.
Important current behavior:
- Related classes are computed and sent in
PARTIAL_STATE. - UI currently logs related classes and updates state subsets; dedicated relationship color/highlight encoding is not finalized.
- Zoom in: mouse wheel up.
- Zoom out: mouse wheel down.
- Zoom range:
0.3to3.0. - Pan: not implemented.
- Rotation: not implemented.
Codescape watches **/*.java and **/*.py and sends partial updates:
-
File changed:
- Re-parse file.
- Compute
changed,removed,related. - Broadcast
PARTIAL_STATEto active webviews.
-
File deleted:
- Remove from store.
- Broadcast
PARTIAL_STATEwithremovedclass names.
Create .exclude in workspace root.
Each line is a glob pattern matched with minimatch.
Example:
**/generated/**
**/build/**
**/test/**
Contributed commands (package.json):
codescape.createPanel-> Create Panelcodescape.scan-> Codescape Scan
Runtime-registered internal commands (not contributed in package.json):
codescape.dumpParseStorecodescape.exportParseStore
- Start extension host (
F5). - Open a Java or Python workspace in extension host window.
- Open Codescape via sidebar or
Create Panelcommand. - Edit/save Java or Python files and observe updates.
- Use zoom wheel to inspect layout.
-
City view not updating:
- Confirm the
.javaor.pyfile is not excluded by.exclude. - Check extension host logs for parser errors.
- Confirm the
-
Empty view:
- Verify workspace has Java or Python files.
- Run
codescape.scan(re-parses backend store; current implementation may still require reopening/reloading view to reflect a full-state refresh).
-
Commands missing:
- Recompile (
npm run compile) and relaunch extension host.
- Recompile (
For a known-good visual smoke test, open one of these folders in the extension host:
examples/java-cityexamples/python-city
Both are intentionally small so the generated city stays compact and in view with the current layout algorithm.