GithubHelp home page GithubHelp logo

satoren / vscode-lrdb Goto Github PK

View Code? Open in Web Editor NEW
41.0 6.0 19.0 2.87 MB

Lua debugger for vscode

Home Page: https://github.com/satoren/LRDB

License: Boost Software License 1.0

TypeScript 95.40% Lua 2.37% JavaScript 2.23%
lua lua-debugger vscode

vscode-lrdb's Introduction

Lua Remote DeBugger for Visual Studio Code

Node.js CI

Introduction

This extension is debug Lua programs with Visual Studio Code.

Lua Debug

Features

  • Supports Windows,macOS,Linux
  • Add/remove break points
  • Conditional break points
  • Continue,Pause,Step over, Step in, Step out
  • Local,Global,_ENV,Upvalue variables and arguments
  • Watch window
  • Evaluate Expressions
  • Debug with embedded Lua interpreter(Lua 5.3.3 on Javascript by Emscripten)
  • Debug with Your host program(require embed debug server)
  • Remote debugging over TCP

Extension Settings

launch.json example:

{
    "version": "0.2.0",
    "configurations": [
        {
            "type": "lrdb",
            "request": "launch",
            "name": "Lua Launch",
            "program": "${file}",
            "cwd": "${workspaceFolder}",
            "stopOnEntry": true
        }
    ]
}

Release Notes

CHANGELOG

vscode-lrdb's People

Contributors

dependabot[bot] avatar satoren avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

vscode-lrdb's Issues

Breakpoints in modules are not working/triggering during debug session

It looks like breakpoints are triggering only in main/launch Lua file, but all breakpoints set in the imported modules (via require("module")) are not triggering.
Is this a bug or I need some tweaks in lrdb-extension config and/or workspace config?

OS: macOS 10.12.6
Lua Debugger: internal (Emscripten)

The automated release is failing 🚨

🚨 The automated release from the main branch failed. 🚨

I recommend you give this issue a high priority, so other packages depending on you can benefit from your bug fixes and new features again.

You can find below the list of errors reported by semantic-release. Each one of them has to be resolved in order to automatically publish your package. I’m sure you can fix this 💪.

Errors are usually caused by a misconfiguration or an authentication problem. With each error reported below you will find explanation and guidance to help you to resolve it.

Once all the errors are resolved, semantic-release will release your package the next time you push a commit to the main branch. You can also manually restart the failed CI job that runs semantic-release.

If you are not sure how to resolve this, here are some links that can help you:

If those don’t help, or if this issue is reporting something you think isn’t right, you can always ask the humans behind semantic-release.


Invalid vsce token. Additional information:

Error: Command failed with exit code 1: vsce verify-pat
Usage: vsce [options]

Options:
-V, --version output the version number
-h, --help display help for command

Commands:
ls [options] Lists all the files that will be
published
package [options] Packages an extension
publish [options] [] Publishes an extension
unpublish [options] [] Unpublishes an extension. Example
extension id: microsoft.csharp.
ls-publishers List all known publishers
delete-publisher Deletes a publisher
login Add a publisher to the known
publishers list
logout Remove a publisher from the known
publishers list
show [options] Show extension metadata
search [options] search extension gallery
help [command] display help for command

Unknown command 'verify-pat'.

Unfortunately this error doesn't have any additional information. Feel free to kindly ask the author of the semantic-release-vsce plugin to add more helpful information.


Good luck with your project ✨

Your semantic-release bot 📦🚀

where does print() show?

Do I need some kind of print command redirect to see print commands in console or output?

This is my launch.json:

{
	"name": "Lua Launch",
	"type": "lrdb",
	"request": "launch",
	"program": "luajit",
	"cwd": "${workspaceFolder}",
	"stopOnEntry": true,
	"useInternalLua": false,
	"args": ["tool/vscode-debug.lua", "${relativeFile}"],
}

Debugging embedded lua

I am trying to get LRDB working with a lua instance embedded in a larger program by means of a third-party plugin. I have compiled my plugin with the server code as described in the docs. But I am stumped on how to get the vscode-lrdb extension to connect to my plugin.

This launch.json launches the debugger.

{
    "version": "0.2.0",
    "configurations": [
        {
            "type": "lrdb",
            "request": "launch",
            "name": "Lua Launch",
            "program": "${file}",
            "cwd": "${workspaceFolder}",
            "stopOnEntry": true
        }
    ]
}

