@solana/rpc-subscriptions-transport-websocket
Advanced tools
Comparing version 2.0.0-experimental.dfb72ea to 2.0.0-experimental.e00f668
@@ -0,1 +1,3 @@ | ||
import { SolanaError, SOLANA_ERROR__RPC_SUBSCRIPTIONS_TRANSPORT_FAILED_TO_CONNECT, SOLANA_ERROR__RPC_SUBSCRIPTIONS_TRANSPORT_CONNECTION_CLOSED, SOLANA_ERROR__RPC_SUBSCRIPTIONS_TRANSPORT_CLOSED_BEFORE_MESSAGE_BUFFERED } from '@solana/errors'; | ||
// ../build-scripts/env-shim.ts | ||
@@ -47,4 +49,5 @@ var __DEV__ = /* @__PURE__ */ (() => process["env"].NODE_ENV === "development")(); | ||
reject( | ||
// TODO: Coded error | ||
new Error("WebSocket failed to connect", { cause: ev }) | ||
new SolanaError(SOLANA_ERROR__RPC_SUBSCRIPTIONS_TRANSPORT_FAILED_TO_CONNECT, { | ||
errorEvent: ev | ||
}) | ||
); | ||
@@ -74,4 +77,5 @@ } | ||
reject2( | ||
// TODO: Coded error | ||
new Error("WebSocket was closed before payload could be sent") | ||
new SolanaError( | ||
SOLANA_ERROR__RPC_SUBSCRIPTIONS_TRANSPORT_CLOSED_BEFORE_MESSAGE_BUFFERED | ||
) | ||
); | ||
@@ -123,3 +127,8 @@ }; | ||
} else { | ||
throw new Error("WebSocket connection closed", { cause: e2 }); | ||
throw new SolanaError( | ||
SOLANA_ERROR__RPC_SUBSCRIPTIONS_TRANSPORT_CONNECTION_CLOSED, | ||
{ | ||
cause: e2 | ||
} | ||
); | ||
} | ||
@@ -126,0 +135,0 @@ } |
@@ -0,1 +1,3 @@ | ||
import { SolanaError, SOLANA_ERROR__RPC_SUBSCRIPTIONS_TRANSPORT_FAILED_TO_CONNECT, SOLANA_ERROR__RPC_SUBSCRIPTIONS_TRANSPORT_CONNECTION_CLOSED, SOLANA_ERROR__RPC_SUBSCRIPTIONS_TRANSPORT_CLOSED_BEFORE_MESSAGE_BUFFERED } from '@solana/errors'; | ||
// ../build-scripts/env-shim.ts | ||
@@ -47,4 +49,5 @@ var __DEV__ = /* @__PURE__ */ (() => process["env"].NODE_ENV === "development")(); | ||
reject( | ||
// TODO: Coded error | ||
new Error("WebSocket failed to connect", { cause: ev }) | ||
new SolanaError(SOLANA_ERROR__RPC_SUBSCRIPTIONS_TRANSPORT_FAILED_TO_CONNECT, { | ||
errorEvent: ev | ||
}) | ||
); | ||
@@ -74,4 +77,5 @@ } | ||
reject2( | ||
// TODO: Coded error | ||
new Error("WebSocket was closed before payload could be sent") | ||
new SolanaError( | ||
SOLANA_ERROR__RPC_SUBSCRIPTIONS_TRANSPORT_CLOSED_BEFORE_MESSAGE_BUFFERED | ||
) | ||
); | ||
@@ -123,3 +127,8 @@ }; | ||
} else { | ||
throw new Error("WebSocket connection closed", { cause: e2 }); | ||
throw new SolanaError( | ||
SOLANA_ERROR__RPC_SUBSCRIPTIONS_TRANSPORT_CONNECTION_CLOSED, | ||
{ | ||
cause: e2 | ||
} | ||
); | ||
} | ||
@@ -126,0 +135,0 @@ } |
@@ -0,1 +1,2 @@ | ||
import { SolanaError, SOLANA_ERROR__RPC_SUBSCRIPTIONS_TRANSPORT_FAILED_TO_CONNECT, SOLANA_ERROR__RPC_SUBSCRIPTIONS_TRANSPORT_CONNECTION_CLOSED, SOLANA_ERROR__RPC_SUBSCRIPTIONS_TRANSPORT_CLOSED_BEFORE_MESSAGE_BUFFERED } from '@solana/errors'; | ||
import e from 'ws'; | ||
@@ -47,4 +48,5 @@ | ||
reject( | ||
// TODO: Coded error | ||
new Error("WebSocket failed to connect", { cause: ev }) | ||
new SolanaError(SOLANA_ERROR__RPC_SUBSCRIPTIONS_TRANSPORT_FAILED_TO_CONNECT, { | ||
errorEvent: ev | ||
}) | ||
); | ||
@@ -74,4 +76,5 @@ } | ||
reject2( | ||
// TODO: Coded error | ||
new Error("WebSocket was closed before payload could be sent") | ||
new SolanaError( | ||
SOLANA_ERROR__RPC_SUBSCRIPTIONS_TRANSPORT_CLOSED_BEFORE_MESSAGE_BUFFERED | ||
) | ||
); | ||
@@ -123,3 +126,8 @@ }; | ||
} else { | ||
throw new Error("WebSocket connection closed", { cause: e2 }); | ||
throw new SolanaError( | ||
SOLANA_ERROR__RPC_SUBSCRIPTIONS_TRANSPORT_CONNECTION_CLOSED, | ||
{ | ||
cause: e2 | ||
} | ||
); | ||
} | ||
@@ -126,0 +134,0 @@ } |
{ | ||
"name": "@solana/rpc-subscriptions-transport-websocket", | ||
"version": "2.0.0-experimental.dfb72ea", | ||
"version": "2.0.0-experimental.e00f668", | ||
"description": "An RPC Subscriptions transport that uses WebSockets", | ||
@@ -49,3 +49,4 @@ "exports": { | ||
"dependencies": { | ||
"@solana/rpc-subscriptions-spec": "2.0.0-experimental.dfb72ea" | ||
"@solana/errors": "2.0.0-experimental.e00f668", | ||
"@solana/rpc-subscriptions-spec": "2.0.0-experimental.e00f668" | ||
}, | ||
@@ -52,0 +53,0 @@ "peerDependencies": { |
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
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
119781
1112
3
+ Added@solana/errors@2.0.0-experimental.e00f668(transitive)
+ Added@solana/rpc-spec-types@2.0.0-experimental.e00f668(transitive)
+ Added@solana/rpc-subscriptions-spec@2.0.0-experimental.e00f668(transitive)
+ Addedchalk@5.4.1(transitive)
+ Addedcommander@12.1.0(transitive)
- Removed@solana/rpc-spec-types@2.0.0-experimental.dfb72ea(transitive)
- Removed@solana/rpc-subscriptions-spec@2.0.0-experimental.dfb72ea(transitive)
Updated@solana/rpc-subscriptions-spec@2.0.0-experimental.e00f668