Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

oasis-std

Package Overview
Dependencies
Maintainers
18
Versions
49
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

oasis-std - npm Package Compare versions

Comparing version 0.2.2 to 1.0.0

1

lib/src/abi.js
"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");

9

lib/src/gateway.d.ts

@@ -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

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc