tom_d4rt_dcli 2.2.0
tom_d4rt_dcli: ^2.2.0 copied to clipboard
Base D4rt CLI with dcli bridges. Extensible foundation for D4rt tools.
2.2.0 #
Changed — on the interpreter release with per-execution hooks (GitHub #19) #
tom_d4rt ^1.264.0. Embedders get D4rtExecutionHooks (per-execution lifecycle,
entry interception, revocation with drain). The bridges are regenerated by
tom_d4rt_generator 1.66.0: generated proxies enter scripts through
D4.enterInterpreted, and a sub-package barrel registers only the
declarations of its own package.
Name resolution: yes — through tom_d4rt 1.264.0 (aliases whose target is re-exported,
export-only bridged libraries) and the regenerated registration (a
sub-package barrel such as package:dcli_core/dcli_core.dart offers only
that package's declarations).
2.1.0 #
Changed — on the interpreter release for GitHub #13-#18 #
tom_d4rt ^1.263.0. The bridges are regenerated by tom_d4rt_generator 1.65.0,
which decides the relaxer file's types by what its imports export: the
relaxer file (lib/src/bridges/relaxers.b.dart), an empty stub before
because every dcli class has a pub-cache path, now holds the relaxer wrappers
and generic constructor factories for the bridged dcli / path / CLI API
classes.
Name resolution: yes — through tom_d4rt 1.263.0 (an extension member through a prefixed import, a call of an extension's name as an explicit override, an extension setter beside its getter).
2.0.0 #
Changed — dcli is tom_dcli; scripts import package:tom_dcli/dcli.dart #
The dcli corpus is generated from tom_dcli 10.4.7+tom.1, the Tom Framework's
fork of dcli 10.4.7 (https://github.com/al-the-bear/tom_dcli), in place of
dcli. The fork differs from upstream in one thing: Parser.iniDecode() reads
INI files with dcli's own IniConfig instead of the ini package, which is
LGPL-3.0 and whose relinking requirement no compiled Dart program can meet —
the dcli binary built from this package carried it. The change is offered to
upstream dcli.
Breaking for scripts: the corpus is registered under
package:tom_dcli/dcli.dart, so a script imports that URI instead of
package:dcli/dcli.dart. Bridges regenerated by tom_d4rt_generator 1.63.0.
1.16.0 #
Changed — on tom_d4rt 1.257.0, bridges regenerated by tom_d4rt_generator 1.63.0 #
tom_d4rt ^1.257.0 (from ^1.231.1): the regenerated bridges use the
receiver API of tom_d4rt 1.251.0 and later. The bridges come from the generator
release of the same batch: imports through public libraries (GitHub #5),
bounded dispatch (#11), receiver proxies, typed list returns and the
type-argument name rule.
Name resolution: no.
1.15.0 #
Changed — on tom_todo_model 2.0.0 and tom_vscode_scripting_api 4.0.0 (repeated todos) #
tom_todo_model ^2.0.0 and tom_vscode_scripting_api ^4.0.0, up from ^1.3.0
and ^3.0.0. A todo file holding a repeated todo — the waiting-for-repeat
status, a repeat rule, next_repeat, repeat_count — was refused by the
1.x model; scripts now read it. The scripting-API bridges are regenerated:
scripts reach TomTodoRepeat, TomTodoRepeatRule, TomTodoStatus.waitingForRepeat
and TomTodo.repeat / nextRepeat / repeatCount. No bridged class was
removed.
1.14.0 #
Changed — on dcli 10.4 and pubspec_manager ^4 (vstdm12) #
dcli ^10.4.7, dcli_core and dcli_terminal ^10.4.0, and pubspec_manager
^4.1.0, up from dcli ^10.0.0 and pubspec_manager ^3.2.1. Every dcli from
10.1.0 on requires pubspec_manager ^4, so the old pin held every package
depending on this one on dcli 10.0.0, whatever its own dcli floor said. The
dcli bridges are regenerated against 10.4.7: scripts now also reach
CompiledExecutable, PackedResourcePart, PubGetException and PubSpec.
No bridged class was removed.
1.13.0 #
Changed — on tom_d4rt 1.231.1; the D4rt bridge has the async entry points #
The cli_api bridges are regenerated against tom_d4rt 1.231.1, so a script
reaches D4rt.executeAsync, executeAsAsync and executeProgramAsync on a
bridged interpreter. 1.231.1 also keeps the frames of an error raised after an
await.
1.12.1 #
Changed — generated-file headers name tom_d4rt_generator 1.53.0 #
The bridges' // Generated: headers were re-stamped by the published
tom_d4rt_generator 1.53.0 after the 1.12.0 version commit; this release's
version covers that commit. No code changed.
1.12.0 #
Removed — the Telegram bot mode and tom_chattools (vstdm3) #
Same reason and scope as tom_dcli_exec 1.13.0: tom_chattools -> televerse
-> freezed 3.x caps the analyzer at 12, so the Telegram features go to let
this package take tom_d4rt on analyzer 14.
Changed — tom_d4rt 1.230.0, bridges regenerated #
1.11.0 #
Changed — tom_vscode_scripting_api ^3.0.0, bridges regenerated #
tom_vscode_scripting_api is ^3.0.0 (was ^2.0.3). 3.0.0 removes
AiPromptApi and AiConversationApi with their models (AiPromptResult,
ConversationResult, ConversationExchange, …) and the enums
ConversationMode / HistoryMode: the VS Code extension removed the Local LLM
and AI Conversation panels and answered every such call with an error.
tom_vscode_scripting_api_bridges is regenerated, so a script no longer sees
these classes. The hide ConversationExchange clauses go with them: the local
bot-mode ConversationExchange no longer clashes with anything.
1.10.0 #
Changed — tom_todo_model ^1.3.0, bridges regenerated; generator ^1.52.0 #
tom_todo_model is ^1.3.0 (was ^1.2.0). 1.3.0 adds TomTodo.lastAnswer,
the schema's last_answer field, which the VS Code extension writes when a
prompt-queue run completes a todo; an older model reads a todo carrying it as
an unknown key. tom_vscode_scripting_api_bridges is regenerated, so a script
sees TomTodo.lastAnswer as a getter, a setter and a named constructor
parameter;
the bridge reads it, which is why the floor rises.
The tom_d4rt_generator dev floor is ^1.52.0, the release the bridges were
regenerated with.
1.9.0 #
Changed — bridges regenerated against tom_todo_model 1.2.0 and tom_vscode_scripting_api 2.0.3 #
tom_todo_model is now ^1.2.0 (was ^1.0.1) and tom_vscode_scripting_api
^2.0.3 (was ^2.0.0). An older todo model read a todo carrying blocking
(1.2.0) or user_action (1.1.0) as an unknown key, and the VS Code extension
writes blocking on every save of a todo file. tom_vscode_scripting_api_bridges
is regenerated for both, so a script now sees:
TomTodo.blockingandTomTodo.userAction, as getters and as named constructor parameters;LanguageModelCallException, whichLanguageModelChat.sendRequest,countTokensandVSCodeLanguageModel.invokeToolthrow when the window reports a failed call (scripting API 2.0.2);- the optional
timeoutonVSCodeBridgeClient.sendRequest(scripting API 2.0.1).
Both floors are what the regenerated bridge needs: it reads members only those releases have.
tom_chattools is ^1.0.2 (was >=1.0.2, which pub.dev flags for its missing
upper bound); it resolves the same 1.0.2.
1.8.0 #
Changed — the VS Code scripting API's todos are the shared todo model #
Resolves tom_vscode_scripting_api 2.0.0 (>=2.0.0), whose todo API speaks
TomTodo from tom_todo_model, and tom_vscode_scripting_api_bridges is
regenerated for it. A script that used TodoItem, TodoStatus,
TodoPriority, TodoScope or TodoReference now uses TomTodo,
TomTodoStatus, TomTodoPriority, TomTodoScope and TomTodoReference;
reads answer TodoEntry (.todo, .sourceFile, .level) and lists
TodoListResult (.todos, .entries, .invalid). The scripting API's
CHANGELOG has the details.
1.7.2 #
Changed — resolves the security release; bridges regenerated (dfin4) #
Resolves tom_d4rt 1.226.0. cli_api_bridges carries the interpreter's new public surface
(loadedSourceModuleCount), and tom_vscode_scripting_api_bridges its 1.1.3
API. Scripts run through the REPL keep every permission they had: the REPL
grants FilesystemPermission.any and ProcessRunPermission.any, so neither the
script-runner import check nor the execute rule narrows what a REPL script can
do.
1.7.1 #
Changed — bridges regenerated with tom_d4rt_generator 1.51.0 (sch3) #
tom_d4rt_generator ^1.51.0. 1.51.0 formats its output at this package's language version, so every generated *.b.dart is now dart format-clean as written. The generator's other 1.51.0 changes are in its own CHANGELOG.
bridges_fresh_test's BRIDGE-FRESH-02 now matches D4\s*.extractBridgedArg: the formatter may break the call across lines, and the old literal pattern stopped finding it.
1.7.0 #
Changed — resolves the current interpreter; bridges regenerated (sce212) #
Resolves tom_d4rt 1.192.0 (the first interpreter releases since
2026-09-11) and tom_d4rt_generator 1.44.0. bridges_fresh_test went red on the
upgrade, as it should: the regenerated *.b.dart now bridge the interpreter
API that landed in between (for example registerFunctionTypedef's arity
parameters, reuseAcrossRuns, dispose). Regenerated with d4rtgen and
committed with the upgrade.
1.6.0 #
Removed — eight build_runner-era bridge files nothing imports or regenerates #
lib/src/d4rt_library_bridges/ held bridges_trigger.b.dart and seven
package_*_bridges.b.dart from the build_runner builder, dated 2026-02-26,
~740 KB, shipped in every release since. This package builds its bridges with
the d4rtgen CLI, which writes one self-contained module file per configured
module and never touches that folder — so the files could only rot or be
hand-edited in the belief a regeneration would keep the edit.
Confirmed before deleting: no reference to the folder anywhere outside it, and
d4rtgen --dry-run reports no run writes any of the eight. The builder's
completion marker lib/d4rt_bridges.g.info goes with them.
tom_d4rt_generator 1.28.0's orphan check is what makes this visible, and
test/bridges_fresh_test.dart now asserts nothing is orphaned.
lib/src/bridges/dcli_bridges.b.dart is deliberately NOT regenerated. A
fresh generation drops the settings_yaml import and degrades
getExcludedPaths(SettingsYaml yaml, ...) to dynamic / InvalidType, so the
freshness test reports it as stale. Committing that regeneration would turn the
gate green by shipping the degradation it is reporting.
1.5.0 #
Changed — realigned with the dcli 10 line #
dcli, dcli_core and dcli_terminal move from ^8.4.2 to ^10.0.0, and
dart_console to ^5.0.0 (required by dcli_terminal 10). win32 resolves
6.4.0 in consequence.
The move was blocked, not deferred: tom_build_base pinned dcli: ^8.4.2,
and because it sits transitively under this package via tom_d4rt_generator,
version solving rejected any request for dcli 10 regardless of what this
pubspec said. tom_build_base 2.11.0 widens that constraint to admit both
majors, which is what unblocks this.
Changed — bridges regenerated against the dcli 10 API #
lib/src/bridges/*.b.dart are regenerated. dcli 9 removed a set of members
that had been deprecated through the 8.x line, so the committed bridges
described methods the package no longer has and every test that loaded them
failed to compile. The removals visible here are Env.addToPATHIfAbsent,
Terminal.previousLine, Terminal.lines, DartProject.current,
DartScript.current, and DartSdk.globalActivate /
globalActivateFromPath.
Removed — the FileSync.tempFile() bridge test #
FileSync.tempFile() was deprecated in favour of the top-level
createTempFilename() and removed in dcli 9, so the test asserted an API that
no longer exists. createTempFilename() is already covered by two tests in
the Temp Files group; a third copy in the FileSync group would have been
duplication rather than coverage.
Suite 704/13/0, against a 705/13/0 baseline — the difference is exactly the deleted test.
1.4.0 #
Fixed — the --version banner reports the real version (sce9) #
lib/src/version.versioner.dart said 1.3.1 while the pubspec said 1.4.0, so
dcli --version named a release that is not what was running. The stamp is
regenerated and version_stamp_test passes; published so the correction
reaches the package people install rather than only this tree.
Changed — the bridges are regenerated after seven months, and the package can now check them (sce3) #
tom_d4rt_dcli configured d4rtgen in its buildkit.yaml but listed
tom_d4rt_generator in no dependency block, so dart run tom_d4rt_generator:d4rtgen failed in it and checkBridgeFreshness could not
be called from its suite. It was one of two consumers in the workspace that
could neither regenerate its bridges nor check what it had committed.
The dependency was there once, commented out, with a reason:
# analyzer-10 migration: tom_d4rt_generator (still analyzer ^8.4.1) cannot
# share a resolution with tom_d4rt's analyzer ^10.
That has not been true for some time. The generator depends on
analyzer: ^10.0.0 and on tom_d4rt: ^1.77.0, which is exactly what this
package already declared; adding it back as a DEV dependency resolves on the
first attempt and changes nothing the package ships.
With it in place the measurement was possible, and eight of the nine generated
files were stale — every bridge module, the dartscript, the test runner and
the relaxers, last written in February. They are now what the generator
produces, and test/bridges_fresh_test.dart will say so the next time they
drift.
1.3.1 #
Changed — formatted the tree once (scd82) #
Every package in this repo already declares an SDK floor above the 3.7
tall-style boundary, so the formatter can no longer produce two layouts here.
What was not true is that the trees were formatted: until this commit, running
dart format on any single file rewrote it wholesale and buried whatever real
edit came with it. 46 of 60 files under lib and test were affected.
This package and tom_dcli_exec are twins in the sense SCC26 cares about — the
same REPL on the analyzer line and the analyzer-free line, kept in step by
diffing — so unformatted layout was actively costing the check that keeps them
equal, not merely untidy.
The commit is layout plus twelve brace pairs, and which is which was proven
rather than asserted. git diff -w cannot establish inertness, because the
tall style splits lines and a whitespace-insensitive diff still counts a moved
boundary as a change. What was checked is the token stream, per file, twice:
whitespace stripped, then whitespace and commas stripped. 44 of the 46 files are
identical to HEAD under that normalisation.
The other two are lib/src/cli/repl_base.dart and
lib/src/cli/vscode_integration.dart, which gained braces — ten pairs and two
pairs. Re-wrapping a long braceless if splits it across lines, which is what
makes curly_braces_in_flow_control_structures fire, and it fired twelve times
here. The braces were added by dart fix --code=curly_braces_in_flow_control_structures
rather than by hand: a first attempt to brace them with a regex over the source
corrupted a multi-line string, which is the argument for using the parser. Every
inserted chunk in those two files was then checked to be exactly { or } and
nothing else.
dart analyze is clean, and the formatter is now idempotent here.
1.3.0 #
Added — the full VS Code scripting API bridge surface #
lib/src/bridges/tom_vscode_scripting_api_bridges.b.dart was regenerated
against the current tom_vscode_scripting_api and grew from a partial surface
to the complete one (~9 000 lines of additional bridged members). Scripts that
previously hit Undefined member on a VS Code scripting call now resolve it.
The remaining bridge files (cli_api, dcli, path, tom_chattools) were
regenerated in the same pass; their content is unchanged.
Fixed — barrel re-exports were registered under an unmatched key (GEN-125) #
bridgeReExports() recorded its source as lib/tom_d4rt_cli_api.dart
instead of package:tom_d4rt_dcli/tom_d4rt_cli_api.dart, because the bridge
generator failed to root a relative source path before mapping it to a package
URI. registerLibraryReExport matches that key against a script's import,
which is always a package: URI — so every symbol reached only through a
re-export of the CLI API barrel was invisible to interpreted scripts.
Fixed upstream in tom_d4rt_generator 1.15.3 and picked up here by
regeneration; no hand edits to any *.b.dart.
1.2.0 #
Fixed — .start-execute blocks of bare statements failed to parse (tccc5) #
D4rt.execute(source:) parses its argument as a compilation unit and calls
the top-level main. A .start-execute block was handed straight to it, so a
block of bare statements
.start-execute
var testVar = 100;
verify(testVar == 100, '.start-execute variable works');
.end
parsed as a top-level variable followed by a function declaration with no body
and failed with Expected to find ')' / A function body must be provided.
The three-case rule that fixes this already existed — but only on the stdin
path. It is now the top-level prepareProgramSource, applied at every entry
point that means "run this as a fresh program": stdin, the exec command,
.start-execute, and CliController.execute.
- imports +
main→ run unchanged mainwithout imports → the bridge import block is prefixed- bare statements → prefixed and wrapped in a generated
main
The generated wrapper is async when the statements await, matching what
.start-script already did; await inside a string or comment does not count.
.start-execute also awaits a Future result now instead of printing it.
Requires tom_d4rt >= 1.29.0, without which a run whose assertions all pass is
still failed by phantom extension-registration errors. Routing .start-execute
through the bridge import block — which it needs, because a bridged library's
top-level functions (verify, verifyEquals, …) only become visible through
its import — is what made those errors reachable from this path.
1.1.6 #
- Fix duplicate-export collisions that broke AOT compilation in hosted
consumers (e.g.
tom_core_d4rt'sd4rtbinary). The VS Code integration re-export now hidesPermissionResult,ConversationExchange,ProjectInfoandWorkspaceInfoso the package's ownbot_modetypes win, andtelegram_bot_serverhides the VS CodeConversationExchangeso the localconversation_trailtype is used. No public API change for the package's own types; the VS Code variants of those four names are no longer re-exported (importtom_vscode_scripting_apidirectly if you need them).
1.1.5 #
- Housekeeping: test artifacts now live in a gitignored
testlog/folder;doc/no longer ships machine-generated baselines or last_testrun.json. No code changes.
1.1.4 #
Maintenance #
- Regenerated dcli bridges against the current
tom_d4rt_generator1.9.0 (summary-backed extraction, GEN-095 and follow-up fixes). - Pinned dependency constraints to current releases (
tom_d4rt^1.8.20,tom_vscode_scripting_api^1.0.1,tom_chattools^1.0.2).
1.1.3 #
Maintenance #
- Renamed
version.g.dart→version.versioner.dart. - Updated barrel import in
tom_d4rt_dcli.dart.
1.1.2 #
Bug Fixes #
- GEN-070 follow-up:
Findclass now properly bridged via generator fix (multi-chain barrel re-export) - Removed
dcli_missing_bridges.dartsupplementary bridge (no longer needed) - Removed
lastModified/setLastModifedtests (not exported from dcli barrel) - Replaced deprecated
symlink()tests withcreateSymLink()tests
Tests #
- All 389 tests pass, 0 failures, 0 skips
1.1.1 #
Bug Fixes #
- DCLI-GEN-001: Added supplementary bridge for missing global functions (
lastModified,setLastModifed,symlink) - DCLI-GEN-002: Added
Findclass bridge with static getters (file,directory,link) - DCLI-VSCODE-001: Fixed VS Code bridge import path and test constructor arguments
- DCLI-LOCK-001: Updated tests for deprecated
NamedLock.withLock(dcli 8.4.2), addedwithLockAsynctests - DCLI-API-001: Fixed
expandDefinetest prefix ($→@) - Symlink bridge uses
createSymLinkinternally (avoids deprecatedsymlink()warning)
Tests #
- All 391 tests pass, 0 failures, 0 skips
1.1.0 #
- Full DCli scripting support now
- Updated tom_d4rt dependency to ^1.8.1
- Regenerated bridges with latest generator (multi-barrel registration, extension filtering)
1.0.0 #
- Initial version.