Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
xxadev
vscode
提交
fc6e8fda
V
vscode
项目概览
xxadev
/
vscode
与 Fork 源项目一致
从无法访问的项目Fork
通知
2
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
V
vscode
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
fc6e8fda
编写于
2月 05, 2020
作者:
I
isidor
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
fixes #89059
上级
39587fe5
变更
4
隐藏空白更改
内联
并排
Showing
4 changed file
with
14 addition
and
9 deletion
+14
-9
src/vs/workbench/contrib/debug/browser/debugSession.ts
src/vs/workbench/contrib/debug/browser/debugSession.ts
+1
-2
src/vs/workbench/contrib/debug/browser/rawDebugSession.ts
src/vs/workbench/contrib/debug/browser/rawDebugSession.ts
+11
-5
src/vs/workbench/contrib/debug/common/debugUtils.ts
src/vs/workbench/contrib/debug/common/debugUtils.ts
+1
-1
src/vs/workbench/contrib/debug/test/browser/repl.test.ts
src/vs/workbench/contrib/debug/test/browser/repl.test.ts
+1
-1
未找到文件。
src/vs/workbench/contrib/debug/browser/debugSession.ts
浏览文件 @
fc6e8fda
...
...
@@ -190,7 +190,7 @@ export class DebugSession implements IDebugSession {
try
{
const
customTelemetryService
=
await
dbgr
.
getCustomTelemetryService
();
const
debugAdapter
=
await
dbgr
.
createDebugAdapter
(
this
);
this
.
raw
=
new
RawDebugSession
(
debugAdapter
,
dbgr
,
this
.
telemetryService
,
customTelemetryService
,
this
.
extensionHostDebugService
,
this
.
openerService
);
this
.
raw
=
new
RawDebugSession
(
debugAdapter
,
dbgr
,
this
.
telemetryService
,
customTelemetryService
,
this
.
extensionHostDebugService
,
this
.
openerService
,
this
.
notificationService
);
await
this
.
raw
.
start
();
this
.
registerListeners
();
...
...
@@ -693,7 +693,6 @@ export class DebugSession implements IDebugSession {
await
this
.
raw
.
configurationDone
();
}
catch
(
e
)
{
// Disconnect the debug session on configuration done error #10596
this
.
notificationService
.
error
(
e
);
if
(
this
.
raw
)
{
this
.
raw
.
disconnect
();
}
...
...
src/vs/workbench/contrib/debug/browser/rawDebugSession.ts
浏览文件 @
fc6e8fda
...
...
@@ -19,6 +19,7 @@ import { env as processEnv } from 'vs/base/common/process';
import
{
IOpenerService
}
from
'
vs/platform/opener/common/opener
'
;
import
{
IDisposable
,
dispose
}
from
'
vs/base/common/lifecycle
'
;
import
{
CancellationToken
}
from
'
vs/base/common/cancellation
'
;
import
{
INotificationService
}
from
'
vs/platform/notification/common/notification
'
;
/**
* This interface represents a single command line argument split into a "prefix" and a "path" half.
...
...
@@ -79,7 +80,8 @@ export class RawDebugSession implements IDisposable {
private
readonly
telemetryService
:
ITelemetryService
,
public
readonly
customTelemetryService
:
ITelemetryService
|
undefined
,
private
readonly
extensionHostDebugService
:
IExtensionHostDebugService
,
private
readonly
openerService
:
IOpenerService
private
readonly
openerService
:
IOpenerService
,
private
readonly
notificationService
:
INotificationService
)
{
this
.
debugAdapter
=
debugAdapter
;
this
.
_capabilities
=
Object
.
create
(
null
);
...
...
@@ -632,8 +634,8 @@ export class RawDebugSession implements IDisposable {
return
errors
.
canceled
();
}
const
error
=
errorResponse
&&
errorResponse
.
body
?
errorResponse
.
body
.
error
:
null
;
const
errorMessage
=
errorResponse
?
errorResponse
.
message
||
''
:
''
;
const
error
:
DebugProtocol
.
Message
|
undefined
=
errorResponse
?.
body
?.
error
;
const
errorMessage
=
errorResponse
?.
message
||
''
;
if
(
error
&&
error
.
sendTelemetry
)
{
const
telemetryMessage
=
error
?
formatPII
(
error
.
format
,
true
,
error
.
variables
)
:
errorMessage
;
...
...
@@ -641,15 +643,19 @@ export class RawDebugSession implements IDisposable {
}
const
userMessage
=
error
?
formatPII
(
error
.
format
,
false
,
error
.
variables
)
:
errorMessage
;
if
(
error
&&
error
.
url
)
{
const
url
=
error
?.
url
;
if
(
error
&&
url
)
{
const
label
=
error
.
urlLabel
?
error
.
urlLabel
:
nls
.
localize
(
'
moreInfo
'
,
"
More Info
"
);
return
createErrorWithActions
(
userMessage
,
{
actions
:
[
new
Action
(
'
debug.moreInfo
'
,
label
,
undefined
,
true
,
()
=>
{
this
.
openerService
.
open
(
URI
.
parse
(
error
.
url
));
this
.
openerService
.
open
(
URI
.
parse
(
url
));
return
Promise
.
resolve
(
null
);
})]
});
}
if
(
error
&&
error
.
format
&&
error
.
showUser
)
{
this
.
notificationService
.
error
(
error
.
format
);
}
return
new
Error
(
userMessage
);
}
...
...
src/vs/workbench/contrib/debug/common/debugUtils.ts
浏览文件 @
fc6e8fda
...
...
@@ -11,7 +11,7 @@ import { deepClone } from 'vs/base/common/objects';
const
_formatPIIRegexp
=
/{
([^
}
]
+
)
}/g
;
export
function
formatPII
(
value
:
string
,
excludePII
:
boolean
,
args
:
{
[
key
:
string
]:
string
}):
string
{
export
function
formatPII
(
value
:
string
,
excludePII
:
boolean
,
args
:
{
[
key
:
string
]:
string
}
|
undefined
):
string
{
return
value
.
replace
(
_formatPIIRegexp
,
function
(
match
,
group
)
{
if
(
excludePII
&&
group
.
length
>
0
&&
group
[
0
]
!==
'
_
'
)
{
return
match
;
...
...
src/vs/workbench/contrib/debug/test/browser/repl.test.ts
浏览文件 @
fc6e8fda
...
...
@@ -135,7 +135,7 @@ suite('Debug - REPL', () => {
model
.
addSession
(
session
);
const
adapter
=
new
MockDebugAdapter
();
const
raw
=
new
RawDebugSession
(
adapter
,
undefined
!
,
undefined
!
,
undefined
!
,
undefined
!
,
undefined
!
);
const
raw
=
new
RawDebugSession
(
adapter
,
undefined
!
,
undefined
!
,
undefined
!
,
undefined
!
,
undefined
!
,
undefined
!
);
session
.
initializeForTest
(
raw
);
await
session
.
addReplExpression
(
undefined
,
'
before.1
'
);
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录