diff --git a/package.json b/package.json index 60bd5bf..e6dbc0b 100644 --- a/package.json +++ b/package.json @@ -59,9 +59,9 @@ "arweave" ], "bugs": { - "url": "https://github.com/redstone-finance/redstone-smartweave/issues" + "url": "https://github.com/redstone-finance/warp/issues" }, - "homepage": "https://github.com/redstone-finance/redstone-smartweave#readme", + "homepage": "https://github.com/redstone-finance/warp#readme", "dependencies": { "@assemblyscript/loader": "^0.19.23", "@idena/vrf-js": "^1.0.1", diff --git a/src/__tests__/integration/wasm/as-deploy-write-read.test.ts b/src/__tests__/integration/wasm/as-deploy-write-read.test.ts index 5dc6ddc..d937147 100644 --- a/src/__tests__/integration/wasm/as-deploy-write-read.test.ts +++ b/src/__tests__/integration/wasm/as-deploy-write-read.test.ts @@ -22,7 +22,7 @@ describe('Testing the Warp client for AssemblyScript WASM contract', () => { let arweave: Arweave; let arlocal: ArLocal; - let smartweave: Warp; + let warp: Warp; let contract: Contract; beforeAll(async () => { @@ -39,7 +39,7 @@ describe('Testing the Warp client for AssemblyScript WASM contract', () => { LoggerFactory.INST.logLevel('error'); - smartweave = WarpNodeFactory.forTesting(arweave); + warp = WarpNodeFactory.forTesting(arweave); wallet = await arweave.wallets.generate(); await addFunds(arweave, wallet); @@ -48,14 +48,14 @@ describe('Testing the Warp client for AssemblyScript WASM contract', () => { initialState = fs.readFileSync(path.join(__dirname, '../data/wasm/counter-init-state.json'), 'utf8'); // deploying contract using the new SDK. - contractTxId = await smartweave.createContract.deploy({ + contractTxId = await warp.createContract.deploy({ wallet, initState: initialState, src: contractSrc, wasmSrcCodeDir: path.join(__dirname, '../data/wasm/as/assembly') }); - contract = smartweave.contract(contractTxId).setEvaluationOptions({ + contract = warp.contract(contractTxId).setEvaluationOptions({ gasLimit: 1000000000 }); contract.connect(wallet); diff --git a/src/__tests__/integration/wasm/go-deploy-write-read.test.ts b/src/__tests__/integration/wasm/go-deploy-write-read.test.ts index a346de9..360efcc 100644 --- a/src/__tests__/integration/wasm/go-deploy-write-read.test.ts +++ b/src/__tests__/integration/wasm/go-deploy-write-read.test.ts @@ -15,7 +15,7 @@ describe('Testing the Go WASM Profit Sharing Token', () => { let arweave: Arweave; let arlocal: ArLocal; - let smartweave: Warp; + let warp: Warp; let pst: PstContract; let contractTxId: string; @@ -37,7 +37,7 @@ describe('Testing the Go WASM Profit Sharing Token', () => { LoggerFactory.INST.logLevel('error'); - smartweave = WarpNodeFactory.forTesting(arweave); + warp = WarpNodeFactory.forTesting(arweave); wallet = await arweave.wallets.generate(); await addFunds(arweave, wallet); @@ -58,14 +58,14 @@ describe('Testing the Go WASM Profit Sharing Token', () => { }; // deploying contract using the new SDK. - contractTxId = await smartweave.createContract.deploy({ + contractTxId = await warp.createContract.deploy({ wallet, initState: JSON.stringify(initialState), src: contractSrc, wasmSrcCodeDir: path.join(__dirname, '../data/wasm/go/src') }); - properForeignContractTxId = await smartweave.createContract.deploy({ + properForeignContractTxId = await warp.createContract.deploy({ wallet, initState: JSON.stringify({ ...initialState, @@ -78,7 +78,7 @@ describe('Testing the Go WASM Profit Sharing Token', () => { wasmSrcCodeDir: path.join(__dirname, '../data/wasm/go/src') }); - wrongForeignContractTxId = await smartweave.createContract.deploy({ + wrongForeignContractTxId = await warp.createContract.deploy({ wallet, initState: JSON.stringify({ ...initialState, @@ -92,7 +92,7 @@ describe('Testing the Go WASM Profit Sharing Token', () => { }); // connecting to the PST contract - pst = smartweave.pst(contractTxId); + pst = warp.pst(contractTxId); // connecting wallet to the PST contract pst.connect(wallet); diff --git a/src/__tests__/integration/wasm/rust-deploy-write-read.test.ts b/src/__tests__/integration/wasm/rust-deploy-write-read.test.ts index f62baac..271035d 100644 --- a/src/__tests__/integration/wasm/rust-deploy-write-read.test.ts +++ b/src/__tests__/integration/wasm/rust-deploy-write-read.test.ts @@ -16,7 +16,7 @@ describe('Testing the Rust WASM Profit Sharing Token', () => { let arweave: Arweave; let arlocal: ArLocal; - let smartweave: Warp; + let warp: Warp; let pst: PstContract; let contractTxId: string; @@ -42,7 +42,7 @@ describe('Testing the Rust WASM Profit Sharing Token', () => { LoggerFactory.INST.logLevel('error'); - smartweave = WarpNodeFactory.forTesting(arweave); + warp = WarpNodeFactory.forTesting(arweave); wallet = await arweave.wallets.generate(); await addFunds(arweave, wallet); @@ -63,7 +63,7 @@ describe('Testing the Rust WASM Profit Sharing Token', () => { }; // deploying contract using the new SDK. - contractTxId = await smartweave.createContract.deploy({ + contractTxId = await warp.createContract.deploy({ wallet, initState: JSON.stringify(initialState), src: contractSrc, @@ -71,7 +71,7 @@ describe('Testing the Rust WASM Profit Sharing Token', () => { wasmGlueCode: path.join(__dirname, '../data/wasm/rust/rust-pst.js') }); - properForeignContractTxId = await smartweave.createContract.deploy({ + properForeignContractTxId = await warp.createContract.deploy({ wallet, initState: JSON.stringify({ ...initialState, @@ -85,7 +85,7 @@ describe('Testing the Rust WASM Profit Sharing Token', () => { wasmGlueCode: path.join(__dirname, '../data/wasm/rust/rust-pst.js') }); - wrongForeignContractTxId = await smartweave.createContract.deploy({ + wrongForeignContractTxId = await warp.createContract.deploy({ wallet, initState: JSON.stringify({ ...initialState, @@ -100,7 +100,7 @@ describe('Testing the Rust WASM Profit Sharing Token', () => { }); // connecting to the PST contract - pst = smartweave.pst(contractTxId); + pst = warp.pst(contractTxId); // connecting wallet to the PST contract pst.connect(wallet); diff --git a/tools/bundle.ts b/tools/bundle.ts index 523ef93..1f066dc 100644 --- a/tools/bundle.ts +++ b/tools/bundle.ts @@ -2,7 +2,7 @@ import Arweave from 'arweave'; import { LoggerFactory, - SmartWeaveNodeFactory + WarpNodeFactory } from '../src'; import { TsLogFactory } from '../src/logging/node/TsLogFactory'; import path from "path"; @@ -38,7 +38,7 @@ async function main() { useNullAsDefault: true }); - const smartweave = await SmartWeaveNodeFactory.knexCached(arweave, knexConfig); + const warp = await WarpNodeFactory.knexCached(arweave, knexConfig); const wallet: JWKInterface = readJSON('.secrets/33F0QHcb22W7LwWR1iRC8Az1ntZG09XQ03YWuw2ABqA.json'); @@ -46,7 +46,7 @@ async function main() { const initialState = fs.readFileSync(path.join(__dirname, 'data/js/token-pst.json'), 'utf8'); // case 1 - full deploy, js contract - const contractTxId = await smartweave.createContract.deploy({ + const contractTxId = await warp.createContract.deploy({ wallet, initState: initialState, src: jsContractSrc, @@ -55,7 +55,7 @@ async function main() { logger.info("tx id:", contractTxId); // connecting to a given contract - const token = smartweave + const token = warp .contract(contractTxId) // connecting wallet to a contract. It is required before performing any "writeInteraction" // calling "writeInteraction" without connecting to a wallet first will cause a runtime error. @@ -76,10 +76,10 @@ async function main() { target: "33F0QHcb22W7LwWR1iRC8Az1ntZG09XQ03YWuw2ABqA", qty: 10 }, [{ - name: SmartWeaveTags.INTERACT_WRITE, + name: WarpTags.INTERACT_WRITE, value: "33F0QHcb22W7LwWR1iRC8Az1ntZG09XQ03YWuw2ABqA" },{ - name: SmartWeaveTags.INTERACT_WRITE, + name: WarpTags.INTERACT_WRITE, value: "4MnaOd-GvsE5iVQD4OhdY8DOrH3vo0QEqOw31HeIzQ0" } ]);*/ diff --git a/tools/call-stack.ts b/tools/call-stack.ts index fc2bc13..816359a 100644 --- a/tools/call-stack.ts +++ b/tools/call-stack.ts @@ -4,7 +4,7 @@ import { LoggerFactory, mapReplacer } from '../src'; import { TsLogFactory } from '../src/logging/node/TsLogFactory'; import fs from 'fs'; import path from 'path'; -import { SmartWeaveWebFactory } from '../src/core/web/SmartWeaveWebFactory'; +import { WarpWebFactory } from '../src/core/web/WarpWebFactory'; async function main() { LoggerFactory.use(new TsLogFactory()); @@ -20,9 +20,9 @@ async function main() { const contractTxId = 'LppT1p3wri4FCKzW5buohsjWxpJHC58_rgIO-rYTMB8'; - const smartweave = SmartWeaveWebFactory.memCached(arweave); + const warp = WarpWebFactory.memCached(arweave); - const contract = smartweave.contract(contractTxId).setEvaluationOptions({ + const contract = warp.contract(contractTxId).setEvaluationOptions({ ignoreExceptions: false, stackTrace: { saveState: false diff --git a/tools/contract-testnet.js b/tools/contract-testnet.js index e9611e3..e6704c2 100644 --- a/tools/contract-testnet.js +++ b/tools/contract-testnet.js @@ -6,7 +6,7 @@ const {TsLogFactory} = require('../lib/cjs/logging/node/TsLogFactory'); const fs = require('fs'); const path =require('path'); const {readContract} = require("smartweave"); -const {SmartWeaveNodeFactory} = require("../lib/cjs/core/node/SmartWeaveNodeFactory"); +const {WarpNodeFactory} = require("../lib/cjs/core/node/WarpNodeFactory"); const logger = LoggerFactory.INST.create('Contract'); @@ -20,7 +20,7 @@ async function main() { protocol: 'https', port: 443, }); - /*const result = await SmartWeaveNodeFactory + /*const result = await WarpNodeFactory .memCached(arweave) .contract("dKR4CTZUei9Q7L0n37WXs8pOOMP-WOyg0_2DSprdag4") .readState();*/ diff --git a/tools/contract-wasm.ts b/tools/contract-wasm.ts index 8c98a4a..1d64b96 100644 --- a/tools/contract-wasm.ts +++ b/tools/contract-wasm.ts @@ -5,8 +5,8 @@ import { BlockHeightInteractionsSorter, Contract, DefaultEvaluationOptions, LexicographicalInteractionsSorter, LoggerFactory, - SmartWeave, - SmartWeaveNodeFactory + Warp, + WarpNodeFactory } from '../src'; import {TsLogFactory} from '../src/logging/node/TsLogFactory'; import fs from 'fs'; @@ -16,7 +16,7 @@ import {JWKInterface} from 'arweave/node/lib/wallet'; async function main() { let wallet: JWKInterface; - let smartweave: SmartWeave; + let warp: Warp; LoggerFactory.use(new TsLogFactory()); LoggerFactory.INST.logLevel('error'); @@ -34,7 +34,7 @@ async function main() { }); try { - smartweave = SmartWeaveNodeFactory.memCached(arweave); + warp = WarpNodeFactory.memCached(arweave); wallet = await arweave.wallets.generate(); const walletAddress = await arweave.wallets.getAddress(wallet); @@ -44,13 +44,13 @@ async function main() { const initialState = fs.readFileSync(path.join(__dirname, 'data/wasm/counter-init-state.json'), 'utf8'); - const contractTxId = await smartweave.createContract.deploy({ + const contractTxId = await warp.createContract.deploy({ wallet, initState: initialState, src: contractSrc }); - const contract = smartweave.contract(contractTxId).connect(wallet).setEvaluationOptions({ + const contract = warp.contract(contractTxId).connect(wallet).setEvaluationOptions({ ignoreExceptions: true, gasLimit: 12000000 }); diff --git a/tools/contract.ts b/tools/contract.ts index 19e341e..f67a28a 100644 --- a/tools/contract.ts +++ b/tools/contract.ts @@ -1,6 +1,6 @@ /* eslint-disable */ import Arweave from 'arweave'; -import {LoggerFactory, SmartWeaveNodeFactory} from '../src'; +import {LoggerFactory, WarpNodeFactory} from '../src'; import * as fs from 'fs'; import knex from 'knex'; import os from 'os'; @@ -46,9 +46,9 @@ async function main() { }, useNullAsDefault: true }); - const smartweave = (await SmartWeaveNodeFactory.knexCachedBased(arweave, knexConfig, 1)) + const warp = (await WarpNodeFactory.knexCachedBased(arweave, knexConfig, 1)) .useRedStoneGateway().build(); - const contract = smartweave.contract("3vAx5cIFhwMihrNJgGx3CoAeZTOjG7LeIs9tnbBfL14"); + const contract = warp.contract("3vAx5cIFhwMihrNJgGx3CoAeZTOjG7LeIs9tnbBfL14"); await contract.readState(); await contract.readState(); diff --git a/tools/deploytest.ts b/tools/deploytest.ts index 6782c86..02f28be 100644 --- a/tools/deploytest.ts +++ b/tools/deploytest.ts @@ -1,6 +1,6 @@ /* eslint-disable */ import Arweave from 'arweave'; -import {LoggerFactory, SmartWeaveNodeFactory} from '../src'; +import {LoggerFactory, WarpNodeFactory} from '../src'; import {TsLogFactory} from '../src/logging/node/TsLogFactory'; import fs from 'fs'; import path from 'path'; @@ -18,28 +18,28 @@ async function main() { }); try { - const smartweave = SmartWeaveNodeFactory.memCached(arweave); + const warp = WarpNodeFactory.memCached(arweave); const jsContractSrc = fs.readFileSync(path.join(__dirname, 'data/js/token-pst.js'), 'utf8'); const wasmContractSrc = fs.readFileSync(path.join(__dirname, 'data/rust/rust-pst_bg.wasm')); const initialState = fs.readFileSync(path.join(__dirname, 'data/js/token-pst.json'), 'utf8'); // case 1 - full deploy, js contract - const contractTxId = await smartweave.createContract.deploy({ + const contractTxId = await warp.createContract.deploy({ wallet, initState: initialState, src: jsContractSrc, }, true); // case 2 - deploy from source, js contract - /*const contractTxId = await smartweave.createContract.deployFromSourceTx({ + /*const contractTxId = await warp.createContract.deployFromSourceTx({ wallet, initState: initialState, srcTxId: "Hj0S0iK5rG8yVf_5u-usb9vRZg1ZFkylQLXu6rcDt-0", }, true);*/ // case 3 - full deploy, wasm contract - /*const contractTxId = await smartweave.createContract.deploy({ + /*const contractTxId = await warp.createContract.deploy({ wallet, initState: initialState, src: wasmContractSrc, @@ -48,13 +48,13 @@ async function main() { }, true);*/ // case 4 - deploy from source, wasm contract - /*const contractTxId = await smartweave.createContract.deployFromSourceTx({ + /*const contractTxId = await warp.createContract.deployFromSourceTx({ wallet, initState: initialState, srcTxId: "5wXT-A0iugP9pWEyw-iTbB0plZ_AbmvlNKyBfGS3AUY", }, true);*/ - const contract = smartweave.contract(contractTxId).connect(wallet); + const contract = warp.contract(contractTxId).connect(wallet); await contract.bundleInteraction({ function: "storeBalance", diff --git a/tools/inner-write-2.ts b/tools/inner-write-2.ts index b8ee1c9..5b52a56 100644 --- a/tools/inner-write-2.ts +++ b/tools/inner-write-2.ts @@ -1,6 +1,6 @@ /* eslint-disable */ import Arweave from 'arweave'; -import { Contract, LoggerFactory, SmartWeave, SmartWeaveNodeFactory } from '../src'; +import { Contract, LoggerFactory, Warp, WarpNodeFactory } from '../src'; import { TsLogFactory } from '../src/logging/node/TsLogFactory'; import fs from 'fs'; import path from 'path'; @@ -16,7 +16,7 @@ async function main() { let wallet: JWKInterface; let walletAddress: string; - let smartweave: SmartWeave; + let warp: Warp; let contractA: Contract; let contractB: Contract; let contractC: Contract; @@ -43,7 +43,7 @@ async function main() { }); try { - smartweave = SmartWeaveNodeFactory.memCached(arweave); + warp = WarpNodeFactory.memCached(arweave); wallet = await arweave.wallets.generate(); @@ -64,20 +64,20 @@ async function main() { 'utf8' ); - contractATxId = await smartweave.createContract.deploy({ + contractATxId = await warp.createContract.deploy({ wallet, initState: contractAInitialState, src: contractASrc }); - contractBTxId = await smartweave.createContract.deploy({ + contractBTxId = await warp.createContract.deploy({ wallet, initState: contractBInitialState, src: contractBSrc }); - contractA = smartweave.contract(contractATxId).setEvaluationOptions({ internalWrites: true }).connect(wallet); - contractB = smartweave.contract(contractBTxId).setEvaluationOptions({ internalWrites: true }).connect(wallet); + contractA = warp.contract(contractATxId).setEvaluationOptions({ internalWrites: true }).connect(wallet); + contractB = warp.contract(contractBTxId).setEvaluationOptions({ internalWrites: true }).connect(wallet); await mine(); @@ -132,11 +132,11 @@ async function main() { logger.info('ContractA -805 :', (await contractA.readState()).state.counter); logger.info('ContractB -2060 :', (await contractB.readState()).state.counter); - const contractA2 = SmartWeaveNodeFactory.memCached(arweave) + const contractA2 = WarpNodeFactory.memCached(arweave) .contract(contractATxId) .setEvaluationOptions({ internalWrites: true }) .connect(wallet); - const contractB2 = SmartWeaveNodeFactory.memCached(arweave) + const contractB2 = WarpNodeFactory.memCached(arweave) .contract(contractBTxId) .setEvaluationOptions({ internalWrites: true }) .connect(wallet); diff --git a/tools/inner-write.ts b/tools/inner-write.ts index e76610c..e02b2c3 100644 --- a/tools/inner-write.ts +++ b/tools/inner-write.ts @@ -1,6 +1,6 @@ /* eslint-disable */ import Arweave from 'arweave'; -import { Contract, LoggerFactory, SmartWeave, SmartWeaveNodeFactory } from '../src'; +import { Contract, LoggerFactory, Warp, WarpNodeFactory } from '../src'; import { TsLogFactory } from '../src/logging/node/TsLogFactory'; import fs from 'fs'; import path from 'path'; @@ -15,7 +15,7 @@ async function main() { let wallet: JWKInterface; let walletAddress: string; - let smartweave: SmartWeave; + let warp: Warp; let calleeContract: Contract; let callingContract: Contract; let calleeTxId; @@ -38,7 +38,7 @@ async function main() { }); try { - smartweave = SmartWeaveNodeFactory.memCached(arweave); + warp = WarpNodeFactory.memCached(arweave); wallet = await arweave.wallets.generate(); walletAddress = await arweave.wallets.jwkToAddress(wallet); @@ -53,23 +53,23 @@ async function main() { ); // deploying contract using the new SDK. - calleeTxId = await smartweave.createContract.deploy({ + calleeTxId = await warp.createContract.deploy({ wallet, initState: JSON.stringify({ counter: 100 }), src: calleeContractSrc }); - const callingTxId = await smartweave.createContract.deploy({ + const callingTxId = await warp.createContract.deploy({ wallet, initState: JSON.stringify({ ticker: 'WRITING_CONTRACT' }), src: callingContractSrc }); - calleeContract = smartweave.contract(calleeTxId).connect(wallet).setEvaluationOptions({ + calleeContract = warp.contract(calleeTxId).connect(wallet).setEvaluationOptions({ ignoreExceptions: false, internalWrites: true, }); - callingContract = smartweave.contract(callingTxId).connect(wallet).setEvaluationOptions({ + callingContract = warp.contract(callingTxId).connect(wallet).setEvaluationOptions({ ignoreExceptions: false, internalWrites: true }); diff --git a/tools/interactions-from-other-contract.ts b/tools/interactions-from-other-contract.ts index 591b3a4..58e4124 100644 --- a/tools/interactions-from-other-contract.ts +++ b/tools/interactions-from-other-contract.ts @@ -5,7 +5,7 @@ import { MemCache, RedstoneGatewayContractDefinitionLoader, RedstoneGatewayInteractionsLoader, - SmartWeaveNodeFactory + WarpNodeFactory } from '../src'; import * as fs from 'fs'; import knex from 'knex'; @@ -34,7 +34,7 @@ async function main() { const loader = new FromContractInteractionsLoader(jsContractTxId); - const smartweave = SmartWeaveNodeFactory.memCachedBased(arweave) + const smartweave = WarpNodeFactory.memCachedBased(arweave) .setInteractionsLoader(loader) .build(); diff --git a/tools/separate-sign.ts b/tools/separate-sign.ts index 94065cb..c99c237 100644 --- a/tools/separate-sign.ts +++ b/tools/separate-sign.ts @@ -1,6 +1,6 @@ /* eslint-disable */ import Arweave from 'arweave'; -import {LoggerFactory, SmartWeaveNodeFactory} from '../src'; +import {LoggerFactory, WarpNodeFactory} from '../src'; import {TsLogFactory} from '../src/logging/node/TsLogFactory'; import fs from 'fs'; import path from 'path'; @@ -20,14 +20,14 @@ async function main() { }); try { - const smartweave = SmartWeaveNodeFactory + const warp = WarpNodeFactory .memCachedBased(arweave) .useRedStoneGateway() .build(); let customSignCalled = false; - const result = await smartweave.contract("Daj-MNSnH55TDfxqC7v4eq0lKzVIwh98srUaWqyuZtY") + const result = await warp.contract("Daj-MNSnH55TDfxqC7v4eq0lKzVIwh98srUaWqyuZtY") .connect(/*wallet*/async (tx) => { logger.info("Custom sign function"); customSignCalled = true; diff --git a/tools/sorting-transactions.ts b/tools/sorting-transactions.ts index 2a3c428..30d7e10 100644 --- a/tools/sorting-transactions.ts +++ b/tools/sorting-transactions.ts @@ -5,8 +5,8 @@ import { BlockHeightInteractionsSorter, Contract, DefaultEvaluationOptions, LexicographicalInteractionsSorter, LoggerFactory, RedstoneGatewayInteractionsLoader, - SmartWeave, - SmartWeaveNodeFactory + Warp, + WarpNodeFactory } from '../src'; import {TsLogFactory} from '../src/logging/node/TsLogFactory'; import fs from 'fs'; diff --git a/tools/stake.ts b/tools/stake.ts index 309fbed..ba94589 100644 --- a/tools/stake.ts +++ b/tools/stake.ts @@ -1,6 +1,6 @@ /* eslint-disable */ import Arweave from 'arweave'; -import { Contract, LoggerFactory, SmartWeave, SmartWeaveNodeFactory } from '../src'; +import { Contract, LoggerFactory, Warp, WarpNodeFactory } from '../src'; import { TsLogFactory } from '../src/logging/node/TsLogFactory'; import fs from 'fs'; import path from 'path'; @@ -21,7 +21,7 @@ async function main() { let wallet: JWKInterface; let walletAddress: string; - let smartweave: SmartWeave; + let warp: Warp; LoggerFactory.use(new TsLogFactory()); LoggerFactory.INST.logLevel('debug'); @@ -42,7 +42,7 @@ async function main() { }); try { - smartweave = SmartWeaveNodeFactory.memCached(arweave); + warp = WarpNodeFactory.memCached(arweave); wallet = await arweave.wallets.generate(); walletAddress = await arweave.wallets.jwkToAddress(wallet); @@ -65,7 +65,7 @@ async function main() { 'utf8' ); - tokenContractTxId = await smartweave.createContract.deploy({ + tokenContractTxId = await warp.createContract.deploy({ wallet, initState: JSON.stringify({ ...JSON.parse(tokenContractInitialState), @@ -74,7 +74,7 @@ async function main() { src: tokenContractSrc }); - stakingContractTxId = await smartweave.createContract.deploy({ + stakingContractTxId = await warp.createContract.deploy({ wallet, initState: JSON.stringify({ ...JSON.parse(stakingContractInitialState), @@ -83,11 +83,11 @@ async function main() { src: stakingContractSrc }); - tokenContract = smartweave + tokenContract = warp .contract(tokenContractTxId) .setEvaluationOptions({ internalWrites: true }) .connect(wallet); - stakingContract = smartweave + stakingContract = warp .contract(stakingContractTxId) .setEvaluationOptions({ internalWrites: true }) .connect(wallet); diff --git a/tools/sync-state.ts b/tools/sync-state.ts index 8d4e8e7..9ab2ef8 100644 --- a/tools/sync-state.ts +++ b/tools/sync-state.ts @@ -1,6 +1,6 @@ /* eslint-disable */ import Arweave from 'arweave'; -import {LoggerFactory, SmartWeaveNodeFactory} from '../src'; +import {LoggerFactory, WarpNodeFactory} from '../src'; import fs from 'fs'; import {JWKInterface} from 'arweave/node/lib/wallet'; import {TsLogFactory} from "../src/logging/node/TsLogFactory"; @@ -17,7 +17,7 @@ async function main() { }); try { - const contract = await SmartWeaveNodeFactory.memCached(arweave) + const contract = await WarpNodeFactory.memCached(arweave) .contract("XIutiOKujGI21_ywULlBeyy-L9d8goHxt0ZyUayGaDg") .syncState("http://134.209.84.136:8080"); diff --git a/tools/write-check.ts b/tools/write-check.ts index 4cca874..345abf9 100644 --- a/tools/write-check.ts +++ b/tools/write-check.ts @@ -4,7 +4,7 @@ import { LoggerFactory } from '../src'; import { TsLogFactory } from '../src/logging/node/TsLogFactory'; import fs from 'fs'; import path from 'path'; -import { SmartWeaveWebFactory } from '../src/core/web/SmartWeaveWebFactory'; +import { WarpWebFactory } from '../src/core/web/WarpWebFactory'; import { FromFileInteractionsLoader } from './FromFileInteractionsLoader'; import { readContract } from 'smartweave'; import { readJSON } from '../../redstone-smartweave-examples/src/_utils'; @@ -21,7 +21,7 @@ async function main() { logging: false // Enable network request logging }); - const smartweave = SmartWeaveWebFactory.memCached(arweave); + const smartweave = WarpWebFactory.memCached(arweave); const jwk = readJSON('../redstone-node/.secrets/redstone-jwk.json');