Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
xxadev
vscode
提交
2643ce10
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,发现更多精彩内容 >>
提交
2643ce10
编写于
9月 04, 2018
作者:
A
Andre Weinand
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
move telemetry out of way
上级
f7eeebcd
变更
1
隐藏空白更改
内联
并排
Showing
1 changed file
with
66 addition
and
48 deletion
+66
-48
src/vs/workbench/parts/debug/electron-browser/debugService.ts
...vs/workbench/parts/debug/electron-browser/debugService.ts
+66
-48
未找到文件。
src/vs/workbench/parts/debug/electron-browser/debugService.ts
浏览文件 @
2643ce10
...
...
@@ -17,7 +17,7 @@ import * as aria from 'vs/base/browser/ui/aria/aria';
import
{
IContextKeyService
,
IContextKey
}
from
'
vs/platform/contextkey/common/contextkey
'
;
import
{
IMarkerService
}
from
'
vs/platform/markers/common/markers
'
;
import
{
ILifecycleService
}
from
'
vs/platform/lifecycle/common/lifecycle
'
;
import
{
IExtensionService
}
from
'
vs/workbench/services/extensions/common/extensions
'
;
import
{
IExtensionService
,
IExtensionDescription
}
from
'
vs/workbench/services/extensions/common/extensions
'
;
import
{
IInstantiationService
}
from
'
vs/platform/instantiation/common/instantiation
'
;
import
{
FileChangesEvent
,
FileChangeType
,
IFileService
}
from
'
vs/platform/files/common/files
'
;
import
{
IWindowService
}
from
'
vs/platform/windows/common/windows
'
;
...
...
@@ -687,26 +687,8 @@ export class DebugService implements IDebugService {
this
.
viewModel
.
setMultiSessionView
(
true
);
}
/* __GDPR__
"debugSessionStart" : {
"type": { "classification": "SystemMetaData", "purpose": "FeatureInsight" },
"breakpointCount": { "classification": "SystemMetaData", "purpose": "FeatureInsight", "isMeasurement": true },
"exceptionBreakpoints": { "classification": "SystemMetaData", "purpose": "FeatureInsight" },
"watchExpressionsCount": { "classification": "SystemMetaData", "purpose": "FeatureInsight", "isMeasurement": true },
"extensionName": { "classification": "PublicNonPersonalData", "purpose": "FeatureInsight" },
"isBuiltin": { "classification": "SystemMetaData", "purpose": "FeatureInsight", "isMeasurement": true},
"launchJsonExists": { "classification": "SystemMetaData", "purpose": "FeatureInsight", "isMeasurement": true }
}
*/
return
this
.
telemetryService
.
publicLog
(
'
debugSessionStart
'
,
{
type
:
resolved
.
type
,
breakpointCount
:
this
.
model
.
getBreakpoints
().
length
,
exceptionBreakpoints
:
this
.
model
.
getExceptionBreakpoints
(),
watchExpressionsCount
:
this
.
model
.
getWatchExpressions
().
length
,
extensionName
:
dbgr
.
extensionDescription
.
id
,
isBuiltin
:
dbgr
.
extensionDescription
.
isBuiltin
,
launchJsonExists
:
root
&&
!!
this
.
configurationService
.
getValue
<
IGlobalConfig
>
(
'
launch
'
,
{
resource
:
root
.
uri
})
});
return
this
.
telemetryDebugSessionStart
(
root
,
resolved
.
type
,
dbgr
.
extensionDescription
);
}).
then
(()
=>
session
,
(
error
:
Error
|
string
)
=>
{
if
(
session
)
{
session
.
dispose
();
...
...
@@ -717,15 +699,6 @@ export class DebugService implements IDebugService {
return
TPromise
.
as
(
null
);
}
const
errorMessage
=
error
instanceof
Error
?
error
.
message
:
error
;
/* __GDPR__
"debugMisconfiguration" : {
"type" : { "classification": "SystemMetaData", "purpose": "FeatureInsight" },
"error": { "classification": "CallstackOrException", "purpose": "FeatureInsight" }
}
*/
this
.
telemetryService
.
publicLog
(
'
debugMisconfiguration
'
,
{
type
:
resolved
?
resolved
.
type
:
undefined
,
error
:
errorMessage
});
// Show the repl if some error got logged there #5870
if
(
this
.
model
.
getReplElements
().
length
>
0
)
{
this
.
panelService
.
openPanel
(
REPL_ID
,
false
);
...
...
@@ -734,6 +707,8 @@ export class DebugService implements IDebugService {
if
(
resolved
&&
resolved
.
request
===
'
attach
'
&&
resolved
.
__autoAttach
)
{
// ignore attach timeouts in auto attach mode
}
else
{
const
errorMessage
=
error
instanceof
Error
?
error
.
message
:
error
;
this
.
telemetryDebugMisconfiguration
(
resolved
?
resolved
.
type
:
undefined
,
errorMessage
);
this
.
showError
(
errorMessage
,
errors
.
isErrorWithActions
(
error
)
?
error
.
actions
:
[]);
}
return
undefined
;
...
...
@@ -777,24 +752,7 @@ export class DebugService implements IDebugService {
});
}
const
breakpoints
=
this
.
model
.
getBreakpoints
();
/* __GDPR__
"debugSessionStop" : {
"type" : { "classification": "SystemMetaData", "purpose": "FeatureInsight" },
"success": { "classification": "SystemMetaData", "purpose": "FeatureInsight", "isMeasurement": true },
"sessionLengthInSeconds": { "classification": "SystemMetaData", "purpose": "FeatureInsight", "isMeasurement": true },
"breakpointCount": { "classification": "SystemMetaData", "purpose": "FeatureInsight", "isMeasurement": true },
"watchExpressionsCount": { "classification": "SystemMetaData", "purpose": "FeatureInsight", "isMeasurement": true }
}
*/
this
.
telemetryService
.
publicLog
(
'
debugSessionStop
'
,
{
type
:
session
&&
session
.
configuration
.
type
,
success
:
(
<
RawDebugSession
>
session
.
raw
).
emittedStopped
||
breakpoints
.
length
===
0
,
sessionLengthInSeconds
:
(
<
RawDebugSession
>
session
.
raw
).
getLengthInSeconds
(),
breakpointCount
:
breakpoints
.
length
,
watchExpressionsCount
:
this
.
model
.
getWatchExpressions
().
length
});
this
.
telemetryDebugSessionStop
(
session
);
if
(
session
.
configuration
.
postDebugTask
)
{
this
.
doRunTask
(
session
.
getId
(),
session
.
root
,
session
.
configuration
.
postDebugTask
).
then
(
undefined
,
err
=>
...
...
@@ -1160,4 +1118,64 @@ export class DebugService implements IDebugService {
dispose
():
void
{
this
.
toDispose
=
dispose
(
this
.
toDispose
);
}
// telemetry
private
telemetryDebugSessionStart
(
root
:
IWorkspaceFolder
,
type
:
string
,
extension
:
IExtensionDescription
):
TPromise
<
any
>
{
/* __GDPR__
"debugSessionStart" : {
"type": { "classification": "SystemMetaData", "purpose": "FeatureInsight" },
"breakpointCount": { "classification": "SystemMetaData", "purpose": "FeatureInsight", "isMeasurement": true },
"exceptionBreakpoints": { "classification": "SystemMetaData", "purpose": "FeatureInsight" },
"watchExpressionsCount": { "classification": "SystemMetaData", "purpose": "FeatureInsight", "isMeasurement": true },
"extensionName": { "classification": "PublicNonPersonalData", "purpose": "FeatureInsight" },
"isBuiltin": { "classification": "SystemMetaData", "purpose": "FeatureInsight", "isMeasurement": true},
"launchJsonExists": { "classification": "SystemMetaData", "purpose": "FeatureInsight", "isMeasurement": true }
}
*/
return
this
.
telemetryService
.
publicLog
(
'
debugSessionStart
'
,
{
type
:
type
,
breakpointCount
:
this
.
model
.
getBreakpoints
().
length
,
exceptionBreakpoints
:
this
.
model
.
getExceptionBreakpoints
(),
watchExpressionsCount
:
this
.
model
.
getWatchExpressions
().
length
,
extensionName
:
extension
.
id
,
isBuiltin
:
extension
.
isBuiltin
,
launchJsonExists
:
root
&&
!!
this
.
configurationService
.
getValue
<
IGlobalConfig
>
(
'
launch
'
,
{
resource
:
root
.
uri
})
});
}
private
telemetryDebugSessionStop
(
session
:
ISession
):
TPromise
<
any
>
{
const
breakpoints
=
this
.
model
.
getBreakpoints
();
/* __GDPR__
"debugSessionStop" : {
"type" : { "classification": "SystemMetaData", "purpose": "FeatureInsight" },
"success": { "classification": "SystemMetaData", "purpose": "FeatureInsight", "isMeasurement": true },
"sessionLengthInSeconds": { "classification": "SystemMetaData", "purpose": "FeatureInsight", "isMeasurement": true },
"breakpointCount": { "classification": "SystemMetaData", "purpose": "FeatureInsight", "isMeasurement": true },
"watchExpressionsCount": { "classification": "SystemMetaData", "purpose": "FeatureInsight", "isMeasurement": true }
}
*/
return
this
.
telemetryService
.
publicLog
(
'
debugSessionStop
'
,
{
type
:
session
&&
session
.
configuration
.
type
,
success
:
(
<
RawDebugSession
>
session
.
raw
).
emittedStopped
||
breakpoints
.
length
===
0
,
sessionLengthInSeconds
:
(
<
RawDebugSession
>
session
.
raw
).
getLengthInSeconds
(),
breakpointCount
:
breakpoints
.
length
,
watchExpressionsCount
:
this
.
model
.
getWatchExpressions
().
length
});
}
private
telemetryDebugMisconfiguration
(
debugType
:
string
,
message
:
string
):
TPromise
<
any
>
{
/* __GDPR__
"debugMisconfiguration" : {
"type" : { "classification": "SystemMetaData", "purpose": "FeatureInsight" },
"error": { "classification": "CallstackOrException", "purpose": "FeatureInsight" }
}
*/
return
this
.
telemetryService
.
publicLog
(
'
debugMisconfiguration
'
,
{
type
:
debugType
,
error
:
message
});
}
}
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录