Skip to content

Add Emmy attach debugger support#51

Open
Yoctillion wants to merge 4 commits intoEmmyLua:mainfrom
Yoctillion:attach-debugger
Open

Add Emmy attach debugger support#51
Yoctillion wants to merge 4 commits intoEmmyLua:mainfrom
Yoctillion:attach-debugger

Conversation

@Yoctillion
Copy link
Copy Markdown

  • Add attach debugger: inject emmy_hook.dll into running process by pid or name
  • Add launch debugger: start executable with hook pre-loaded
  • Extract EmmyDebugProcessBase from EmmyDebugProcess for shared protocol logic
  • Fix prepareSandbox plugin directory prefix (was copying to wrong path)
  • Fix EasyHook.dll missing from installDependencies (caused injection failure)
  • Fix transport connecting to 127.0.0.1 instead of ::1
  • Fix EmmyLuaAnalyzerAdaptor server path resolution

- Add attach debugger: inject emmy_hook.dll into running process by pid or name
- Add launch debugger: start executable with hook pre-loaded
- Extract EmmyDebugProcessBase from EmmyDebugProcess for shared protocol logic
- Fix prepareSandbox plugin directory prefix (was copying to wrong path)
- Fix EasyHook.dll missing from installDependencies (caused injection failure)
- Fix transport connecting to 127.0.0.1 instead of ::1
- Fix EmmyLuaAnalyzerAdaptor server path resolution

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@CppCXY
Copy link
Copy Markdown
Member

CppCXY commented Apr 24, 2026

Have you referenced this project? https://github.com/EmmyLua/EmmyLua2-AttachDebugger

@Yoctillion
Copy link
Copy Markdown
Author

This project depends on the old EmmyLua plugin and is not applicable to EmmyLua2. I referenced its implementation in this pull request.

@CppCXY
Copy link
Copy Markdown
Member

CppCXY commented Apr 24, 2026

This project depends on the old EmmyLua plugin and is not applicable to EmmyLua2. I referenced its implementation in this pull request.

https://github.com/EmmyLua/EmmyLua2-AttachDebugger/blob/c0faa197cafc8bc029d6622b07f8c48b5a8f0c19/build.gradle.kts#L70

Actually, it is just emmylua2's attach debugger, but I haven't updated it.

@CppCXY
Copy link
Copy Markdown
Member

CppCXY commented Apr 24, 2026

I support that it can be merged into the EmmyLua2 plugin, but some modifications are needed. First, we need to mark it as Windows only in a prominent place, and then you should show me the relevant UI and usage, and add documentation.

@Yoctillion
Copy link
Copy Markdown
Author

OK, I will add these later

Add os="windows" to configurationType, programRunner, and
xdebugger.attachDebuggerProvider for both Emmy Attach and Emmy Launch
debuggers so they are invisible on non-Windows platforms.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@Yoctillion
Copy link
Copy Markdown
Author

The launch debugger doesn't seem to be working properly. I will fix it together, or remove it

Yoctillion and others added 2 commits April 24, 2026 21:09
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
- Add docs/attach-debugger.md with setup and usage guide
- Add docs/attach-debugger.gif demo
- Link from project README with Windows-only note

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@Yoctillion
Copy link
Copy Markdown
Author

I've added os="windows" to all related extension points so the debugger is invisible on non-Windows platforms, and added documentation with a demo GIF in docs/attach-debugger.md.

@Yoctillion Yoctillion changed the title Add Emmy attach/launch debugger support Add Emmy attach debugger support Apr 30, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants