-
Notifications
You must be signed in to change notification settings - Fork 403
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix: debug toolbar is disappeared or session paused after debug session started #4312
Conversation
Warning There were issues while running some tools. Please review the errors and either fix the tool’s configuration or disable the tool if it’s a critical failure. 🔧 eslint
warning eslint@8.57.1: This version is no longer supported. Please see https://eslint.org/version-support for other options. 工作流程本次拉取请求包含三个主要变更:在调试断点服务中修改了 变更
可能相关的拉取请求
建议审阅者
📜 Recent review detailsConfiguration used: CodeRabbit UI 📒 Files selected for processing (1)
🚧 Files skipped from review as they are similar to previous changes (1)
⏰ Context from checks skipped due to timeout of 90000ms (9)
Finishing Touches
Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media? 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 0
🧹 Nitpick comments (1)
packages/debug/src/browser/view/configuration/debug-configuration.module.less (1)
99-100
: 修复调试工具栏定位问题通过添加
top: 0
和left: 0
解决了工具栏消失的问题。之前由于没有指定具体位置,导致绝对定位的工具栏可能会出现在不可预期的位置。这个修复很好地解决了原始问题。建议在注释中说明这个定位的重要性:
.debug_toolbar_container { position: absolute; width: 100%; height: 100%; display: flex; align-content: center; justify-content: center; z-index: 10; user-select: none; + /* 确保工具栏固定在容器的左上角,防止在调试会话期间消失 */ top: 0; left: 0;
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (2)
packages/debug/src/browser/view/breakpoints/debug-breakpoints.service.ts
(2 hunks)packages/debug/src/browser/view/configuration/debug-configuration.module.less
(1 hunks)
⏰ Context from checks skipped due to timeout of 90000ms (8)
- GitHub Check: unittest (ubuntu-latest, 18.x, jsdom)
- GitHub Check: unittest (ubuntu-latest, 18.x, node)
- GitHub Check: build (ubuntu-latest, 20.x)
- GitHub Check: unittest (macos-latest, 18.x, jsdom)
- GitHub Check: build-windows
- GitHub Check: unittest (macos-latest, 18.x, node)
- GitHub Check: ubuntu-latest, Node.js 20.x
- GitHub Check: build (macos-latest, 20.x)
🔇 Additional comments (1)
packages/debug/src/browser/view/breakpoints/debug-breakpoints.service.ts (1)
Line range hint
146-160
: 将方法改为箭头函数以确保正确的 this 绑定这个改动通过使用箭头函数确保了
this
的正确绑定,避免了在回调中可能出现的上下文丢失问题。虽然改动是正确的,但与调试工具栏消失的问题似乎没有直接关系。
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #4312 +/- ##
==========================================
- Coverage 54.20% 54.20% -0.01%
==========================================
Files 1634 1634
Lines 99941 99947 +6
Branches 21703 21699 -4
==========================================
+ Hits 54177 54180 +3
- Misses 38021 38023 +2
- Partials 7743 7744 +1
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
/next |
🎉 PR Next publish successful! 3.7.1-next-1736417771.0 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 1
🧹 Nitpick comments (2)
packages/ai-native/src/browser/languages/tree-sitter/wasm-manager.ts (2)
33-33
: 修正拼写错误:'protocal' 应为 'protocol'变量名中存在拼写错误,这可能会导致代码可读性降低。
建议修改为:
- const protocal = url.scheme; + const protocol = url.scheme;
32-34
: 建议简化路径构建逻辑当前的实现虽然有效,但可以通过使用 URI 的内置方法使其更简洁。
建议重构为:
- const url = new URI(baseUrl); - const protocal = url.scheme; - const wasmPath = new URI(path.join(url.path.toString(), 'tree-sitter.wasm')).withScheme(protocal); + const wasmPath = URI.from(baseUrl).resolve('tree-sitter.wasm');这样的实现更简洁,且保持了相同的功能。
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (1)
packages/ai-native/src/browser/languages/tree-sitter/wasm-manager.ts
(2 hunks)
⏰ Context from checks skipped due to timeout of 90000ms (7)
- GitHub Check: unittest (ubuntu-latest, 18.x, jsdom)
- GitHub Check: build (ubuntu-latest, 20.x)
- GitHub Check: unittest (ubuntu-latest, 18.x, node)
- GitHub Check: unittest (macos-latest, 18.x, jsdom)
- GitHub Check: build (macos-latest, 20.x)
- GitHub Check: unittest (macos-latest, 18.x, node)
- GitHub Check: build-windows
🔇 Additional comments (1)
packages/ai-native/src/browser/languages/tree-sitter/wasm-manager.ts (1)
5-5
: 导入更改看起来不错!从
@opensumi/ide-utils
导入URI
类是一个很好的改进,这样可以更好地处理 URI 路径。
/next |
🎉 PR Next publish successful! 3.7.1-next-1736420958.0 |
/next |
🎉 PR Next publish successful! 3.7.1-next-1736421899.0 |
Types
Background or solution
Changelog
fix debug toolbar is disappeared after debug session started
Summary by CodeRabbit
样式调整
代码重构
toggleBreakpointEnable
方法的声明方式,确保方法内部的this
上下文保持一致。