flipper-common
Advanced tools
Comparing version 0.136.0 to 0.137.0
export { Logger, LoggerTrackType, LoggerTypes, LoggerArgs, getLogger, setLoggerInstance, NoopLogger, } from './utils/Logger'; | ||
export * from './server-types'; | ||
export * from './ServerAddOn'; | ||
export { sleep } from './utils/sleep'; | ||
@@ -10,3 +11,4 @@ export { timeout } from './utils/timeout'; | ||
export { logPlatformSuccessRate, reportPlatformFailures, reportUsage, reportPluginFailures, tryCatchReportPluginFailuresAsync, tryCatchReportPlatformFailures, tryCatchReportPluginFailures, UnsupportedError, } from './utils/metrics'; | ||
export { ConnectivityError, CancelledPromiseError, UserUnauthorizedError, UserNotSignedInError, NoLongerConnectedToClientError, isConnectivityOrAuthError, isError, isAuthError, getStringFromErrorLike, getErrorFromErrorLike, } from './utils/errors'; | ||
export { ConnectivityError, CancelledPromiseError, UserUnauthorizedError, UserNotSignedInError, NoLongerConnectedToClientError, isConnectivityOrAuthError, isError, isAuthError, getStringFromErrorLike, getErrorFromErrorLike, deserializeRemoteError, } from './utils/errors'; | ||
export { createControlledPromise } from './utils/controlledPromise'; | ||
export * from './GK'; | ||
@@ -17,2 +19,3 @@ export * from './clientUtils'; | ||
export * from './doctor'; | ||
export * from './ServerAddOn'; | ||
//# sourceMappingURL=index.d.ts.map |
@@ -13,3 +13,3 @@ "use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.getErrorFromErrorLike = exports.getStringFromErrorLike = exports.isAuthError = exports.isError = exports.isConnectivityOrAuthError = exports.NoLongerConnectedToClientError = exports.UserNotSignedInError = exports.UserUnauthorizedError = exports.CancelledPromiseError = exports.ConnectivityError = exports.UnsupportedError = exports.tryCatchReportPluginFailures = exports.tryCatchReportPlatformFailures = exports.tryCatchReportPluginFailuresAsync = exports.reportPluginFailures = exports.reportUsage = exports.reportPlatformFailures = exports.logPlatformSuccessRate = exports.fsConstants = exports.assertNever = exports.isProduction = exports.isTest = exports.timeout = exports.sleep = exports.NoopLogger = exports.setLoggerInstance = exports.getLogger = void 0; | ||
exports.createControlledPromise = exports.deserializeRemoteError = exports.getErrorFromErrorLike = exports.getStringFromErrorLike = exports.isAuthError = exports.isError = exports.isConnectivityOrAuthError = exports.NoLongerConnectedToClientError = exports.UserNotSignedInError = exports.UserUnauthorizedError = exports.CancelledPromiseError = exports.ConnectivityError = exports.UnsupportedError = exports.tryCatchReportPluginFailures = exports.tryCatchReportPlatformFailures = exports.tryCatchReportPluginFailuresAsync = exports.reportPluginFailures = exports.reportUsage = exports.reportPlatformFailures = exports.logPlatformSuccessRate = exports.fsConstants = exports.assertNever = exports.isProduction = exports.isTest = exports.timeout = exports.sleep = exports.NoopLogger = exports.setLoggerInstance = exports.getLogger = void 0; | ||
var Logger_1 = require("./utils/Logger"); | ||
@@ -20,2 +20,3 @@ Object.defineProperty(exports, "getLogger", { enumerable: true, get: function () { return Logger_1.getLogger; } }); | ||
__exportStar(require("./server-types"), exports); | ||
__exportStar(require("./ServerAddOn"), exports); | ||
var sleep_1 = require("./utils/sleep"); | ||
@@ -53,2 +54,5 @@ Object.defineProperty(exports, "sleep", { enumerable: true, get: function () { return sleep_1.sleep; } }); | ||
Object.defineProperty(exports, "getErrorFromErrorLike", { enumerable: true, get: function () { return errors_1.getErrorFromErrorLike; } }); | ||
Object.defineProperty(exports, "deserializeRemoteError", { enumerable: true, get: function () { return errors_1.deserializeRemoteError; } }); | ||
var controlledPromise_1 = require("./utils/controlledPromise"); | ||
Object.defineProperty(exports, "createControlledPromise", { enumerable: true, get: function () { return controlledPromise_1.createControlledPromise; } }); | ||
__exportStar(require("./GK"), exports); | ||
@@ -59,2 +63,3 @@ __exportStar(require("./clientUtils"), exports); | ||
__exportStar(require("./doctor"), exports); | ||
__exportStar(require("./ServerAddOn"), exports); | ||
//# sourceMappingURL=index.js.map |
@@ -7,2 +7,4 @@ export interface PluginDetails { | ||
main: string; | ||
serverAddOnSource?: string; | ||
serverAddOn?: string; | ||
id: string; | ||
@@ -58,2 +60,3 @@ gatekeeper?: string; | ||
entry: string; | ||
serverAddOnEntry?: string; | ||
} | ||
@@ -60,0 +63,0 @@ export declare type ActivatablePluginDetails = BundledPluginDetails | InstalledPluginDetails; |
@@ -49,3 +49,5 @@ "use strict"; | ||
main: packageJson.main, | ||
serverAddOn: packageJson.serverAddOn, | ||
source: packageJson.flipperBundlerEntry, | ||
serverAddOnSource: packageJson.flipperBundlerEntryServerAddOn, | ||
id: packageJson.id || packageJson.name, | ||
@@ -52,0 +54,0 @@ gatekeeper: packageJson.gatekeeper, |
import { FlipperDoctor } from './doctor'; | ||
import { BundledPluginDetails, DeviceSpec, DeviceType, DownloadablePluginDetails, InstalledPluginDetails, OS as PluginOS, UpdatablePluginDetails } from './PluginDetails'; | ||
import { ServerAddOnStartDetails } from './ServerAddOn'; | ||
import { EnvironmentInfo, LauncherSettings, ProcessConfig, Settings } from './settings'; | ||
@@ -86,2 +87,3 @@ export declare type FlipperServerState = 'pending' | 'starting' | 'started' | 'error' | 'closed'; | ||
}; | ||
'plugins-server-add-on-message': ExecuteMessage; | ||
'download-file-update': DownloadFileUpdate; | ||
@@ -170,2 +172,5 @@ }; | ||
'plugins-remove-plugins': (names: string[]) => Promise<void>; | ||
'plugins-server-add-on-start': (pluginName: string, details: ServerAddOnStartDetails, owner: string) => Promise<void>; | ||
'plugins-server-add-on-stop': (pluginName: string, owner: string) => Promise<void>; | ||
'plugins-server-add-on-request-response': (payload: ExecuteMessage) => Promise<ClientResponseType>; | ||
'doctor-get-healthchecks': (settings: FlipperDoctor.HealthcheckSettings) => Promise<FlipperDoctor.Healthchecks>; | ||
@@ -172,0 +177,0 @@ 'doctor-run-healthcheck': (settings: FlipperDoctor.HealthcheckSettings, category: keyof FlipperDoctor.Healthchecks, name: string) => Promise<FlipperDoctor.HealthcheckResult>; |
@@ -0,1 +1,2 @@ | ||
import { ClientErrorType } from '../server-types'; | ||
export declare function isAuthError(err: any): err is UserNotSignedInError | UserUnauthorizedError; | ||
@@ -31,2 +32,3 @@ export declare function isConnectivityOrAuthError(err: any): err is ConnectivityError | UserNotSignedInError | UserUnauthorizedError; | ||
export declare function getStringFromErrorLike(e: any): string; | ||
export declare const deserializeRemoteError: (serializedError: ClientErrorType) => Error; | ||
//# sourceMappingURL=errors.d.ts.map |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.getStringFromErrorLike = exports.getErrorFromErrorLike = exports.isError = exports.NoLongerConnectedToClientError = exports.UserNotSignedInError = exports.UserUnauthorizedError = exports.ConnectivityError = exports.CancelledPromiseError = exports.isConnectivityOrAuthError = exports.isAuthError = void 0; | ||
exports.deserializeRemoteError = exports.getStringFromErrorLike = exports.getErrorFromErrorLike = exports.isError = exports.NoLongerConnectedToClientError = exports.UserNotSignedInError = exports.UserUnauthorizedError = exports.ConnectivityError = exports.CancelledPromiseError = exports.isConnectivityOrAuthError = exports.isAuthError = void 0; | ||
function isAuthError(err) { | ||
@@ -93,2 +93,9 @@ return (err instanceof UserNotSignedInError || err instanceof UserUnauthorizedError); | ||
exports.getStringFromErrorLike = getStringFromErrorLike; | ||
const deserializeRemoteError = (serializedError) => { | ||
const err = new Error(serializedError.message); | ||
err.name = serializedError.name; | ||
err.stack += `. Caused by: ${serializedError.stacktrace}`; | ||
return err; | ||
}; | ||
exports.deserializeRemoteError = deserializeRemoteError; | ||
//# sourceMappingURL=errors.js.map |
{ | ||
"name": "flipper-common", | ||
"version": "0.136.0", | ||
"version": "0.137.0", | ||
"description": "Server & UI shared Flipper utilities", | ||
@@ -5,0 +5,0 @@ "repository": "facebook/flipper", |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
104647
74
1530