chore: use pnpm 9

Signed-off-by: bestmike007 <i@bestmike007.com>
This commit is contained in:
bestmike007
2024-04-19 07:35:41 -05:00
parent a2722b364c
commit 0d9f174714
15 changed files with 4261 additions and 3547 deletions

View File

@@ -1,2 +1,2 @@
nodejs 20.12.2
yarn 1.22.19
pnpm 9.0.4

View File

@@ -37,13 +37,13 @@
"memoizee": "^0.4.15",
"ramda": "^0.29.1",
"safe-json-stringify": "^1.2.0",
"slonik": "^40.2.5",
"slonik": "^41.0.0",
"ts-clarity": "^0.0.20",
"yargs-parser": "^21.1.1",
"zod": "^3.22.4"
"zod": "^3.22.5"
},
"devDependencies": {
"@swc/core": "^1.4.14",
"@swc/core": "^1.4.16",
"@types/cors": "^2.8.17",
"@types/express": "^4.17.21",
"@types/memoizee": "^0.4.11",

4231
pnpm-lock.yaml generated Normal file

File diff suppressed because it is too large Load Diff

View File

@@ -1,7 +1,7 @@
import { TransactionVersion } from '@stacks/common';
import { hashSha256Sync } from '@stacks/encryption';
import { getAddressFromPrivateKey } from '@stacks/transactions';
import assert from 'assert';
import assert from 'node:assert';
import {
kSponsorAccountCount,
kSponsorAddress,

View File

@@ -10,7 +10,6 @@ import {
generateWallet,
getStxAddress,
} from '@stacks/wallet-sdk';
import got from 'got-cjs';
import { getRequiredEnv, kStacksEndpoint } from '../config';
import { stringify } from '../util';
@@ -51,17 +50,19 @@ async function main() {
tx_bytes.byteLength,
);
const rs = await got
.post('https://sponsor-tx.alexgo.dev/v1/graphql', {
json: {
query: `mutation MyMutation {
const rs = await fetch('https://sponsor-tx.alexgo.dev/v1/graphql', {
method: 'POST',
body: JSON.stringify({
query: `mutation MyMutation {
execute(tx: "${tx_buffer.toString('hex')}")
}`,
variables: null,
operationName: 'MyMutation',
},
})
.json();
variables: null,
operationName: 'MyMutation',
}),
headers: {
'Content-Type': 'application/json',
},
}).then(rs => rs.json());
console.log(stringify(rs));
}

View File

@@ -1,4 +1,4 @@
import assert from 'assert';
import assert from 'node:assert';
export function getOptionalEnv(envKey: string) {
return process.env[envKey];

View File

@@ -4,8 +4,8 @@ import {
createNumericTypeParser,
createPool,
createSqlTag,
DatabasePool,
PrimitiveValueExpression,
type DatabasePool,
type PrimitiveValueExpression,
} from 'slonik';
import { fromUint8Array } from 'ts-clarity';
import z from 'zod';

View File

@@ -9,8 +9,8 @@ import {
cvToString,
deserializeTransaction,
} from '@stacks/transactions';
import assert from 'assert';
import { RequestHandler } from 'express';
import type { RequestHandler } from 'express';
import assert from 'node:assert';
import { getAccountNonces } from 'ts-clarity';
import {
kMaxTransactionsPerBlock,

View File

@@ -1,8 +1,8 @@
import {
PayloadType,
StacksMessageType,
StacksTransaction,
addressToString,
type StacksTransaction,
} from '@stacks/transactions';
import { getPgPool, sql } from './db';

View File

@@ -1,4 +1,4 @@
import { TypeParser } from 'slonik';
import type { TypeParser } from 'slonik';
import { hexToBuffer } from './utils';
const byteaParser = (value: string) => {

View File

@@ -1,4 +1,4 @@
import { TypeParser } from 'slonik';
import type { TypeParser } from 'slonik';
const numericParser = (value: string) => {
return BigInt(value.replace(/\.[0]*$/, ''));

View File

@@ -6,9 +6,9 @@ import {
estimateTransactionFeeWithFallback,
sponsorTransaction,
} from '@stacks/transactions';
import assert from 'assert';
import assert from 'node:assert';
import { getAccountNonces } from 'ts-clarity';
import { SponsorAccount } from './accounts';
import type { SponsorAccount } from './accounts';
import {
kFeeIncrement,
kStacksBroadcastEndpoints,

View File

@@ -7,9 +7,9 @@ import {
estimateTransactionFeeWithFallback,
sponsorTransaction,
} from '@stacks/transactions';
import assert from 'assert';
import assert from 'node:assert';
import { getAccountNonces } from 'ts-clarity';
import { SponsorAccount } from './accounts';
import type { SponsorAccount } from './accounts';
import {
kBaseFee,
kMaxTransactionsPerBlock,

View File

@@ -1,6 +1,6 @@
import { StacksMainnet, StacksMocknet } from '@stacks/network';
import type { StacksMainnet, StacksMocknet } from '@stacks/network';
import { getAccountNonces, getTransaction } from 'ts-clarity';
import { SponsorAccount } from './accounts';
import type { SponsorAccount } from './accounts';
import { SponsorRecord, getPgPool, sql } from './db';
import { stringify } from './util';

3518
yarn.lock

File diff suppressed because it is too large Load Diff