Skip to content

Commit c68e93f

Browse files
committed
Removing the getDirSize() function for calculating telemetry codewhispererCodeScanProjectBytes
1 parent f0d891d commit c68e93f

File tree

1 file changed

+0
-11
lines changed

1 file changed

+0
-11
lines changed

packages/core/src/codewhisperer/commands/startSecurityScan.ts

Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,6 @@ import {
2929
CodeScanTelemetryEntry,
3030
} from '../models/model'
3131
import { cancel, ok } from '../../shared/localizedText'
32-
import { getDirSize } from '../../shared/filesystemUtilities'
3332
import { telemetry } from '../../shared/telemetry/telemetry'
3433
import { isAwsError } from '../../shared/errors'
3534
import { openUrl } from '../../shared/utilities/vsCodeUtils'
@@ -288,16 +287,6 @@ export async function emitCodeScanTelemetry(
288287
scope: CodeWhispererConstants.CodeAnalysisScope
289288
) {
290289
codeScanTelemetryEntry.codewhispererCodeScanProjectBytes = 0
291-
const now = performance.now()
292-
if (scope === CodeWhispererConstants.CodeAnalysisScope.PROJECT) {
293-
for (const folder of vscode.workspace.workspaceFolders ?? []) {
294-
codeScanTelemetryEntry.codewhispererCodeScanProjectBytes += await getDirSize(
295-
folder.uri.fsPath,
296-
now,
297-
CodeWhispererConstants.projectSizeCalculateTimeoutSeconds * 1000
298-
)
299-
}
300-
}
301290
telemetry.codewhisperer_securityScan.emit({
302291
...codeScanTelemetryEntry,
303292
passive: codeScanTelemetryEntry.codewhispererCodeScanScope === CodeAnalysisScope.FILE,

0 commit comments

Comments
 (0)