Adopt error no telemetry for filesystem providers. (#148832)
Adopt erorr no telemetrypull/151679/head
parent
070fb39a3c
commit
cfecdd5461
|
@ -7,6 +7,7 @@ import { coalesce } from 'vs/base/common/arrays';
|
|||
import { Promises, ResourceQueue } from 'vs/base/common/async';
|
||||
import { bufferedStreamToBuffer, bufferToReadable, newWriteableBufferStream, readableToBuffer, streamToBuffer, VSBuffer, VSBufferReadable, VSBufferReadableBufferedStream, VSBufferReadableStream } from 'vs/base/common/buffer';
|
||||
import { CancellationToken, CancellationTokenSource } from 'vs/base/common/cancellation';
|
||||
import { ErrorNoTelemetry } from 'vs/base/common/errors';
|
||||
import { Emitter } from 'vs/base/common/event';
|
||||
import { hash } from 'vs/base/common/hash';
|
||||
import { Iterable } from 'vs/base/common/iterator';
|
||||
|
@ -136,7 +137,7 @@ export class FileService extends Disposable implements IFileService {
|
|||
// Assert provider
|
||||
const provider = this.provider.get(resource.scheme);
|
||||
if (!provider) {
|
||||
const error = new Error();
|
||||
const error = new ErrorNoTelemetry();
|
||||
error.name = 'ENOPRO';
|
||||
error.message = localize('noProviderFound', "No file system provider found for resource '{0}'", resource.toString());
|
||||
|
||||
|
|
|
@ -17,6 +17,7 @@ import { CharCode } from 'vs/base/common/charCode';
|
|||
import { VSBuffer } from 'vs/base/common/buffer';
|
||||
import { IExtensionDescription } from 'vs/platform/extensions/common/extensions';
|
||||
import { checkProposedApiEnabled } from 'vs/workbench/services/extensions/common/extensions';
|
||||
import { ErrorNoTelemetry } from 'vs/base/common/errors';
|
||||
|
||||
class FsLinkProvider {
|
||||
|
||||
|
@ -295,7 +296,7 @@ export class ExtHostFileSystem implements ExtHostFileSystemShape {
|
|||
private _getFsProvider(handle: number): vscode.FileSystemProvider {
|
||||
const provider = this._fsProvider.get(handle);
|
||||
if (!provider) {
|
||||
const err = new Error();
|
||||
const err = new ErrorNoTelemetry();
|
||||
err.name = 'ENOPRO';
|
||||
err.message = `no provider`;
|
||||
throw err;
|
||||
|
|
Loading…
Reference in New Issue