But because the script isn't running under the control of my plugin, none of its environment is available so it fails immediately. Conversely I can change the "program" tag to point to the host program. That successfully launches the host program, but then the code hangs when I try to launch my .lua script.

The docs seems to imply that what I want to do is possible, but I don't see the options to do it.

The automated release is failing 🚨

🚨 The automated release from the main branch failed. 🚨

I recommend you give this issue a high priority, so other packages depending on you can benefit from your bug fixes and new features again.

You can find below the list of errors reported by semantic-release. Each one of them has to be resolved in order to automatically publish your package. I’m sure you can fix this 💪.

Errors are usually caused by a misconfiguration or an authentication problem. With each error reported below you will find explanation and guidance to help you to resolve it.

Once all the errors are resolved, semantic-release will release your package the next time you push a commit to the main branch. You can also manually restart the failed CI job that runs semantic-release.

If you are not sure how to resolve this, here are some links that can help you:

If those don’t help, or if this issue is reporting something you think isn’t right, you can always ask the humans behind semantic-release.


Invalid vsce token. Additional information:

Error: Command failed with exit code 1: vsce verify-pat
ERROR The Personal Access Token verification has failed. Additional information:

Error: {"$id":"1","customProperties":{"Descriptor":null,"IdentityDisplayName":null,"Token":null,"RequestedPermissions":0,"NamespaceId":"00000000-0000-0000-0000-000000000000"},"innerException":null,"message":"Access Denied: The Personal Access Token used has expired.","typeName":"Microsoft.VisualStudio.Services.Security.AccessCheckException, Microsoft.VisualStudio.Services.WebApi","typeKey":"AccessCheckException","errorCode":0,"eventId":3000}

Unfortunately this error doesn't have any additional information. Feel free to kindly ask the author of the semantic-release-vsce plugin to add more helpful information.


Good luck with your project ✨

Your semantic-release bot 📦🚀

Buffer() is deprecated

(node:18388) [DEP0005] DeprecationWarning: Buffer() is deprecated due to security and usability issues. Please use the Buffer.alloc(), Buffer.allocUnsafe(), or Buffer.from() methods instead.

LRDB not attaching to local process with VS Code >= 1.82, fix/workaround described

My organisation uses LRDB to attach VS Code to an application running Lua. This process seems to have broken as of VS Code version 1.82, with the LRDB plugin version 1.0.1. When invoking the attach process, it now seems to fail and return immediately.

The issue seems to be related to the "host" setting in the attach configuration. The default value for this is "localhost" - as shown in the following image - and this is what our configuration was set to. This default value seems to no longer work.
image

Changing this "host" value from "localhost" to "127.0.0.1" seems to fix the issue, and the debugger now attaches as normal.

Working configuration:
image

While I don't know if this an issue with LRDB per-se, I am posting this issue here as I don't know what part of the IDE/plugin organism it is that was previously accepting "localhost" as a value and no longer is, and what part of the organism is still recommending "localhost" as a sensible default. Possibly the plugin needs to be updated in some way, possibly the problem is entirely with VSCode. However, if other users of LRDB have the same issue they are more likely find this workaround if it's written here.

Many thanks for the very useful plugin!

support to multiple source roots

is there a way to specify multiple source roots to the debugger?

part of my lua code is embedded in the executable and another part is loaded separately, when i try to acces the embedded part i receive an error, even if i add both sourceroots to my workspace

Call stack paused on entry.

I'm attempting to debug a basic Lua program. I configured the launch.json file correctly,however,as soon as I ran the debugger,the call stack paused on entry.

environment variable

How can I set LUA_PATH for launching program?
I want something like that:

{
	"type": "lrdb",
	"request": "launch",
	"useInternalLua": false,
	"name": "Run tests",
	"program": "${workspaceRoot}/bin/lua_run",
	"args": ["data/tests/main.lua"],
	"sourceRoot": "${workspaceRoot}",
	"cwd": "${workspaceRoot}",
	"env": {
		"LUA_PATH": "data/tests/?.lua;data/scripts/?.lua"
	}
}

Dynamic libraries are not enabled for embedded interpreter

