oasis-std
Advanced tools
Comparing version 0.2.2 to 1.0.0
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.encodeEventTopic = exports.typedArraySchemaType = exports.Decoder = exports.Encoder = exports.doAbiDecode = exports.abiDecode = exports.abiEncode = void 0; | ||
const buffer_1 = require("buffer"); | ||
@@ -5,0 +4,0 @@ const js_sha3_1 = require("js-sha3"); |
@@ -18,3 +18,3 @@ import EventEmitter from 'eventemitter3'; | ||
* `payload` should be the service bytecode followed by the constructor stdin. | ||
* @returns a promise that resolves to the address of the newly-created service. | ||
* @returns the address of the newly-created service. | ||
*/ | ||
@@ -26,3 +26,3 @@ deploy(payload: Uint8Array, options?: DeployOptions): Promise<Address>; | ||
* Optional `headers` override those passed to the `Gateway` constructor. | ||
* @returns a promise that resolves to the service stdout or rejects with an `RpcError`. | ||
* @returns the service stdout or rejects with an `RpcError`. | ||
*/ | ||
@@ -46,4 +46,5 @@ rpc(address: Address, payload: Uint8Array, options?: RpcOptions, headers?: Map<string, string>): Promise<Uint8Array>; | ||
private unsubscribe; | ||
getSenders(): Promise<Address[]>; | ||
/** | ||
* @returns a promise that resolves to the bytecode present at `address`. Rejects | ||
* @returns the bytecode present at `address`. Rejects | ||
* if there is no service at `address` or there is no bytecode (i.e. the address is an | ||
@@ -54,3 +55,3 @@ * externally-owned account). | ||
/** | ||
* @returns a promise that resolves to the public key of the service at `address`. | ||
* @returns the public key of the service at `address`. | ||
* Rejects if there is no service at `address`. | ||
@@ -57,0 +58,0 @@ */ |
@@ -36,3 +36,2 @@ "use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.Subscription = exports.Gateway = void 0; | ||
const common_1 = require("@oasislabs/common"); | ||
@@ -61,3 +60,3 @@ const confidential_1 = require("@oasislabs/confidential"); | ||
* `payload` should be the service bytecode followed by the constructor stdin. | ||
* @returns a promise that resolves to the address of the newly-created service. | ||
* @returns the address of the newly-created service. | ||
*/ | ||
@@ -91,3 +90,3 @@ deploy(payload, options) { | ||
* Optional `headers` override those passed to the `Gateway` constructor. | ||
* @returns a promise that resolves to the service stdout or rejects with an `RpcError`. | ||
* @returns the service stdout or rejects with an `RpcError`. | ||
*/ | ||
@@ -192,4 +191,10 @@ rpc(address, payload, options, headers = new Map()) { | ||
} | ||
getSenders() { | ||
return __awaiter(this, void 0, void 0, function* () { | ||
const { addresses } = yield this.inner.getSenders().catch(wrapError); | ||
return addresses.map((addr) => new types_1.Address(addr)); | ||
}); | ||
} | ||
/** | ||
* @returns a promise that resolves to the bytecode present at `address`. Rejects | ||
* @returns the bytecode present at `address`. Rejects | ||
* if there is no service at `address` or there is no bytecode (i.e. the address is an | ||
@@ -212,3 +217,3 @@ * externally-owned account). | ||
/** | ||
* @returns a promise that resolves to the public key of the service at `address`. | ||
* @returns the public key of the service at `address`. | ||
* Rejects if there is no service at `address`. | ||
@@ -318,3 +323,3 @@ */ | ||
} | ||
// Returns a Promise that resolves to the first event. After that, the | ||
// @returns the first event. After that, the | ||
// subscription automatically ends. | ||
@@ -321,0 +326,0 @@ first() { |
"use strict"; | ||
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) { | ||
if (k2 === undefined) k2 = k; | ||
Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } }); | ||
}) : (function(o, m, k, k2) { | ||
if (k2 === undefined) k2 = k; | ||
o[k2] = m[k]; | ||
})); | ||
var __exportStar = (this && this.__exportStar) || function(m, exports) { | ||
for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); | ||
}; | ||
function __export(m) { | ||
for (var p in m) if (!exports.hasOwnProperty(p)) exports[p] = m[p]; | ||
} | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
var abi_1 = require("./abi"); | ||
Object.defineProperty(exports, "Decoder", { enumerable: true, get: function () { return abi_1.Decoder; } }); | ||
Object.defineProperty(exports, "Encoder", { enumerable: true, get: function () { return abi_1.Encoder; } }); | ||
Object.defineProperty(exports, "abiDecode", { enumerable: true, get: function () { return abi_1.abiDecode; } }); | ||
Object.defineProperty(exports, "abiEncode", { enumerable: true, get: function () { return abi_1.abiEncode; } }); | ||
Object.defineProperty(exports, "encodeEventTopic", { enumerable: true, get: function () { return abi_1.encodeEventTopic; } }); | ||
__exportStar(require("./gateway"), exports); | ||
exports.Decoder = abi_1.Decoder; | ||
exports.Encoder = abi_1.Encoder; | ||
exports.abiDecode = abi_1.abiDecode; | ||
exports.abiEncode = abi_1.abiEncode; | ||
exports.encodeEventTopic = abi_1.encodeEventTopic; | ||
__export(require("./gateway")); | ||
var types_1 = require("./types"); | ||
Object.defineProperty(exports, "Address", { enumerable: true, get: function () { return types_1.Address; } }); | ||
Object.defineProperty(exports, "Balance", { enumerable: true, get: function () { return types_1.Balance; } }); | ||
Object.defineProperty(exports, "RpcError", { enumerable: true, get: function () { return types_1.RpcError; } }); | ||
Object.defineProperty(exports, "Map", { enumerable: true, get: function () { return types_1.OasisMap; } }); | ||
Object.defineProperty(exports, "Set", { enumerable: true, get: function () { return types_1.OasisSet; } }); | ||
Object.defineProperty(exports, "Result", { enumerable: true, get: function () { return types_1.Result; } }); | ||
exports.Address = types_1.Address; | ||
exports.Balance = types_1.Balance; | ||
exports.RpcError = types_1.RpcError; | ||
exports.Map = types_1.OasisMap; | ||
exports.Set = types_1.OasisSet; | ||
exports.Result = types_1.Result; | ||
var logging_1 = require("./logging"); | ||
Object.defineProperty(exports, "oasisLogger", { enumerable: true, get: function () { return logging_1.oasisLogger; } }); | ||
Object.defineProperty(exports, "stackTrace", { enumerable: true, get: function () { return logging_1.stackTrace; } }); | ||
exports.oasisLogger = logging_1.oasisLogger; | ||
exports.stackTrace = logging_1.stackTrace; | ||
var utils_1 = require("./utils"); | ||
Object.defineProperty(exports, "decodeHex", { enumerable: true, get: function () { return utils_1.decodeHex; } }); | ||
Object.defineProperty(exports, "encodeHex", { enumerable: true, get: function () { return utils_1.encodeHex; } }); | ||
Object.defineProperty(exports, "fetchBytecode", { enumerable: true, get: function () { return utils_1.fetchBytecode; } }); | ||
exports.decodeHex = utils_1.decodeHex; | ||
exports.encodeHex = utils_1.encodeHex; | ||
exports.fetchBytecode = utils_1.fetchBytecode; | ||
//# sourceMappingURL=index.js.map |
@@ -7,3 +7,2 @@ "use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.stackTrace = exports.oasisLogger = exports.logLevelFromEnv = void 0; | ||
const pino_1 = __importDefault(require("pino")); | ||
@@ -10,0 +9,0 @@ const isNode = typeof process !== 'undefined' && !!((_a = process === null || process === void 0 ? void 0 : process.versions) === null || _a === void 0 ? void 0 : _a.node); |
"use strict"; | ||
/* eslint-disable no-inner-declarations, @typescript-eslint/no-namespace */ | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.OasisSet = exports.OasisMap = exports.Result = exports.RpcError = exports.Balance = exports.Address = void 0; | ||
const utils_1 = require("./utils"); | ||
@@ -6,0 +5,0 @@ const abi_1 = require("./abi"); |
@@ -15,3 +15,2 @@ "use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.unreachable = exports.typedArrayToBuffer = exports.fetchBytecode = exports.encodeHex = exports.decodeHex = void 0; | ||
const buffer_1 = require("buffer"); | ||
@@ -18,0 +17,0 @@ const node_fetch_1 = __importDefault(require("node-fetch")); |
{ | ||
"name": "oasis-std", | ||
"version": "0.2.2", | ||
"version": "1.0.0", | ||
"description": "Oasis platform standard library", | ||
@@ -18,6 +18,6 @@ "license": "Apache-2.0", | ||
"dependencies": { | ||
"@oasislabs/common": "=1.0.0-rc.19", | ||
"@oasislabs/confidential": "=1.0.0-rc.25", | ||
"@oasislabs/gateway": "=1.0.0-rc.45", | ||
"@oasislabs/service": "=1.0.0-rc.36", | ||
"@oasislabs/common": "^1.0.0", | ||
"@oasislabs/confidential": "^1.0.0", | ||
"@oasislabs/gateway": "^1.0.0", | ||
"@oasislabs/service": "^1.0.0", | ||
"@types/pino": "^6.2.1", | ||
@@ -30,3 +30,3 @@ "buffer": "^5.4.3", | ||
}, | ||
"gitHead": "0281dc450caf2d9e17250a5760295b2277424685" | ||
"gitHead": "6f5dfabb1fbab372907f2d9b116557bf93b05333" | ||
} |
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
No v1
QualityPackage is not semver >=1. This means it is not stable and does not support ^ ranges.
Found 1 instance in 1 package
1
307955
2087
+ Added@hapi/bourne@2.1.0(transitive)
+ Added@oasislabs/common@1.0.0(transitive)
+ Added@oasislabs/confidential@1.0.0(transitive)
+ Added@oasislabs/gateway@1.0.0(transitive)
+ Added@oasislabs/service@1.0.0(transitive)
+ Added@types/pako@1.0.7(transitive)
+ Added@types/uuid@3.4.13(transitive)
+ Addedansi-styles@3.2.14.3.0(transitive)
+ Addedargs@5.0.3(transitive)
+ Addedaxios@0.19.2(transitive)
+ Addedbsaes@0.0.2(transitive)
+ Addedcamelcase@5.0.05.3.1(transitive)
+ Addedcamelcase-keys@6.2.2(transitive)
+ Addedcbor-js@0.1.0(transitive)
+ Addedchalk@2.4.24.1.2(transitive)
+ Addedcolor-convert@1.9.32.0.1(transitive)
+ Addedcolor-name@1.1.31.1.4(transitive)
+ Addeddeoxysii@0.0.2(transitive)
+ Addedescape-string-regexp@1.0.5(transitive)
+ Addedfollow-redirects@1.5.10(transitive)
+ Addedgraceful-fs@4.2.11(transitive)
+ Addedhas-flag@3.0.04.0.0(transitive)
+ Addedimurmurhash@0.1.4(transitive)
+ Addedinherits@2.0.4(transitive)
+ Addedjmespath@0.15.0(transitive)
+ Addedjoycon@2.2.5(transitive)
+ Addedjs-sha512@0.8.0(transitive)
+ Addedleven@2.1.0(transitive)
+ Addedmap-obj@4.3.0(transitive)
+ Addedmri@1.1.4(transitive)
+ Addednode-localstorage@2.2.1(transitive)
+ Addedpako@1.0.11(transitive)
+ Addedpino-pretty@4.8.0(transitive)
+ Addedquick-lru@4.0.1(transitive)
+ Addedreadable-stream@3.6.2(transitive)
+ Addedrfdc@1.4.1(transitive)
+ Addedsafe-buffer@5.2.1(transitive)
+ Addedslide@1.1.6(transitive)
+ Addedsplit2@3.2.2(transitive)
+ Addedstring_decoder@1.3.0(transitive)
+ Addedsupports-color@5.5.07.2.0(transitive)
+ Addedtweetnacl@1.0.3(transitive)
+ Addeduint32@0.2.1(transitive)
+ Addedutil-deprecate@1.0.2(transitive)
+ Addeduuid@3.4.0(transitive)
+ Addedwrite-file-atomic@1.3.4(transitive)
- Removedcolorette@2.0.20(transitive)
- Removedfast-copy@3.0.2(transitive)
- Removedhelp-me@5.0.0(transitive)
- Removedjoycon@3.1.1(transitive)
- Removedminimist@1.2.8(transitive)
- Removedon-exit-leak-free@2.1.2(transitive)
- Removedpino-abstract-transport@2.0.0(transitive)
- Removedpino-pretty@13.0.0(transitive)
- Removedsecure-json-parse@2.7.0(transitive)
- Removedsonic-boom@4.2.0(transitive)
- Removedsplit2@4.2.0(transitive)
Updated@oasislabs/common@^1.0.0
Updated@oasislabs/gateway@^1.0.0
Updated@oasislabs/service@^1.0.0