Skip to content

Commit

Permalink
Merge pull request #606 from hop-protocol/feat/core-to-v1
Browse files Browse the repository at this point in the history
Feat/core to v1
  • Loading branch information
shanefontaine authored May 20, 2024
2 parents d7e0f70 + a57e07b commit 205eb50
Show file tree
Hide file tree
Showing 349 changed files with 791 additions and 4,329 deletions.
7 changes: 0 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,13 +19,6 @@
[@hop-protocol/v2-sdk](packages/v2-sdk) | [![npm version](https://badge.fury.io/js/%40hop-protocol%2Fv2-sdk.svg)](https://badge.fury.io/js/) | V2 TypeScript Hop SDK |
[@hop-protocol/v2-hop-node](packages/v-2hop-node) | [![npm version](https://badge.fury.io/js/%40hop-protocol%2Fv2-hop-node.svg)](https://badge.fury.io/js/) | TypeScript Hop Node |

### Shared

| Lib/App | Current Version | Description |
| --- | --- | --- |
| [@hop-protocol/sdk-core](packages/sdk-core) | [![npm version](https://badge.fury.io/js/%40hop-protocol%2Fsdk-core.svg)](https://badge.fury.io/js/) | Shared Hop SDK code |
| [@hop-protocol/hop-node-core](packages/hop-node-core) | [![npm version](https://badge.fury.io/js/%40hop-protocol%2Fhop-node-core.svg)](https://badge.fury.io/js/) | Shared Hop Node code |

## Quickstart

The Hop monorepo uses [PNPM](https://pnpm.io/) for package and workspace management.
Expand Down
28 changes: 0 additions & 28 deletions packages/hop-node-core/README.md

This file was deleted.

95 changes: 0 additions & 95 deletions packages/hop-node-core/eslint.config.mjs

This file was deleted.

73 changes: 0 additions & 73 deletions packages/hop-node-core/package.json

This file was deleted.

1 change: 0 additions & 1 deletion packages/hop-node-core/src/config/index.ts

This file was deleted.

19 changes: 0 additions & 19 deletions packages/hop-node-core/src/constants/constants.ts

This file was deleted.

1 change: 0 additions & 1 deletion packages/hop-node-core/src/constants/index.ts

This file was deleted.

12 changes: 0 additions & 12 deletions packages/hop-node-core/src/index.ts

This file was deleted.

5 changes: 0 additions & 5 deletions packages/hop-node-core/src/types/error.ts

This file was deleted.

24 changes: 0 additions & 24 deletions packages/hop-node-core/src/utils/index.ts

This file was deleted.

24 changes: 22 additions & 2 deletions packages/hop-node/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -33,22 +33,36 @@
"lint": "eslint .",
"version": "pnpm version"
},
"//": "@maticnetwork/maticjs-ethers requires 3.5.0 of @maticnetwork/maticjs but 3.7.7 is needed for zkEVM compatibility as well as general compatibility",
"dependencies": {
"@arbitrum/sdk": "2.0.18",
"@aws-sdk/client-cloudwatch-logs": "3.338.0",
"@aws-sdk/client-kms": "3.338.0",
"@aws-sdk/client-lambda": "3.338.0",
"@aws-sdk/client-s3": "3.338.0",
"@aws-sdk/client-ssm": "3.338.0",
"@consensys/linea-sdk": "0.1.6",
"@eth-optimism/sdk": "3.1.4",
"@ethereumjs/tx": "5.3.0",
"@ethersproject/hdnode": "5.0.9",
"@hop-protocol/hop-node-core": "workspace:*",
"@hop-protocol/sdk": "workspace:*",
"@maticnetwork/maticjs": "3.5.0",
"@maticnetwork/maticjs-ethers": "1.0.3",
"@maticnetwork/maticjs-pos-zkevm": "npm:@maticnetwork/[email protected]",
"@slack/web-api": "7.0.1",
"@uniswap/sdk-core": "3.2.2",
"@uniswap/v3-core": "1.0.1",
"@uniswap/v3-sdk": "3.9.0",
"asn1.js": "5.4.1",
"async-mutex": "0.4.1",
"bip39": "3.1.0",
"chalk": "4.1.2",
"classic-level": "1.4.1",
"commander": "6.2.1",
"console-clear": "1.1.1",
"ethereum-block-by-date": "1.4.9",
"ethers": "5.7.2",
"keythereum": "1.2.0",
"level-party": "5.1.1",
"lodash": "4.17.21",
"luxon": "3.4.4",
Expand All @@ -57,19 +71,25 @@
"mkdirp": "3.0.1",
"nearest-date": "1.0.1",
"pidusage": "3.0.2",
"p-queue": "8.0.1",
"prom-client": "15.1.0",
"prompt": "1.3.0",
"subleveldown": "6.0.1",
"to-hex": "0.0.18"
"to-hex": "0.0.18",
"uuid": "9.0.1"
},
"devDependencies": {
"@ethereumjs/rlp": "5.0.2",
"@types/ethereum-block-by-date": "1.4.1",
"@types/lodash": "4.14.202",
"@types/luxon": "3.4.2",
"@types/minimist": "1.2.5",
"@types/keythereum": "1.2.4",
"@types/pidusage": "2.0.5",
"@types/prompt": "1.1.8",
"@types/subleveldown": "4.1.4",
"@types/uuid": "9.0.8",
"eslint-plugin-jest": "28.2.0",
"tsx": "4.7.2"
},
"homepage": "https://hop.exchange",
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
6 changes: 3 additions & 3 deletions packages/hop-node/src/cctp/cctp/Message.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,12 +8,12 @@ import {
} from './utils.js'
import { ChainSlug, getChainSlug } from '@hop-protocol/sdk'
import type { NetworkSlug } from '@hop-protocol/sdk'
import { MIN_POLYGON_GAS_PRICE } from '@hop-protocol/hop-node-core'
import { MIN_POLYGON_GAS_PRICE } from '#constants/index.js'
import type { RequiredEventFilter } from '../indexer/OnchainEventIndexer.js'
import { getRpcProvider } from '@hop-protocol/hop-node-core'
import { getRpcProvider } from '#utils/getRpcProvider.js'
import { config as globalConfig } from '#config/index.js'
import { Mutex } from 'async-mutex'
import { wait } from '@hop-protocol/hop-node-core'
import { wait } from '#utils/wait.js'

// Temp to handle API rate limit
const mutex = new Mutex()
Expand Down
2 changes: 1 addition & 1 deletion packages/hop-node/src/cctp/cctp/MessageManager.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { wallets } from '@hop-protocol/hop-node-core'
import { wallets } from '#wallets/index.js'
import type { ChainSlug } from '@hop-protocol/sdk'
import { getChainSlug } from '@hop-protocol/sdk'
import { FSMPoller } from '../fsm/FSMPoller.js'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ import { Message } from '../Message.js'
import { OnchainEventStore } from './OnchainEventStore.js'
import type { RequiredFilter } from '../../indexer/OnchainEventIndexer.js'
import { getTimestampFromBlockNumberMs } from './utils.js'
import { getRpcProvider } from '@hop-protocol/hop-node-core'
import { getRpcProvider } from '#utils/getRpcProvider.js'

export class TransitionDataProvider<T extends MessageState, U extends IMessage> implements ITransitionDataProvider<T, U> {
readonly #stores: Record<T, IDataStore>
Expand Down
2 changes: 1 addition & 1 deletion packages/hop-node/src/cctp/cctp/transitionData/utils.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { getRpcProvider } from '@hop-protocol/hop-node-core'
import { getRpcProvider } from '#utils/getRpcProvider.js'
import { getChainSlug, ChainSlug } from '@hop-protocol/sdk'

export async function getTimestampFromBlockNumberMs (chainId: number, blockNumber: number): Promise<number> {
Expand Down
2 changes: 1 addition & 1 deletion packages/hop-node/src/cctp/fsm/FSMPoller.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import type { ChainSlug } from '@hop-protocol/sdk'
import { StateMachineDB } from '../db/StateMachineDB.js'
import { TransitionDataProvider } from '../cctp/transitionData/TransitionDataProvider.js'
import { wait } from '@hop-protocol/hop-node-core'
import { wait } from '#utils/wait.js'

// TODO: Not this here
import type { IMessage, MessageState } from '../cctp/MessageManager.js'
Expand Down
Loading

0 comments on commit 205eb50

Please sign in to comment.