Skip to content

Commit

Permalink
Fix build issues from codegen changes
Browse files Browse the repository at this point in the history
  • Loading branch information
stwiname committed Dec 20, 2023
1 parent adbaef1 commit 78b7854
Show file tree
Hide file tree
Showing 6 changed files with 27 additions and 233 deletions.
27 changes: 15 additions & 12 deletions .github/scripts/ci.package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,29 +3,32 @@
"private": true,
"workspaces": [
"Agoric/*",
"Akash/*",
"Archway/*",
"Axelar/*",
"Cheqd/*",
"Comdex/*",
"CosmosHub/*",
"Dymension/*",
"Evmos/*",
"Injective/*",
"Kava/*",
"Migaloo/*",
"OKX/*",
"Osmosis/*",
"Sei/*",
"Thorchain/*",
"Akash/*",
"Axelar/*",
"Comdex/*",
"Cronos/*",
"Fetch.ai/*",
"Injective/*",
"Iris/*",
"Jackal/*",
"Juno/*",
"Kava/kava-starter",
"Kujira/*",
"Mars/*",
"Migaloo/*",
"Multi-Chain/*",
"Neutron/*",
"Omniflixhub/*",
"Osmosis/*",
"Persistence/*",
"Sei/*",
"Stargaze/*",
"Umee/*"
"Thorchain/*",
"UmeeX/*"
],
"scripts": {
"codegen": "yarn workspaces run codegen",
Expand Down
4 changes: 2 additions & 2 deletions Injective/injective-starter/src/mappings/mappingHandlers.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { SpotLimitOrder } from "../types";
import { MsgCreateSpotLimitOrderMessage } from "../types/CosmosMessageTypes";
import * as messages from "../types/CosmosMessageTypes";

/*
export async function handleBlock(block: CosmosBlock): Promise<void> {
Expand Down Expand Up @@ -44,7 +44,7 @@ export async function handleEvent(event: CosmosEvent): Promise<void> {
*/

export async function handleMessage(
msg: MsgCreateSpotLimitOrderMessage
msg: messages.injective.exchange.v1beta1.tx.MsgCreateSpotLimitOrderMessage
): Promise<void> {
//logger.info(JSON.stringify(msg));
const spotLimitOrder = SpotLimitOrder.create({
Expand Down
2 changes: 1 addition & 1 deletion Kava/kava-evm-starter/package.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"name": "okx-starter",
"name": "kava-evm-starter",
"version": "0.0.1",
"description": "This project can be use as a starting point for developing your Cosmos (Kava) based SubQuery project via the Etheruem API",
"main": "dist/index.js",
Expand Down
205 changes: 0 additions & 205 deletions Kujira/kujira-starter/proto/kujira/oracle/query.proto

This file was deleted.

18 changes: 7 additions & 11 deletions Osmosis/osmosis-starter/src/mappings/mappingHandlers.ts
Original file line number Diff line number Diff line change
@@ -1,8 +1,4 @@
import {
MsgSwapExactAmountInMessage,
MsgSwapExactAmountOutMessage,
MsgJoinSwapShareAmountOutMessage,
} from "../types/CosmosMessageTypes";
import * as messages from "../types/CosmosMessageTypes";
import { Pool, Swap, SwapRoute, Direction, Message } from "../types";
import { CosmosBlock } from "@subql/types-cosmos";

Expand All @@ -22,9 +18,9 @@ async function checkGetPool(id: string, block: CosmosBlock): Promise<Pool> {

function createSwap(
msg:
| MsgSwapExactAmountInMessage
| MsgSwapExactAmountOutMessage
| MsgJoinSwapShareAmountOutMessage,
| messages.osmosis.gamm.v1beta1.tx.MsgSwapExactAmountInMessage
| messages.osmosis.gamm.v1beta1.tx.MsgSwapExactAmountOutMessage
| messages.osmosis.gamm.v1beta1.tx.MsgJoinSwapShareAmountOutMessage,
direction: Direction,
message: Message
): Swap {
Expand All @@ -40,7 +36,7 @@ function createSwap(
}

export async function handleMsgSwapExactAmountIn(
msg: MsgSwapExactAmountInMessage
msg: messages.osmosis.gamm.v1beta1.tx.MsgSwapExactAmountInMessage
): Promise<void> {
logger.info(
`Processing MsgSwapExactAmountIn at block ${msg.block.header.height.toString()}`
Expand Down Expand Up @@ -76,7 +72,7 @@ export async function handleMsgSwapExactAmountIn(
}

export async function handleMsgSwapExactAmountOut(
msg: MsgSwapExactAmountOutMessage
msg: messages.osmosis.gamm.v1beta1.tx.MsgSwapExactAmountOutMessage
): Promise<void> {
logger.info(
`Processing MsgSwapExactAmountOut at block ${msg.block.header.height.toString()}`
Expand Down Expand Up @@ -112,7 +108,7 @@ export async function handleMsgSwapExactAmountOut(
}

export async function handleMsgJoinSwapShareAmountOut(
msg: MsgJoinSwapShareAmountOutMessage
msg: messages.osmosis.gamm.v1beta1.tx.MsgJoinSwapShareAmountOutMessage
): Promise<void> {
logger.info(
`Processing MsgJoinSwapShareAmountOut at block ${msg.block.header.height.toString()}`
Expand Down
4 changes: 2 additions & 2 deletions Thorchain/thorchain-starter/src/mappings/mappingHandlers.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { Coin, Deposit, DepositCoin } from "../types";
import { MsgDepositMessage } from "../types/CosmosMessageTypes";
import * as messages from "../types/CosmosMessageTypes";

/*
export async function handleBlock(block: CosmosBlock): Promise<void> {
Expand All @@ -19,7 +19,7 @@ export async function handleTransaction(tx: CosmosTransaction): Promise<void> {
}
*/

export async function handleMessage(msg: MsgDepositMessage): Promise<void> {
export async function handleMessage(msg: messages.thorchain.v1.x.thorchain.types.msg_deposit.MsgDepositMessage): Promise<void> {
// Create Deposit record
const depositEntity = Deposit.create({
id: `${msg.tx.hash}-${msg.idx}`,
Expand Down

0 comments on commit 78b7854

Please sign in to comment.