feat: ethers plugin (#278)

* chore: arweave upgrade

* fix: add Buffer for browser env

* feat: ethers extension plugin

* fix: remove trash

* fix: normalize-source test
This commit is contained in:
Asia
2022-11-29 11:56:26 +01:00
committed by GitHub
parent bda4211863
commit dc4d1c70b3
10 changed files with 619 additions and 1700 deletions

View File

@@ -3,7 +3,6 @@ import {defaultCacheOptions, LoggerFactory, Warp, WarpFactory} from '../src';
import os from 'os';
import {JWKInterface} from "arweave/web/lib/wallet";
import fs from "fs";
import {StateUpdatePlugin} from "warp-contracts-subscription-plugin";
const logger = LoggerFactory.INST.create('Contract');

View File

@@ -4,9 +4,6 @@ import {defaultCacheOptions, defaultWarpGwOptions, LoggerFactory, WarpFactory} f
import fs from 'fs';
import path from 'path';
import {JWKInterface} from 'arweave/node/lib/wallet';
import {WarpPlugin, WarpPluginType} from "../src/core/WarpPlugin";
const { NlpManager } = require('node-nlp');
async function main() {
let wallet: JWKInterface = readJSON('./.secrets/33F0QHcb22W7LwWR1iRC8Az1ntZG09XQ03YWuw2ABqA.json');;
@@ -19,17 +16,6 @@ async function main() {
protocol: 'https'
});
class NlpExtension implements WarpPlugin<any, void> {
process(input: any): void {
input.NlpManager = NlpManager;
}
type(): WarpPluginType {
return 'smartweave-extension';
}
}
try {
const warp = WarpFactory
.forMainnet({...defaultCacheOptions, inMemory: true});