Everything was good until I've tried to debug 'requiring' my dll. Debug fails after with exit status 4294967295 and message "error loading module from file. Dynamic libraries not enabled; check your lua installation".
Extension strongly needs to support interpreter setting, or config. Or a way to enable dynamic libs.

"Invalid variable attributes" displayed in variables lists for Lua 5.1 // lrdb plugin version >0.3.4

Issue Type: Bug

I use lrdb to remote-debug an application that has lua 5.1 embedded. This worked very nicely up until satoren.lrdb extension version 0.4.0, after which significant issues with the variables lists shown in vscode were observed.

Some test script being debugged with satoren.lrdb extension version 0.4.0 (note that 1.0.0 behaves the same):
test_script_0 4 0

The same script being debugged with satoren.lrdb extension version 0.3.4:
test_script_0 3 4

I had a go at trying to get to the root of this issue - swapping bits of extension script from version 0.3.4 in to version 0.4.0, but the refactor that has taken place is significant and my complete lack of knowledge of javascript, vscode plugin debugging or the debug adapter protocol forced me to abandon the attempt.

I can roll back to version 0.3.4 of the extension, but obviously it would better to fix the issue somehow. Let me know if I can provide any further information to help fix this issue.

Extension version: 0.4.0
VS Code version: Code 1.64.2 (f80445acd5a3dadef24aa209168452a3d97cc326, 2022-02-09T22:02:28.252Z)
OS version: Windows_NT x64 10.0.19044
Restricted Mode: No

Not working debug after vscode 1.40

Issue Type: Bug

Not working debug after vscode 1.40. Work well in debug server extension mode

Extension version: 0.3.4
VS Code version: Code 1.40.1 (8795a9889db74563ddd43eb0a897a2384129a619, 2019-11-13T16:47:44.719Z)
OS version: Darwin x64 18.7.0

System Info
Item Value
CPUs Intel(R) Core(TM) i7-7820HQ CPU @ 2.90GHz (8 x 2900)
GPU Status 2d_canvas: enabled
flash_3d: enabled
flash_stage3d: enabled
flash_stage3d_baseline: enabled
gpu_compositing: enabled
metal: disabled_off
multiple_raster_threads: enabled_on
oop_rasterization: disabled_off
protected_video_decode: unavailable_off
rasterization: enabled
skia_renderer: disabled_off
surface_control: disabled_off
surface_synchronization: enabled_on
video_decode: enabled
viz_display_compositor: enabled_on
viz_hit_test_surface_layer: disabled_off
webgl: enabled
webgl2: enabled
Load (avg) 3, 3, 2
Memory (System) 16.00GB (0.30GB free)
Process Argv
Screen Reader no
VM 0%

The automated release is failing 🚨

🚨 The automated release from the main branch failed. 🚨

I recommend you give this issue a high priority, so other packages depending on you can benefit from your bug fixes and new features again.

You can find below the list of errors reported by semantic-release. Each one of them has to be resolved in order to automatically publish your package. I’m sure you can fix this 💪.

Errors are usually caused by a misconfiguration or an authentication problem. With each error reported below you will find explanation and guidance to help you to resolve it.

Once all the errors are resolved, semantic-release will release your package the next time you push a commit to the main branch. You can also manually restart the failed CI job that runs semantic-release.

If you are not sure how to resolve this, here are some links that can help you:

If those don’t help, or if this issue is reporting something you think isn’t right, you can always ask the humans behind semantic-release.


Invalid vsce token. Additional information:

Error: Command failed with exit code 1: vsce verify-pat
ERROR The Personal Access Token verification has failed. Additional information:

Error: {"$id":"1","customProperties":{"Descriptor":null,"IdentityDisplayName":null,"Token":null,"RequestedPermissions":0,"NamespaceId":"00000000-0000-0000-0000-000000000000"},"innerException":null,"message":"Access Denied: The Personal Access Token used has expired.","typeName":"Microsoft.VisualStudio.Services.Security.AccessCheckException, Microsoft.VisualStudio.Services.WebApi","typeKey":"AccessCheckException","errorCode":0,"eventId":3000}

Unfortunately this error doesn't have any additional information. Feel free to kindly ask the author of the semantic-release-vsce plugin to add more helpful information.


Good luck with your project ✨

Your semantic-release bot 📦🚀

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.