commit | 188dd3fa3c368c470fa802d8dde65774ba46fa52 | [log] [tgz] |
---|---|---|
author | Adam Rosien <adam@rosien.net> | Fri Apr 26 09:32:09 2024 -0700 |
committer | Adam Rosien <adam@rosien.net> | Thu May 02 13:07:24 2024 -0700 |
tree | 7390aa9b5f11fbc8b5f1de7afb4bc2adbab11bb8 | |
parent | 4999e1a6e41c2a0356e5589b15a56666bd9d3ea9 [diff] |
Refactor to fix event delivery guarantees. Events were emitted, or sometimes not emitted at all, before state changes were committed. Events were emitted, or sometimes not emitted at all, before state changes were committed. Some refactorings to both directly fix this and also improve the code: - New `Parse.Deliver` class encapsulates translation of `Parse.Event`s into DAP state and events, delivered via the `Debugee` interface. It also ensures state is delivered before events so that consumers can react to events and read the correct state values. `Parse.Deliver` also fixes the bug of not delivering certain events, like the data position upon the "continue" action, by delivering events at every kind of stopping action, which includes "step", "continue", and a hit breakpoint. - Remove `Debugee.state` and have the `Debugee` implementation emit the DAP events directly via `Debugee.events`. - Instead of using `None`-terminated `Queue`, which enqueues with `Some` and terminates with `None`, use the `Channel` data type which only uses the actual message type. - To lift an `IO` into a `Resource`, replace `Resource.eval(io)` with `io.toResource`. - Fix Daffodil 3.7.0 upgrade problems. Fixes #995.
This is an extension for Visual Studio Code (VS Code) which enables the interactive debugging of DFDL schema parsing using Apache Daffodil.
The easiest way to install the extension is through the VS Code Extension Marketplace. The steps are as follow:
Ctrl+P
(windown/linux) OR Command+P
(macos)ext install ASF.apache-daffodil-vscode
, then hit Enter
. This will begin installing the extension.If you wish to download the VSIX file instead, perhaps to install a previous version of the extension. The prebuilt VSIX files used to released the extension are available at Apache Daffodil VS Code Release Page. The steps are as follow:
Binaries
click on the file listed to begin the download.Installation From File
section for installing the prebuilt file.:exclamation:NOT necessary if using prebuilt VSIX:exclamation:
:exclamation:NOT necessary if running extension via VS Code without VSIX but a yarn install
will be required:exclamation:
Run full package
yarn package
apache-daffodil-vscode-*.vsix
The debug server will automatically be run by the extension unless useExistingServer
is to set to true
inside of .vscode/launch.json
If you wish to run the debug server manually the scripts to do so are at the following locations:
/home/USERNAME/.local/share/daffodil-dap
/Users/USERNAME/Library/Application\ Support/daffodil-dap
C:\\Users\\USERNAME\\AppData\\Roaming\\daffodil-dap
Once you have either downloaded the VSIX file or created it, you can now install it. There are two options to do this:
Via “Extensions: Install from VSIX” command from within VS Code.
vsix
to bring up the command and pointing it at the vsix
fileVia command line
code --install-extension apache-daffodil-vscode-*.vsix
Please refer to the Wiki page at https://github.com/apache/daffodil-vscode/wiki
You can ask questions on the dev@daffodil.apache.org or users@daffodil.apache.org mailing lists. You can report bugs via GitHub Issues.
Apache Daffodilâ„¢ Extension for Visual Studio Code is licensed under the Apache License, v2.0.
This product includes the logback library, which is available under the Eclipse Public License v1.0.
This product includes the Java Debug Server for Visual Studio Code library, which is available under the Eclipse Public License v1.0.
This product includes the Xml Schema Object Model library, which is licensed under the Common Development and Distribution License Version 1.1.
This product includes the Regular Mono RedHatFont font, which is licensed under the SIL Open Font License, Version 1.1.
This product includes the space-grotesk font, which is licensed under the SIL Open Font License, Version 1.1.