From 8e796f189f89f8c57ee754fbd05b0b580c36e16f Mon Sep 17 00:00:00 2001 From: Jakub Zajac Date: Tue, 8 Aug 2023 00:39:23 +0100 Subject: [PATCH 01/18] Feat: Add claimExpenditure saga --- .../ExpenditureAdvanceButton.tsx | 14 ++++ src/i18n/en.json | 2 + src/redux/actionTypes.ts | 3 + .../sagas/expenditures/claimExpenditure.ts | 78 +++++++++++++++++++ src/redux/sagas/expenditures/index.ts | 2 + src/redux/types/actions/expenditures.ts | 12 ++- 6 files changed, 110 insertions(+), 1 deletion(-) create mode 100644 src/redux/sagas/expenditures/claimExpenditure.ts diff --git a/src/components/common/Expenditures/ExpenditureDetailsPage/ExpenditureAdvanceButton/ExpenditureAdvanceButton.tsx b/src/components/common/Expenditures/ExpenditureDetailsPage/ExpenditureAdvanceButton/ExpenditureAdvanceButton.tsx index d878211904a..5a32e381d1c 100644 --- a/src/components/common/Expenditures/ExpenditureDetailsPage/ExpenditureAdvanceButton/ExpenditureAdvanceButton.tsx +++ b/src/components/common/Expenditures/ExpenditureDetailsPage/ExpenditureAdvanceButton/ExpenditureAdvanceButton.tsx @@ -70,6 +70,20 @@ const ExpenditureAdvanceButton = ({ ); } + if (expenditure.status === ExpenditureStatus.Finalized) { + return ( + + Claim funds + + ); + } + return null; }; diff --git a/src/i18n/en.json b/src/i18n/en.json index 3faa604e913..602a54b232f 100644 --- a/src/i18n/en.json +++ b/src/i18n/en.json @@ -264,6 +264,8 @@ "transaction.group.editExpenditure.description": "Edit Expenditure", "transaction.ColonyClient.cancelExpenditure.title": "Cancel Expenditure", "transaction.ColonyClient.cancelExpenditure.description": "Cancel Expenditure", + "transaction.ColonyClient.claimExpenditurePayout.title": "Claim Expenditure Payout", + "transaction.ColonyClient.claimExpenditurePayout.description": "Claim Expenditure Payout", "metatransaction.debug.description": "DEBUG: context: {context} methodName: {methodName}", "metatransaction.group.deposit.title": "Activate tokens", diff --git a/src/redux/actionTypes.ts b/src/redux/actionTypes.ts index 6e6cf194faf..4421bf4a170 100644 --- a/src/redux/actionTypes.ts +++ b/src/redux/actionTypes.ts @@ -213,4 +213,7 @@ export enum ActionTypes { EXPENDITURE_CANCEL = 'EXPENDITURE_CANCEL', EXPENDITURE_CANCEL_SUCCESS = 'EXPENDITURE_CANCEL_SUCCESS', EXPENDITURE_CANCEL_ERROR = 'EXPENDITURE_CANCEL_ERROR', + EXPENDITURE_CLAIM = 'EXPENDITURE_CLAIM', + EXPENDITURE_CLAIM_SUCCESS = 'EXPENDITURE_CLAIM_SUCCESS', + EXPENDITURE_CLAIM_ERROR = 'EXPENDITURE_CLAIM_ERROR', } diff --git a/src/redux/sagas/expenditures/claimExpenditure.ts b/src/redux/sagas/expenditures/claimExpenditure.ts new file mode 100644 index 00000000000..56f9a227080 --- /dev/null +++ b/src/redux/sagas/expenditures/claimExpenditure.ts @@ -0,0 +1,78 @@ +import { ClientType } from '@colony/colony-js'; +import { takeEvery, fork, call, put, all } from 'redux-saga/effects'; + +import { Action, ActionTypes, AllActions } from '~redux'; +import { transactionPending, transactionReady } from '~redux/actionCreators'; + +import { + createTransaction, + createTransactionChannels, + getTxChannel, +} from '../transactions'; +import { putError, takeFrom } from '../utils'; + +function* claimExpenditure({ + meta, + payload: { colonyAddress, expenditure }, +}: Action) { + const txChannel = yield call(getTxChannel, meta.id); + const batchKey = 'claimExpenditure'; + + try { + const channels = yield createTransactionChannels(meta.id, [ + ...expenditure.slots.map((slot) => slot.id.toString()), + ]); + + // Create one claim transaction for each slot + // @TODO: We should create one transaction for each token address + yield all( + expenditure.slots.map((slot) => + fork(createTransaction, channels[slot.id].id, { + context: ClientType.ColonyClient, + methodName: 'claimExpenditurePayout', + identifier: colonyAddress, + params: [ + expenditure.nativeId, + slot.id, + slot.payouts?.[0].tokenAddress ?? '', + ], + group: { + key: batchKey, + id: meta.id, + index: 0, + }, + ready: false, + }), + ), + ); + + yield all( + expenditure.slots + .map((slot) => [ + put(transactionPending(channels[slot.id].id)), + put(transactionReady(channels[slot.id].id)), + takeFrom( + channels[slot.id].channel, + ActionTypes.TRANSACTION_SUCCEEDED, + ), + ]) + .flat(), + ); + + yield put({ + type: ActionTypes.EXPENDITURE_CREATE_SUCCESS, + payload: {}, + meta, + }); + } catch (error) { + return yield putError(ActionTypes.EXPENDITURE_CLAIM_ERROR, error, meta); + } + + txChannel.close(); + + return null; +} + +export default function* claimExpenditureSaga() { + yield takeEvery(ActionTypes.EXPENDITURE_CLAIM, claimExpenditure); +} diff --git a/src/redux/sagas/expenditures/index.ts b/src/redux/sagas/expenditures/index.ts index bbc48c0df1a..1d2afd0ed35 100644 --- a/src/redux/sagas/expenditures/index.ts +++ b/src/redux/sagas/expenditures/index.ts @@ -6,6 +6,7 @@ import finalizeExpenditureSaga from './finalizeExpenditure'; import fundExpenditureSaga from './fundExpenditure'; import editExpenditureSaga from './editExpenditure'; import cancelExpenditureSaga from './cancelExpenditure'; +import claimExpenditureSaga from './claimExpenditure'; export default function* expendituresSagas() { yield all([ @@ -15,5 +16,6 @@ export default function* expendituresSagas() { call(fundExpenditureSaga), call(editExpenditureSaga), call(cancelExpenditureSaga), + call(claimExpenditureSaga), ]); } diff --git a/src/redux/types/actions/expenditures.ts b/src/redux/types/actions/expenditures.ts index 32e047b8e5a..8371673a256 100644 --- a/src/redux/types/actions/expenditures.ts +++ b/src/redux/types/actions/expenditures.ts @@ -72,4 +72,14 @@ export type ExpendituresActionTypes = object > | ErrorActionType - | UniqueActionType; + | UniqueActionType + | UniqueActionType< + ActionTypes.EXPENDITURE_CLAIM, + { + colonyAddress: Address; + expenditure: Expenditure; + }, + object + > + | ErrorActionType + | UniqueActionType; From cb3d68659a3d255c071caaa200d0f6b975907708 Mon Sep 17 00:00:00 2001 From: Jakub Zajac Date: Tue, 8 Aug 2023 00:48:06 +0100 Subject: [PATCH 02/18] Add: missing i18n messages --- src/i18n/en.json | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/i18n/en.json b/src/i18n/en.json index 602a54b232f..417026a73ab 100644 --- a/src/i18n/en.json +++ b/src/i18n/en.json @@ -264,6 +264,8 @@ "transaction.group.editExpenditure.description": "Edit Expenditure", "transaction.ColonyClient.cancelExpenditure.title": "Cancel Expenditure", "transaction.ColonyClient.cancelExpenditure.description": "Cancel Expenditure", + "transaction.group.claimExpenditure.title": "Claim Expenditure Payouts", + "transaction.group.claimExpenditure.description": "Claim Expenditure Payouts", "transaction.ColonyClient.claimExpenditurePayout.title": "Claim Expenditure Payout", "transaction.ColonyClient.claimExpenditurePayout.description": "Claim Expenditure Payout", From b532bd0838dd2a353e68ce6b606e26fd9cf399ae Mon Sep 17 00:00:00 2001 From: Jakub Zajac Date: Tue, 8 Aug 2023 00:48:36 +0100 Subject: [PATCH 03/18] Fix: claimExpenditure saga success action --- src/redux/sagas/expenditures/claimExpenditure.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/redux/sagas/expenditures/claimExpenditure.ts b/src/redux/sagas/expenditures/claimExpenditure.ts index 56f9a227080..a851fa662d3 100644 --- a/src/redux/sagas/expenditures/claimExpenditure.ts +++ b/src/redux/sagas/expenditures/claimExpenditure.ts @@ -60,7 +60,7 @@ function* claimExpenditure({ ); yield put({ - type: ActionTypes.EXPENDITURE_CREATE_SUCCESS, + type: ActionTypes.EXPENDITURE_CLAIM_SUCCESS, payload: {}, meta, }); From 42d79e7b3df7eae075c2facc46fea26e40029756 Mon Sep 17 00:00:00 2001 From: Jakub Zajac Date: Fri, 18 Aug 2023 16:32:15 +0100 Subject: [PATCH 04/18] Feat: Add `finalizedAt` field to Expenditure model --- amplify/backend/api/colonycdapp/schema.graphql | 1 + src/graphql/generated.ts | 6 ++++++ 2 files changed, 7 insertions(+) diff --git a/amplify/backend/api/colonycdapp/schema.graphql b/amplify/backend/api/colonycdapp/schema.graphql index 1b4dc50f406..43603821d2b 100644 --- a/amplify/backend/api/colonycdapp/schema.graphql +++ b/amplify/backend/api/colonycdapp/schema.graphql @@ -2528,6 +2528,7 @@ type Expenditure @model { metadata: ExpenditureMetadata @hasOne(fields: ["id"]) balances: [ExpenditureBalance!] @function(name: "fetchExpenditureBalances-${env}") + finalizedAt: AWSTimestamp } # Each expenditure can have multiple slots with one recipient and possibly multiple payouts (with different token addresses) diff --git a/src/graphql/generated.ts b/src/graphql/generated.ts index 9002c94e070..a09ede79eab 100644 --- a/src/graphql/generated.ts +++ b/src/graphql/generated.ts @@ -985,6 +985,7 @@ export type CreateExpenditureInput = { balances?: InputMaybe>; colonyId: Scalars['ID']; createdAt?: InputMaybe; + finalizedAt?: InputMaybe; id?: InputMaybe; nativeDomainId: Scalars['Int']; nativeFundingPotId: Scalars['Int']; @@ -1349,6 +1350,7 @@ export type Expenditure = { colony: Colony; colonyId: Scalars['ID']; createdAt: Scalars['AWSDateTime']; + finalizedAt?: Maybe; id: Scalars['ID']; metadata?: Maybe; nativeDomainId: Scalars['Int']; @@ -2111,6 +2113,7 @@ export type ModelExpenditureConditionInput = { and?: InputMaybe>>; colonyId?: InputMaybe; createdAt?: InputMaybe; + finalizedAt?: InputMaybe; nativeDomainId?: InputMaybe; nativeFundingPotId?: InputMaybe; nativeId?: InputMaybe; @@ -2130,6 +2133,7 @@ export type ModelExpenditureFilterInput = { and?: InputMaybe>>; colonyId?: InputMaybe; createdAt?: InputMaybe; + finalizedAt?: InputMaybe; id?: InputMaybe; nativeDomainId?: InputMaybe; nativeFundingPotId?: InputMaybe; @@ -2536,6 +2540,7 @@ export type ModelSubscriptionExpenditureFilterInput = { and?: InputMaybe>>; colonyId?: InputMaybe; createdAt?: InputMaybe; + finalizedAt?: InputMaybe; id?: InputMaybe; nativeDomainId?: InputMaybe; nativeFundingPotId?: InputMaybe; @@ -5028,6 +5033,7 @@ export type UpdateExpenditureInput = { balances?: InputMaybe>; colonyId?: InputMaybe; createdAt?: InputMaybe; + finalizedAt?: InputMaybe; id: Scalars['ID']; nativeDomainId?: InputMaybe; nativeFundingPotId?: InputMaybe; From 5731b1423f6529477f48bf1db90af515b9ac4ebd Mon Sep 17 00:00:00 2001 From: Jakub Zajac Date: Fri, 18 Aug 2023 16:32:46 +0100 Subject: [PATCH 05/18] Define AWSTimestamp in codegen.js config --- codegen.js | 1 + 1 file changed, 1 insertion(+) diff --git a/codegen.js b/codegen.js index 80c4a3653a0..039d0353bbc 100644 --- a/codegen.js +++ b/codegen.js @@ -49,6 +49,7 @@ const codegen = async () => { AWSDateTime: 'string', AWSEmail: 'string', AWSURL: 'string', + AWSTimestamp: 'number', }, }, watch: graphqlFiles, From 2a2fad42f146fa60040fa99ec49453f973024b73 Mon Sep 17 00:00:00 2001 From: Jakub Zajac Date: Fri, 18 Aug 2023 19:15:22 +0100 Subject: [PATCH 06/18] Link parameters lambda layer to fetchExpenditureBalances --- ...xpenditureBalances-cloudformation-template.json | 7 ++++++- .../function-parameters.json | 14 +++++++++++++- 2 files changed, 19 insertions(+), 2 deletions(-) diff --git a/amplify/backend/function/fetchExpenditureBalances/fetchExpenditureBalances-cloudformation-template.json b/amplify/backend/function/fetchExpenditureBalances/fetchExpenditureBalances-cloudformation-template.json index 9dcf0bcd75f..f6f929bb985 100644 --- a/amplify/backend/function/fetchExpenditureBalances/fetchExpenditureBalances-cloudformation-template.json +++ b/amplify/backend/function/fetchExpenditureBalances/fetchExpenditureBalances-cloudformation-template.json @@ -70,7 +70,12 @@ }, "Role": { "Fn::GetAtt": ["LambdaExecutionRole", "Arn"] }, "Runtime": "nodejs14.x", - "Layers": [], + "Layers": [ + { + "Ref": "functioncolonycdappSSMAccessArn" + }, + "arn:aws:lambda:eu-west-2:133256977650:layer:AWS-Parameters-and-Secrets-Lambda-Extension:4" + ], "Timeout": 25 } }, diff --git a/amplify/backend/function/fetchExpenditureBalances/function-parameters.json b/amplify/backend/function/fetchExpenditureBalances/function-parameters.json index d5078776c21..1d7b2ad491b 100644 --- a/amplify/backend/function/fetchExpenditureBalances/function-parameters.json +++ b/amplify/backend/function/fetchExpenditureBalances/function-parameters.json @@ -1,3 +1,15 @@ { - "lambdaLayers": [] + "lambdaLayers": [ + { + "type": "ProjectLayer", + "resourceName": "colonycdappSSMAccess", + "env": "qa", + "version": "Always choose latest version", + "isLatestVersionSelected": true + }, + { + "type": "ExternalLayer", + "arn": "arn:aws:lambda:eu-west-2:133256977650:layer:AWS-Parameters-and-Secrets-Lambda-Extension:4" + } + ] } \ No newline at end of file From 5a8cbde87bb85cc2cbb55f273d7f32995c84c6dd Mon Sep 17 00:00:00 2001 From: Jakub Zajac Date: Sun, 20 Aug 2023 11:14:12 +0100 Subject: [PATCH 07/18] Remove redirect to /404 from expenditure details page --- .../ExpenditureDetailsPage/ExpenditureDetailsPage.tsx | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/src/components/common/Expenditures/ExpenditureDetailsPage/ExpenditureDetailsPage.tsx b/src/components/common/Expenditures/ExpenditureDetailsPage/ExpenditureDetailsPage.tsx index 8974286fea0..c7ca3e91581 100644 --- a/src/components/common/Expenditures/ExpenditureDetailsPage/ExpenditureDetailsPage.tsx +++ b/src/components/common/Expenditures/ExpenditureDetailsPage/ExpenditureDetailsPage.tsx @@ -4,7 +4,6 @@ import { Id } from '@colony/colony-js'; import { ExpenditureStatus, useGetExpenditureQuery } from '~gql'; import { useColonyContext } from '~hooks'; -import NotFoundRoute from '~routes/NotFoundRoute'; import { Heading3 } from '~shared/Heading'; import { getExpenditureDatabaseId } from '~utils/databaseId'; import { findDomainByNativeId } from '~utils/domains'; @@ -46,7 +45,12 @@ const ExpenditureDetailsPage = () => { const expenditure = data.getExpenditure; if (!expenditure) { - return ; + return ( +
+ This expenditure does not exist in the database but a page refresh might + help. +
+ ); } const expenditureDomain = findDomainByNativeId( From 81e0e4b68ef9e08c3fa41c6e8ed91d85b9007c2c Mon Sep 17 00:00:00 2001 From: Jakub Zajac Date: Sun, 20 Aug 2023 11:20:32 +0100 Subject: [PATCH 08/18] Feat: ExpenditureClaimButton component --- .../ExpenditureAdvanceButton.tsx | 14 +--- .../ExpenditureClaimButton.tsx | 67 +++++++++++++++++++ .../ExpenditureClaimButton/index.ts | 1 + src/graphql/fragments/expenditures.graphql | 1 + src/graphql/generated.ts | 31 ++++----- 5 files changed, 88 insertions(+), 26 deletions(-) create mode 100644 src/components/common/Expenditures/ExpenditureDetailsPage/ExpenditureClaimButton/ExpenditureClaimButton.tsx create mode 100644 src/components/common/Expenditures/ExpenditureDetailsPage/ExpenditureClaimButton/index.ts diff --git a/src/components/common/Expenditures/ExpenditureDetailsPage/ExpenditureAdvanceButton/ExpenditureAdvanceButton.tsx b/src/components/common/Expenditures/ExpenditureDetailsPage/ExpenditureAdvanceButton/ExpenditureAdvanceButton.tsx index 5a32e381d1c..5ff32b28e9d 100644 --- a/src/components/common/Expenditures/ExpenditureDetailsPage/ExpenditureAdvanceButton/ExpenditureAdvanceButton.tsx +++ b/src/components/common/Expenditures/ExpenditureDetailsPage/ExpenditureAdvanceButton/ExpenditureAdvanceButton.tsx @@ -8,6 +8,8 @@ import { Colony, Expenditure } from '~types'; import { isExpenditureFunded } from '~utils/expenditures'; import { findDomainByNativeId } from '~utils/domains'; +import ExpenditureClaimButton from '../ExpenditureClaimButton/ExpenditureClaimButton'; + interface ExpenditureAdvanceButtonProps { expenditure: Expenditure; colony: Colony; @@ -71,17 +73,7 @@ const ExpenditureAdvanceButton = ({ } if (expenditure.status === ExpenditureStatus.Finalized) { - return ( - - Claim funds - - ); + return ; } return null; diff --git a/src/components/common/Expenditures/ExpenditureDetailsPage/ExpenditureClaimButton/ExpenditureClaimButton.tsx b/src/components/common/Expenditures/ExpenditureDetailsPage/ExpenditureClaimButton/ExpenditureClaimButton.tsx new file mode 100644 index 00000000000..dabfdcf3a8d --- /dev/null +++ b/src/components/common/Expenditures/ExpenditureDetailsPage/ExpenditureClaimButton/ExpenditureClaimButton.tsx @@ -0,0 +1,67 @@ +import React from 'react'; +import { ExpenditureStatus } from '~gql'; +import { ActionTypes } from '~redux'; +import { ActionButton } from '~shared/Button'; +import { Colony, Expenditure } from '~types'; + +interface ExpenditureClaimButtonProps { + colony: Colony; + expenditure: Expenditure; +} + +const ExpenditureClaimButton = ({ + colony, + expenditure, +}: ExpenditureClaimButtonProps) => { + if (expenditure.status !== ExpenditureStatus.Finalized) { + return null; + } + + const isFullyClaimed = !!expenditure.balances?.every( + (balance) => balance.amount === '0', + ); + + if (isFullyClaimed) { + return
There are no more payouts to claim
; + } + + let nextClaimableAt: number | null = null; + const claimableSlots = expenditure.slots.filter((slot) => { + const claimableFrom = new Date( + ((expenditure.finalizedAt ?? 0) + (slot.claimDelay ?? 0)) * 1000, + ).getTime(); + + if (Date.now() >= claimableFrom) { + return true; + } + + if (!nextClaimableAt || claimableFrom < nextClaimableAt) { + nextClaimableAt = claimableFrom; + } + + return false; + }); + + return ( +
+
You can now claim {claimableSlots.length} slots
+ {nextClaimableAt && ( +
Next claim at {new Date(nextClaimableAt).toString()}
+ )} + + {claimableSlots.length && ( + + Claim funds + + )} +
+ ); +}; + +export default ExpenditureClaimButton; diff --git a/src/components/common/Expenditures/ExpenditureDetailsPage/ExpenditureClaimButton/index.ts b/src/components/common/Expenditures/ExpenditureDetailsPage/ExpenditureClaimButton/index.ts new file mode 100644 index 00000000000..fe6b0e4a974 --- /dev/null +++ b/src/components/common/Expenditures/ExpenditureDetailsPage/ExpenditureClaimButton/index.ts @@ -0,0 +1 @@ +export { default } from './ExpenditureClaimButton'; diff --git a/src/graphql/fragments/expenditures.graphql b/src/graphql/fragments/expenditures.graphql index 686891207c0..56c7a28a6e4 100644 --- a/src/graphql/fragments/expenditures.graphql +++ b/src/graphql/fragments/expenditures.graphql @@ -16,6 +16,7 @@ fragment Expenditure on Expenditure { amount requiredAmount } + finalizedAt } fragment ExpenditureSlot on ExpenditureSlot { diff --git a/src/graphql/generated.ts b/src/graphql/generated.ts index a09ede79eab..5862d38afb4 100644 --- a/src/graphql/generated.ts +++ b/src/graphql/generated.ts @@ -28,7 +28,7 @@ export type Scalars = { /** A time string at UTC, such as 10:15:30Z, compliant with the `full-time` format outlined in section 5.6 of the RFC 3339profile of the ISO 8601 standard for representation of dates and times using the Gregorian calendar. */ AWSTime: any; /** The AWSTimestamp scalar type represents the number of seconds that have elapsed since 1970-01-01T00:00Z. Timestamps are serialized and deserialized as numbers. Negative values are also accepted and these represent the number of seconds till 1970-01-01T00:00Z. */ - AWSTimestamp: any; + AWSTimestamp: number; /** A field whose value conforms to the standard URL format as specified in RFC3986: https://www.ietf.org/rfc/rfc3986.txt. */ AWSURL: string; }; @@ -985,7 +985,7 @@ export type CreateExpenditureInput = { balances?: InputMaybe>; colonyId: Scalars['ID']; createdAt?: InputMaybe; - finalizedAt?: InputMaybe; + finalizedAt?: InputMaybe; id?: InputMaybe; nativeDomainId: Scalars['Int']; nativeFundingPotId: Scalars['Int']; @@ -1350,7 +1350,7 @@ export type Expenditure = { colony: Colony; colonyId: Scalars['ID']; createdAt: Scalars['AWSDateTime']; - finalizedAt?: Maybe; + finalizedAt?: Maybe; id: Scalars['ID']; metadata?: Maybe; nativeDomainId: Scalars['Int']; @@ -2113,7 +2113,7 @@ export type ModelExpenditureConditionInput = { and?: InputMaybe>>; colonyId?: InputMaybe; createdAt?: InputMaybe; - finalizedAt?: InputMaybe; + finalizedAt?: InputMaybe; nativeDomainId?: InputMaybe; nativeFundingPotId?: InputMaybe; nativeId?: InputMaybe; @@ -2133,7 +2133,7 @@ export type ModelExpenditureFilterInput = { and?: InputMaybe>>; colonyId?: InputMaybe; createdAt?: InputMaybe; - finalizedAt?: InputMaybe; + finalizedAt?: InputMaybe; id?: InputMaybe; nativeDomainId?: InputMaybe; nativeFundingPotId?: InputMaybe; @@ -2540,7 +2540,7 @@ export type ModelSubscriptionExpenditureFilterInput = { and?: InputMaybe>>; colonyId?: InputMaybe; createdAt?: InputMaybe; - finalizedAt?: InputMaybe; + finalizedAt?: InputMaybe; id?: InputMaybe; nativeDomainId?: InputMaybe; nativeFundingPotId?: InputMaybe; @@ -5033,7 +5033,7 @@ export type UpdateExpenditureInput = { balances?: InputMaybe>; colonyId?: InputMaybe; createdAt?: InputMaybe; - finalizedAt?: InputMaybe; + finalizedAt?: InputMaybe; id: Scalars['ID']; nativeDomainId?: InputMaybe; nativeFundingPotId?: InputMaybe; @@ -5328,7 +5328,7 @@ export type Watcher = { user?: Maybe; }; -export type ColonyActionFragment = { __typename?: 'ColonyAction', type: ColonyActionType, blockNumber: number, initiatorAddress: string, recipientAddress?: string | null, amount?: string | null, tokenAddress?: string | null, createdAt: string, newColonyVersion?: number | null, individualEvents?: string | null, isMotion?: boolean | null, showInActionsList: boolean, transactionHash: string, colonyAddress: string, initiatorUser?: { __typename?: 'User', name: string, walletAddress: string, profile?: { __typename?: 'Profile', displayName?: string | null, avatar?: string | null, thumbnail?: string | null } | null } | null, initiatorColony?: { __typename?: 'Colony', name: string, version: number, colonyAddress: string, metadata?: { __typename?: 'ColonyMetadata', displayName: string, avatar?: string | null, thumbnail?: string | null, isWhitelistActivated?: boolean | null, whitelistedAddresses?: Array | null, changelog?: Array<{ __typename?: 'ColonyMetadataChangelog', transactionHash: string, newDisplayName: string, oldDisplayName: string, hasAvatarChanged: boolean, hasWhitelistChanged: boolean, haveTokensChanged: boolean }> | null } | null, nativeToken: { __typename?: 'Token', decimals: number, name: string, symbol: string, type?: TokenType | null, avatar?: string | null, thumbnail?: string | null, tokenAddress: string }, status?: { __typename?: 'ColonyStatus', recovery?: boolean | null, nativeToken?: { __typename?: 'NativeTokenStatus', mintable?: boolean | null, unlockable?: boolean | null, unlocked?: boolean | null } | null } | null, chainMetadata: { __typename?: 'ChainMetadata', chainId: number }, tokens?: { __typename?: 'ModelColonyTokensConnection', items: Array<{ __typename?: 'ColonyTokens', colonyTokensId: string, token: { __typename?: 'Token', decimals: number, name: string, symbol: string, type?: TokenType | null, avatar?: string | null, thumbnail?: string | null, tokenAddress: string } } | null> } | null, motionsWithUnclaimedStakes?: Array<{ __typename?: 'ColonyUnclaimedStake', motionId: string, unclaimedRewards: Array<{ __typename?: 'StakerRewards', address: string, rewards: { __typename?: 'MotionStakeValues', nay: string, yay: string } }> }> | null, domains?: { __typename?: 'ModelDomainConnection', items: Array<{ __typename?: 'Domain', id: string, nativeId: number, isRoot: boolean, nativeFundingPotId: number, metadata?: { __typename?: 'DomainMetadata', name: string, color: DomainColor, description: string, changelog?: Array<{ __typename?: 'DomainMetadataChangelog', transactionHash: string, oldName: string, newName: string, oldColor: DomainColor, newColor: DomainColor, oldDescription: string, newDescription: string }> | null } | null } | null> } | null, balances?: { __typename?: 'ColonyBalances', items?: Array<{ __typename?: 'ColonyBalance', id: string, balance: string, domain?: { __typename?: 'Domain', id: string, nativeId: number, isRoot: boolean, nativeFundingPotId: number, metadata?: { __typename?: 'DomainMetadata', name: string, color: DomainColor, description: string, changelog?: Array<{ __typename?: 'DomainMetadataChangelog', transactionHash: string, oldName: string, newName: string, oldColor: DomainColor, newColor: DomainColor, oldDescription: string, newDescription: string }> | null } | null } | null, token: { __typename?: 'Token', decimals: number, name: string, symbol: string, type?: TokenType | null, avatar?: string | null, thumbnail?: string | null, tokenAddress: string } } | null> | null } | null, fundsClaims?: { __typename?: 'ModelColonyFundsClaimConnection', items: Array<{ __typename?: 'ColonyFundsClaim', id: string, createdAtBlock: number, createdAt: string, amount: string, token: { __typename?: 'Token', decimals: number, name: string, symbol: string, type?: TokenType | null, avatar?: string | null, thumbnail?: string | null, tokenAddress: string } } | null> } | null, chainFundsClaim?: { __typename?: 'ColonyChainFundsClaim', id: string, createdAtBlock: number, createdAt: string, amount: string } | null, roles?: { __typename?: 'ModelColonyRoleConnection', items: Array<{ __typename?: 'ColonyRole', id: string, targetAddress?: string | null, role_0?: boolean | null, role_1?: boolean | null, role_2?: boolean | null, role_3?: boolean | null, role_5?: boolean | null, role_6?: boolean | null, domain: { __typename?: 'Domain', nativeId: number } } | null> } | null } | null, initiatorExtension?: { __typename?: 'ColonyExtension', hash: string, installedBy: string, installedAt: any, isDeprecated: boolean, isDeleted: boolean, isInitialized: boolean, address: string, colonyAddress: string, currentVersion: number, params?: { __typename?: 'ExtensionParams', votingReputation?: { __typename?: 'VotingReputationParams', maxVoteFraction: string } | null } | null } | null, initiatorToken?: { __typename?: 'Token', decimals: number, name: string, symbol: string, type?: TokenType | null, avatar?: string | null, thumbnail?: string | null, tokenAddress: string } | null, recipientUser?: { __typename?: 'User', name: string, walletAddress: string, profile?: { __typename?: 'Profile', displayName?: string | null, avatar?: string | null, thumbnail?: string | null } | null } | null, recipientColony?: { __typename?: 'Colony', name: string, version: number, colonyAddress: string, metadata?: { __typename?: 'ColonyMetadata', displayName: string, avatar?: string | null, thumbnail?: string | null, isWhitelistActivated?: boolean | null, whitelistedAddresses?: Array | null, changelog?: Array<{ __typename?: 'ColonyMetadataChangelog', transactionHash: string, newDisplayName: string, oldDisplayName: string, hasAvatarChanged: boolean, hasWhitelistChanged: boolean, haveTokensChanged: boolean }> | null } | null, nativeToken: { __typename?: 'Token', decimals: number, name: string, symbol: string, type?: TokenType | null, avatar?: string | null, thumbnail?: string | null, tokenAddress: string }, status?: { __typename?: 'ColonyStatus', recovery?: boolean | null, nativeToken?: { __typename?: 'NativeTokenStatus', mintable?: boolean | null, unlockable?: boolean | null, unlocked?: boolean | null } | null } | null, chainMetadata: { __typename?: 'ChainMetadata', chainId: number }, tokens?: { __typename?: 'ModelColonyTokensConnection', items: Array<{ __typename?: 'ColonyTokens', colonyTokensId: string, token: { __typename?: 'Token', decimals: number, name: string, symbol: string, type?: TokenType | null, avatar?: string | null, thumbnail?: string | null, tokenAddress: string } } | null> } | null, motionsWithUnclaimedStakes?: Array<{ __typename?: 'ColonyUnclaimedStake', motionId: string, unclaimedRewards: Array<{ __typename?: 'StakerRewards', address: string, rewards: { __typename?: 'MotionStakeValues', nay: string, yay: string } }> }> | null, domains?: { __typename?: 'ModelDomainConnection', items: Array<{ __typename?: 'Domain', id: string, nativeId: number, isRoot: boolean, nativeFundingPotId: number, metadata?: { __typename?: 'DomainMetadata', name: string, color: DomainColor, description: string, changelog?: Array<{ __typename?: 'DomainMetadataChangelog', transactionHash: string, oldName: string, newName: string, oldColor: DomainColor, newColor: DomainColor, oldDescription: string, newDescription: string }> | null } | null } | null> } | null, balances?: { __typename?: 'ColonyBalances', items?: Array<{ __typename?: 'ColonyBalance', id: string, balance: string, domain?: { __typename?: 'Domain', id: string, nativeId: number, isRoot: boolean, nativeFundingPotId: number, metadata?: { __typename?: 'DomainMetadata', name: string, color: DomainColor, description: string, changelog?: Array<{ __typename?: 'DomainMetadataChangelog', transactionHash: string, oldName: string, newName: string, oldColor: DomainColor, newColor: DomainColor, oldDescription: string, newDescription: string }> | null } | null } | null, token: { __typename?: 'Token', decimals: number, name: string, symbol: string, type?: TokenType | null, avatar?: string | null, thumbnail?: string | null, tokenAddress: string } } | null> | null } | null, fundsClaims?: { __typename?: 'ModelColonyFundsClaimConnection', items: Array<{ __typename?: 'ColonyFundsClaim', id: string, createdAtBlock: number, createdAt: string, amount: string, token: { __typename?: 'Token', decimals: number, name: string, symbol: string, type?: TokenType | null, avatar?: string | null, thumbnail?: string | null, tokenAddress: string } } | null> } | null, chainFundsClaim?: { __typename?: 'ColonyChainFundsClaim', id: string, createdAtBlock: number, createdAt: string, amount: string } | null, roles?: { __typename?: 'ModelColonyRoleConnection', items: Array<{ __typename?: 'ColonyRole', id: string, targetAddress?: string | null, role_0?: boolean | null, role_1?: boolean | null, role_2?: boolean | null, role_3?: boolean | null, role_5?: boolean | null, role_6?: boolean | null, domain: { __typename?: 'Domain', nativeId: number } } | null> } | null } | null, recipientExtension?: { __typename?: 'ColonyExtension', hash: string, installedBy: string, installedAt: any, isDeprecated: boolean, isDeleted: boolean, isInitialized: boolean, address: string, colonyAddress: string, currentVersion: number, params?: { __typename?: 'ExtensionParams', votingReputation?: { __typename?: 'VotingReputationParams', maxVoteFraction: string } | null } | null } | null, recipientToken?: { __typename?: 'Token', decimals: number, name: string, symbol: string, type?: TokenType | null, avatar?: string | null, thumbnail?: string | null, tokenAddress: string } | null, token?: { __typename?: 'Token', decimals: number, name: string, symbol: string, type?: TokenType | null, avatar?: string | null, thumbnail?: string | null, tokenAddress: string } | null, fromDomain?: { __typename?: 'Domain', id: string, nativeId: number, isRoot: boolean, nativeFundingPotId: number, metadata?: { __typename?: 'DomainMetadata', name: string, color: DomainColor, description: string, changelog?: Array<{ __typename?: 'DomainMetadataChangelog', transactionHash: string, oldName: string, newName: string, oldColor: DomainColor, newColor: DomainColor, oldDescription: string, newDescription: string }> | null } | null } | null, toDomain?: { __typename?: 'Domain', id: string, nativeId: number, isRoot: boolean, nativeFundingPotId: number, metadata?: { __typename?: 'DomainMetadata', name: string, color: DomainColor, description: string, changelog?: Array<{ __typename?: 'DomainMetadataChangelog', transactionHash: string, oldName: string, newName: string, oldColor: DomainColor, newColor: DomainColor, oldDescription: string, newDescription: string }> | null } | null } | null, roles?: { __typename?: 'ColonyActionRoles', role_0?: boolean | null, role_1?: boolean | null, role_2?: boolean | null, role_3?: boolean | null, role_5?: boolean | null, role_6?: boolean | null } | null, motionData?: { __typename?: 'ColonyMotion', remainingStakes: Array, userMinStake: string, requiredStake: string, rootHash: string, nativeMotionDomainId: string, isFinalized: boolean, skillRep: string, repSubmitted: string, hasObjection: boolean, databaseMotionId: string, motionId: string, motionStakes: { __typename?: 'MotionStakes', raw: { __typename?: 'MotionStakeValues', yay: string, nay: string }, percentage: { __typename?: 'MotionStakeValues', yay: string, nay: string } }, usersStakes: Array<{ __typename?: 'UserStakes', address: string, stakes: { __typename?: 'MotionStakes', raw: { __typename?: 'MotionStakeValues', yay: string, nay: string }, percentage: { __typename?: 'MotionStakeValues', yay: string, nay: string } } }>, motionDomain: { __typename?: 'Domain', id: string, nativeId: number, isRoot: boolean, nativeFundingPotId: number, metadata?: { __typename?: 'DomainMetadata', name: string, color: DomainColor, description: string, changelog?: Array<{ __typename?: 'DomainMetadataChangelog', transactionHash: string, oldName: string, newName: string, oldColor: DomainColor, newColor: DomainColor, oldDescription: string, newDescription: string }> | null } | null }, stakerRewards: Array<{ __typename?: 'StakerRewards', address: string, isClaimed: boolean, rewards: { __typename?: 'MotionStakeValues', yay: string, nay: string } }>, voterRecord: Array<{ __typename?: 'VoterRecord', address: string, voteCount: string, vote?: number | null }>, revealedVotes: { __typename?: 'MotionStakes', raw: { __typename?: 'MotionStakeValues', yay: string, nay: string }, percentage: { __typename?: 'MotionStakeValues', yay: string, nay: string } }, motionStateHistory: { __typename?: 'MotionStateHistory', hasVoted: boolean, hasPassed: boolean, hasFailed: boolean, hasFailedNotFinalizable: boolean, inRevealPhase: boolean }, messages?: { __typename?: 'ModelMotionMessageConnection', items: Array<{ __typename?: 'MotionMessage', initiatorAddress: string, name: string, messageKey: string, vote?: string | null, amount?: string | null, initiatorUser?: { __typename?: 'User', name: string, walletAddress: string, profile?: { __typename?: 'Profile', avatar?: string | null, bio?: string | null, displayName?: string | null, email?: string | null, location?: string | null, thumbnail?: string | null, website?: string | null } | null, watchlist?: { __typename?: 'ModelWatchedColoniesConnection', items: Array<{ __typename?: 'WatchedColonies', id: string, createdAt: string, colony: { __typename?: 'Colony', name: string, colonyAddress: string, chainMetadata: { __typename?: 'ChainMetadata', chainId: number }, metadata?: { __typename?: 'ColonyMetadata', displayName: string, avatar?: string | null, thumbnail?: string | null, isWhitelistActivated?: boolean | null, whitelistedAddresses?: Array | null, changelog?: Array<{ __typename?: 'ColonyMetadataChangelog', transactionHash: string, newDisplayName: string, oldDisplayName: string, hasAvatarChanged: boolean, hasWhitelistChanged: boolean, haveTokensChanged: boolean }> | null } | null } } | null> } | null } | null } | null> } | null } | null, colony: { __typename?: 'Colony', colonyAddress: string, nativeToken: { __typename?: 'Token', nativeTokenDecimals: number, nativeTokenSymbol: string, tokenAddress: string } }, pendingDomainMetadata?: { __typename?: 'DomainMetadata', name: string, color: DomainColor, description: string, changelog?: Array<{ __typename?: 'DomainMetadataChangelog', transactionHash: string, oldName: string, newName: string, oldColor: DomainColor, newColor: DomainColor, oldDescription: string, newDescription: string }> | null } | null, pendingColonyMetadata?: { __typename?: 'ColonyMetadata', displayName: string, avatar?: string | null, thumbnail?: string | null, isWhitelistActivated?: boolean | null, whitelistedAddresses?: Array | null, changelog?: Array<{ __typename?: 'ColonyMetadataChangelog', transactionHash: string, newDisplayName: string, oldDisplayName: string, hasAvatarChanged: boolean, hasWhitelistChanged: boolean, haveTokensChanged: boolean }> | null } | null }; +export type ColonyActionFragment = { __typename?: 'ColonyAction', type: ColonyActionType, blockNumber: number, initiatorAddress: string, recipientAddress?: string | null, amount?: string | null, tokenAddress?: string | null, createdAt: string, newColonyVersion?: number | null, individualEvents?: string | null, isMotion?: boolean | null, showInActionsList: boolean, transactionHash: string, colonyAddress: string, initiatorUser?: { __typename?: 'User', name: string, walletAddress: string, profile?: { __typename?: 'Profile', displayName?: string | null, avatar?: string | null, thumbnail?: string | null } | null } | null, initiatorColony?: { __typename?: 'Colony', name: string, version: number, colonyAddress: string, metadata?: { __typename?: 'ColonyMetadata', displayName: string, avatar?: string | null, thumbnail?: string | null, isWhitelistActivated?: boolean | null, whitelistedAddresses?: Array | null, changelog?: Array<{ __typename?: 'ColonyMetadataChangelog', transactionHash: string, newDisplayName: string, oldDisplayName: string, hasAvatarChanged: boolean, hasWhitelistChanged: boolean, haveTokensChanged: boolean }> | null } | null, nativeToken: { __typename?: 'Token', decimals: number, name: string, symbol: string, type?: TokenType | null, avatar?: string | null, thumbnail?: string | null, tokenAddress: string }, status?: { __typename?: 'ColonyStatus', recovery?: boolean | null, nativeToken?: { __typename?: 'NativeTokenStatus', mintable?: boolean | null, unlockable?: boolean | null, unlocked?: boolean | null } | null } | null, chainMetadata: { __typename?: 'ChainMetadata', chainId: number }, tokens?: { __typename?: 'ModelColonyTokensConnection', items: Array<{ __typename?: 'ColonyTokens', colonyTokensId: string, token: { __typename?: 'Token', decimals: number, name: string, symbol: string, type?: TokenType | null, avatar?: string | null, thumbnail?: string | null, tokenAddress: string } } | null> } | null, motionsWithUnclaimedStakes?: Array<{ __typename?: 'ColonyUnclaimedStake', motionId: string, unclaimedRewards: Array<{ __typename?: 'StakerRewards', address: string, rewards: { __typename?: 'MotionStakeValues', nay: string, yay: string } }> }> | null, domains?: { __typename?: 'ModelDomainConnection', items: Array<{ __typename?: 'Domain', id: string, nativeId: number, isRoot: boolean, nativeFundingPotId: number, metadata?: { __typename?: 'DomainMetadata', name: string, color: DomainColor, description: string, changelog?: Array<{ __typename?: 'DomainMetadataChangelog', transactionHash: string, oldName: string, newName: string, oldColor: DomainColor, newColor: DomainColor, oldDescription: string, newDescription: string }> | null } | null } | null> } | null, balances?: { __typename?: 'ColonyBalances', items?: Array<{ __typename?: 'ColonyBalance', id: string, balance: string, domain?: { __typename?: 'Domain', id: string, nativeId: number, isRoot: boolean, nativeFundingPotId: number, metadata?: { __typename?: 'DomainMetadata', name: string, color: DomainColor, description: string, changelog?: Array<{ __typename?: 'DomainMetadataChangelog', transactionHash: string, oldName: string, newName: string, oldColor: DomainColor, newColor: DomainColor, oldDescription: string, newDescription: string }> | null } | null } | null, token: { __typename?: 'Token', decimals: number, name: string, symbol: string, type?: TokenType | null, avatar?: string | null, thumbnail?: string | null, tokenAddress: string } } | null> | null } | null, fundsClaims?: { __typename?: 'ModelColonyFundsClaimConnection', items: Array<{ __typename?: 'ColonyFundsClaim', id: string, createdAtBlock: number, createdAt: string, amount: string, token: { __typename?: 'Token', decimals: number, name: string, symbol: string, type?: TokenType | null, avatar?: string | null, thumbnail?: string | null, tokenAddress: string } } | null> } | null, chainFundsClaim?: { __typename?: 'ColonyChainFundsClaim', id: string, createdAtBlock: number, createdAt: string, amount: string } | null, roles?: { __typename?: 'ModelColonyRoleConnection', items: Array<{ __typename?: 'ColonyRole', id: string, targetAddress?: string | null, role_0?: boolean | null, role_1?: boolean | null, role_2?: boolean | null, role_3?: boolean | null, role_5?: boolean | null, role_6?: boolean | null, domain: { __typename?: 'Domain', nativeId: number } } | null> } | null } | null, initiatorExtension?: { __typename?: 'ColonyExtension', hash: string, installedBy: string, installedAt: number, isDeprecated: boolean, isDeleted: boolean, isInitialized: boolean, address: string, colonyAddress: string, currentVersion: number, params?: { __typename?: 'ExtensionParams', votingReputation?: { __typename?: 'VotingReputationParams', maxVoteFraction: string } | null } | null } | null, initiatorToken?: { __typename?: 'Token', decimals: number, name: string, symbol: string, type?: TokenType | null, avatar?: string | null, thumbnail?: string | null, tokenAddress: string } | null, recipientUser?: { __typename?: 'User', name: string, walletAddress: string, profile?: { __typename?: 'Profile', displayName?: string | null, avatar?: string | null, thumbnail?: string | null } | null } | null, recipientColony?: { __typename?: 'Colony', name: string, version: number, colonyAddress: string, metadata?: { __typename?: 'ColonyMetadata', displayName: string, avatar?: string | null, thumbnail?: string | null, isWhitelistActivated?: boolean | null, whitelistedAddresses?: Array | null, changelog?: Array<{ __typename?: 'ColonyMetadataChangelog', transactionHash: string, newDisplayName: string, oldDisplayName: string, hasAvatarChanged: boolean, hasWhitelistChanged: boolean, haveTokensChanged: boolean }> | null } | null, nativeToken: { __typename?: 'Token', decimals: number, name: string, symbol: string, type?: TokenType | null, avatar?: string | null, thumbnail?: string | null, tokenAddress: string }, status?: { __typename?: 'ColonyStatus', recovery?: boolean | null, nativeToken?: { __typename?: 'NativeTokenStatus', mintable?: boolean | null, unlockable?: boolean | null, unlocked?: boolean | null } | null } | null, chainMetadata: { __typename?: 'ChainMetadata', chainId: number }, tokens?: { __typename?: 'ModelColonyTokensConnection', items: Array<{ __typename?: 'ColonyTokens', colonyTokensId: string, token: { __typename?: 'Token', decimals: number, name: string, symbol: string, type?: TokenType | null, avatar?: string | null, thumbnail?: string | null, tokenAddress: string } } | null> } | null, motionsWithUnclaimedStakes?: Array<{ __typename?: 'ColonyUnclaimedStake', motionId: string, unclaimedRewards: Array<{ __typename?: 'StakerRewards', address: string, rewards: { __typename?: 'MotionStakeValues', nay: string, yay: string } }> }> | null, domains?: { __typename?: 'ModelDomainConnection', items: Array<{ __typename?: 'Domain', id: string, nativeId: number, isRoot: boolean, nativeFundingPotId: number, metadata?: { __typename?: 'DomainMetadata', name: string, color: DomainColor, description: string, changelog?: Array<{ __typename?: 'DomainMetadataChangelog', transactionHash: string, oldName: string, newName: string, oldColor: DomainColor, newColor: DomainColor, oldDescription: string, newDescription: string }> | null } | null } | null> } | null, balances?: { __typename?: 'ColonyBalances', items?: Array<{ __typename?: 'ColonyBalance', id: string, balance: string, domain?: { __typename?: 'Domain', id: string, nativeId: number, isRoot: boolean, nativeFundingPotId: number, metadata?: { __typename?: 'DomainMetadata', name: string, color: DomainColor, description: string, changelog?: Array<{ __typename?: 'DomainMetadataChangelog', transactionHash: string, oldName: string, newName: string, oldColor: DomainColor, newColor: DomainColor, oldDescription: string, newDescription: string }> | null } | null } | null, token: { __typename?: 'Token', decimals: number, name: string, symbol: string, type?: TokenType | null, avatar?: string | null, thumbnail?: string | null, tokenAddress: string } } | null> | null } | null, fundsClaims?: { __typename?: 'ModelColonyFundsClaimConnection', items: Array<{ __typename?: 'ColonyFundsClaim', id: string, createdAtBlock: number, createdAt: string, amount: string, token: { __typename?: 'Token', decimals: number, name: string, symbol: string, type?: TokenType | null, avatar?: string | null, thumbnail?: string | null, tokenAddress: string } } | null> } | null, chainFundsClaim?: { __typename?: 'ColonyChainFundsClaim', id: string, createdAtBlock: number, createdAt: string, amount: string } | null, roles?: { __typename?: 'ModelColonyRoleConnection', items: Array<{ __typename?: 'ColonyRole', id: string, targetAddress?: string | null, role_0?: boolean | null, role_1?: boolean | null, role_2?: boolean | null, role_3?: boolean | null, role_5?: boolean | null, role_6?: boolean | null, domain: { __typename?: 'Domain', nativeId: number } } | null> } | null } | null, recipientExtension?: { __typename?: 'ColonyExtension', hash: string, installedBy: string, installedAt: number, isDeprecated: boolean, isDeleted: boolean, isInitialized: boolean, address: string, colonyAddress: string, currentVersion: number, params?: { __typename?: 'ExtensionParams', votingReputation?: { __typename?: 'VotingReputationParams', maxVoteFraction: string } | null } | null } | null, recipientToken?: { __typename?: 'Token', decimals: number, name: string, symbol: string, type?: TokenType | null, avatar?: string | null, thumbnail?: string | null, tokenAddress: string } | null, token?: { __typename?: 'Token', decimals: number, name: string, symbol: string, type?: TokenType | null, avatar?: string | null, thumbnail?: string | null, tokenAddress: string } | null, fromDomain?: { __typename?: 'Domain', id: string, nativeId: number, isRoot: boolean, nativeFundingPotId: number, metadata?: { __typename?: 'DomainMetadata', name: string, color: DomainColor, description: string, changelog?: Array<{ __typename?: 'DomainMetadataChangelog', transactionHash: string, oldName: string, newName: string, oldColor: DomainColor, newColor: DomainColor, oldDescription: string, newDescription: string }> | null } | null } | null, toDomain?: { __typename?: 'Domain', id: string, nativeId: number, isRoot: boolean, nativeFundingPotId: number, metadata?: { __typename?: 'DomainMetadata', name: string, color: DomainColor, description: string, changelog?: Array<{ __typename?: 'DomainMetadataChangelog', transactionHash: string, oldName: string, newName: string, oldColor: DomainColor, newColor: DomainColor, oldDescription: string, newDescription: string }> | null } | null } | null, roles?: { __typename?: 'ColonyActionRoles', role_0?: boolean | null, role_1?: boolean | null, role_2?: boolean | null, role_3?: boolean | null, role_5?: boolean | null, role_6?: boolean | null } | null, motionData?: { __typename?: 'ColonyMotion', remainingStakes: Array, userMinStake: string, requiredStake: string, rootHash: string, nativeMotionDomainId: string, isFinalized: boolean, skillRep: string, repSubmitted: string, hasObjection: boolean, databaseMotionId: string, motionId: string, motionStakes: { __typename?: 'MotionStakes', raw: { __typename?: 'MotionStakeValues', yay: string, nay: string }, percentage: { __typename?: 'MotionStakeValues', yay: string, nay: string } }, usersStakes: Array<{ __typename?: 'UserStakes', address: string, stakes: { __typename?: 'MotionStakes', raw: { __typename?: 'MotionStakeValues', yay: string, nay: string }, percentage: { __typename?: 'MotionStakeValues', yay: string, nay: string } } }>, motionDomain: { __typename?: 'Domain', id: string, nativeId: number, isRoot: boolean, nativeFundingPotId: number, metadata?: { __typename?: 'DomainMetadata', name: string, color: DomainColor, description: string, changelog?: Array<{ __typename?: 'DomainMetadataChangelog', transactionHash: string, oldName: string, newName: string, oldColor: DomainColor, newColor: DomainColor, oldDescription: string, newDescription: string }> | null } | null }, stakerRewards: Array<{ __typename?: 'StakerRewards', address: string, isClaimed: boolean, rewards: { __typename?: 'MotionStakeValues', yay: string, nay: string } }>, voterRecord: Array<{ __typename?: 'VoterRecord', address: string, voteCount: string, vote?: number | null }>, revealedVotes: { __typename?: 'MotionStakes', raw: { __typename?: 'MotionStakeValues', yay: string, nay: string }, percentage: { __typename?: 'MotionStakeValues', yay: string, nay: string } }, motionStateHistory: { __typename?: 'MotionStateHistory', hasVoted: boolean, hasPassed: boolean, hasFailed: boolean, hasFailedNotFinalizable: boolean, inRevealPhase: boolean }, messages?: { __typename?: 'ModelMotionMessageConnection', items: Array<{ __typename?: 'MotionMessage', initiatorAddress: string, name: string, messageKey: string, vote?: string | null, amount?: string | null, initiatorUser?: { __typename?: 'User', name: string, walletAddress: string, profile?: { __typename?: 'Profile', avatar?: string | null, bio?: string | null, displayName?: string | null, email?: string | null, location?: string | null, thumbnail?: string | null, website?: string | null } | null, watchlist?: { __typename?: 'ModelWatchedColoniesConnection', items: Array<{ __typename?: 'WatchedColonies', id: string, createdAt: string, colony: { __typename?: 'Colony', name: string, colonyAddress: string, chainMetadata: { __typename?: 'ChainMetadata', chainId: number }, metadata?: { __typename?: 'ColonyMetadata', displayName: string, avatar?: string | null, thumbnail?: string | null, isWhitelistActivated?: boolean | null, whitelistedAddresses?: Array | null, changelog?: Array<{ __typename?: 'ColonyMetadataChangelog', transactionHash: string, newDisplayName: string, oldDisplayName: string, hasAvatarChanged: boolean, hasWhitelistChanged: boolean, haveTokensChanged: boolean }> | null } | null } } | null> } | null } | null } | null> } | null } | null, colony: { __typename?: 'Colony', colonyAddress: string, nativeToken: { __typename?: 'Token', nativeTokenDecimals: number, nativeTokenSymbol: string, tokenAddress: string } }, pendingDomainMetadata?: { __typename?: 'DomainMetadata', name: string, color: DomainColor, description: string, changelog?: Array<{ __typename?: 'DomainMetadataChangelog', transactionHash: string, oldName: string, newName: string, oldColor: DomainColor, newColor: DomainColor, oldDescription: string, newDescription: string }> | null } | null, pendingColonyMetadata?: { __typename?: 'ColonyMetadata', displayName: string, avatar?: string | null, thumbnail?: string | null, isWhitelistActivated?: boolean | null, whitelistedAddresses?: Array | null, changelog?: Array<{ __typename?: 'ColonyMetadataChangelog', transactionHash: string, newDisplayName: string, oldDisplayName: string, hasAvatarChanged: boolean, hasWhitelistChanged: boolean, haveTokensChanged: boolean }> | null } | null }; export type MotionStakeValuesFragment = { __typename?: 'MotionStakeValues', yay: string, nay: string }; @@ -5368,11 +5368,11 @@ export type DomainFragment = { __typename?: 'Domain', id: string, nativeId: numb export type DomainMetadataFragment = { __typename?: 'DomainMetadata', name: string, color: DomainColor, description: string, changelog?: Array<{ __typename?: 'DomainMetadataChangelog', transactionHash: string, oldName: string, newName: string, oldColor: DomainColor, newColor: DomainColor, oldDescription: string, newDescription: string }> | null }; -export type ExpenditureFragment = { __typename?: 'Expenditure', id: string, nativeId: number, ownerAddress: string, status: ExpenditureStatus, nativeFundingPotId: number, nativeDomainId: number, slots: Array<{ __typename?: 'ExpenditureSlot', id: number, recipientAddress?: string | null, claimDelay?: number | null, payoutModifier?: number | null, payouts?: Array<{ __typename?: 'ExpenditurePayout', tokenAddress: string, amount: string }> | null }>, metadata?: { __typename?: 'ExpenditureMetadata', fundFromDomainNativeId: number } | null, balances?: Array<{ __typename?: 'ExpenditureBalance', tokenAddress: string, amount: string, requiredAmount: string }> | null }; +export type ExpenditureFragment = { __typename?: 'Expenditure', id: string, nativeId: number, ownerAddress: string, status: ExpenditureStatus, nativeFundingPotId: number, nativeDomainId: number, finalizedAt?: number | null, slots: Array<{ __typename?: 'ExpenditureSlot', id: number, recipientAddress?: string | null, claimDelay?: number | null, payoutModifier?: number | null, payouts?: Array<{ __typename?: 'ExpenditurePayout', tokenAddress: string, amount: string }> | null }>, metadata?: { __typename?: 'ExpenditureMetadata', fundFromDomainNativeId: number } | null, balances?: Array<{ __typename?: 'ExpenditureBalance', tokenAddress: string, amount: string, requiredAmount: string }> | null }; export type ExpenditureSlotFragment = { __typename?: 'ExpenditureSlot', id: number, recipientAddress?: string | null, claimDelay?: number | null, payoutModifier?: number | null, payouts?: Array<{ __typename?: 'ExpenditurePayout', tokenAddress: string, amount: string }> | null }; -export type ExtensionFragment = { __typename?: 'ColonyExtension', hash: string, installedBy: string, installedAt: any, isDeprecated: boolean, isDeleted: boolean, isInitialized: boolean, address: string, colonyAddress: string, currentVersion: number, params?: { __typename?: 'ExtensionParams', votingReputation?: { __typename?: 'VotingReputationParams', maxVoteFraction: string } | null } | null }; +export type ExtensionFragment = { __typename?: 'ColonyExtension', hash: string, installedBy: string, installedAt: number, isDeprecated: boolean, isDeleted: boolean, isInitialized: boolean, address: string, colonyAddress: string, currentVersion: number, params?: { __typename?: 'ExtensionParams', votingReputation?: { __typename?: 'VotingReputationParams', maxVoteFraction: string } | null } | null }; export type ExtensionDisplayFragmentFragment = { __typename?: 'ColonyExtension', hash: string, address: string }; @@ -5499,14 +5499,14 @@ export type GetColonyActionsQueryVariables = Exact<{ }>; -export type GetColonyActionsQuery = { __typename?: 'Query', getActionsByColony?: { __typename?: 'ModelColonyActionConnection', nextToken?: string | null, items: Array<{ __typename?: 'ColonyAction', type: ColonyActionType, blockNumber: number, initiatorAddress: string, recipientAddress?: string | null, amount?: string | null, tokenAddress?: string | null, createdAt: string, newColonyVersion?: number | null, individualEvents?: string | null, isMotion?: boolean | null, showInActionsList: boolean, transactionHash: string, colonyAddress: string, initiatorUser?: { __typename?: 'User', name: string, walletAddress: string, profile?: { __typename?: 'Profile', displayName?: string | null, avatar?: string | null, thumbnail?: string | null } | null } | null, initiatorColony?: { __typename?: 'Colony', name: string, version: number, colonyAddress: string, metadata?: { __typename?: 'ColonyMetadata', displayName: string, avatar?: string | null, thumbnail?: string | null, isWhitelistActivated?: boolean | null, whitelistedAddresses?: Array | null, changelog?: Array<{ __typename?: 'ColonyMetadataChangelog', transactionHash: string, newDisplayName: string, oldDisplayName: string, hasAvatarChanged: boolean, hasWhitelistChanged: boolean, haveTokensChanged: boolean }> | null } | null, nativeToken: { __typename?: 'Token', decimals: number, name: string, symbol: string, type?: TokenType | null, avatar?: string | null, thumbnail?: string | null, tokenAddress: string }, status?: { __typename?: 'ColonyStatus', recovery?: boolean | null, nativeToken?: { __typename?: 'NativeTokenStatus', mintable?: boolean | null, unlockable?: boolean | null, unlocked?: boolean | null } | null } | null, chainMetadata: { __typename?: 'ChainMetadata', chainId: number }, tokens?: { __typename?: 'ModelColonyTokensConnection', items: Array<{ __typename?: 'ColonyTokens', colonyTokensId: string, token: { __typename?: 'Token', decimals: number, name: string, symbol: string, type?: TokenType | null, avatar?: string | null, thumbnail?: string | null, tokenAddress: string } } | null> } | null, motionsWithUnclaimedStakes?: Array<{ __typename?: 'ColonyUnclaimedStake', motionId: string, unclaimedRewards: Array<{ __typename?: 'StakerRewards', address: string, rewards: { __typename?: 'MotionStakeValues', nay: string, yay: string } }> }> | null, domains?: { __typename?: 'ModelDomainConnection', items: Array<{ __typename?: 'Domain', id: string, nativeId: number, isRoot: boolean, nativeFundingPotId: number, metadata?: { __typename?: 'DomainMetadata', name: string, color: DomainColor, description: string, changelog?: Array<{ __typename?: 'DomainMetadataChangelog', transactionHash: string, oldName: string, newName: string, oldColor: DomainColor, newColor: DomainColor, oldDescription: string, newDescription: string }> | null } | null } | null> } | null, balances?: { __typename?: 'ColonyBalances', items?: Array<{ __typename?: 'ColonyBalance', id: string, balance: string, domain?: { __typename?: 'Domain', id: string, nativeId: number, isRoot: boolean, nativeFundingPotId: number, metadata?: { __typename?: 'DomainMetadata', name: string, color: DomainColor, description: string, changelog?: Array<{ __typename?: 'DomainMetadataChangelog', transactionHash: string, oldName: string, newName: string, oldColor: DomainColor, newColor: DomainColor, oldDescription: string, newDescription: string }> | null } | null } | null, token: { __typename?: 'Token', decimals: number, name: string, symbol: string, type?: TokenType | null, avatar?: string | null, thumbnail?: string | null, tokenAddress: string } } | null> | null } | null, fundsClaims?: { __typename?: 'ModelColonyFundsClaimConnection', items: Array<{ __typename?: 'ColonyFundsClaim', id: string, createdAtBlock: number, createdAt: string, amount: string, token: { __typename?: 'Token', decimals: number, name: string, symbol: string, type?: TokenType | null, avatar?: string | null, thumbnail?: string | null, tokenAddress: string } } | null> } | null, chainFundsClaim?: { __typename?: 'ColonyChainFundsClaim', id: string, createdAtBlock: number, createdAt: string, amount: string } | null, roles?: { __typename?: 'ModelColonyRoleConnection', items: Array<{ __typename?: 'ColonyRole', id: string, targetAddress?: string | null, role_0?: boolean | null, role_1?: boolean | null, role_2?: boolean | null, role_3?: boolean | null, role_5?: boolean | null, role_6?: boolean | null, domain: { __typename?: 'Domain', nativeId: number } } | null> } | null } | null, initiatorExtension?: { __typename?: 'ColonyExtension', hash: string, installedBy: string, installedAt: any, isDeprecated: boolean, isDeleted: boolean, isInitialized: boolean, address: string, colonyAddress: string, currentVersion: number, params?: { __typename?: 'ExtensionParams', votingReputation?: { __typename?: 'VotingReputationParams', maxVoteFraction: string } | null } | null } | null, initiatorToken?: { __typename?: 'Token', decimals: number, name: string, symbol: string, type?: TokenType | null, avatar?: string | null, thumbnail?: string | null, tokenAddress: string } | null, recipientUser?: { __typename?: 'User', name: string, walletAddress: string, profile?: { __typename?: 'Profile', displayName?: string | null, avatar?: string | null, thumbnail?: string | null } | null } | null, recipientColony?: { __typename?: 'Colony', name: string, version: number, colonyAddress: string, metadata?: { __typename?: 'ColonyMetadata', displayName: string, avatar?: string | null, thumbnail?: string | null, isWhitelistActivated?: boolean | null, whitelistedAddresses?: Array | null, changelog?: Array<{ __typename?: 'ColonyMetadataChangelog', transactionHash: string, newDisplayName: string, oldDisplayName: string, hasAvatarChanged: boolean, hasWhitelistChanged: boolean, haveTokensChanged: boolean }> | null } | null, nativeToken: { __typename?: 'Token', decimals: number, name: string, symbol: string, type?: TokenType | null, avatar?: string | null, thumbnail?: string | null, tokenAddress: string }, status?: { __typename?: 'ColonyStatus', recovery?: boolean | null, nativeToken?: { __typename?: 'NativeTokenStatus', mintable?: boolean | null, unlockable?: boolean | null, unlocked?: boolean | null } | null } | null, chainMetadata: { __typename?: 'ChainMetadata', chainId: number }, tokens?: { __typename?: 'ModelColonyTokensConnection', items: Array<{ __typename?: 'ColonyTokens', colonyTokensId: string, token: { __typename?: 'Token', decimals: number, name: string, symbol: string, type?: TokenType | null, avatar?: string | null, thumbnail?: string | null, tokenAddress: string } } | null> } | null, motionsWithUnclaimedStakes?: Array<{ __typename?: 'ColonyUnclaimedStake', motionId: string, unclaimedRewards: Array<{ __typename?: 'StakerRewards', address: string, rewards: { __typename?: 'MotionStakeValues', nay: string, yay: string } }> }> | null, domains?: { __typename?: 'ModelDomainConnection', items: Array<{ __typename?: 'Domain', id: string, nativeId: number, isRoot: boolean, nativeFundingPotId: number, metadata?: { __typename?: 'DomainMetadata', name: string, color: DomainColor, description: string, changelog?: Array<{ __typename?: 'DomainMetadataChangelog', transactionHash: string, oldName: string, newName: string, oldColor: DomainColor, newColor: DomainColor, oldDescription: string, newDescription: string }> | null } | null } | null> } | null, balances?: { __typename?: 'ColonyBalances', items?: Array<{ __typename?: 'ColonyBalance', id: string, balance: string, domain?: { __typename?: 'Domain', id: string, nativeId: number, isRoot: boolean, nativeFundingPotId: number, metadata?: { __typename?: 'DomainMetadata', name: string, color: DomainColor, description: string, changelog?: Array<{ __typename?: 'DomainMetadataChangelog', transactionHash: string, oldName: string, newName: string, oldColor: DomainColor, newColor: DomainColor, oldDescription: string, newDescription: string }> | null } | null } | null, token: { __typename?: 'Token', decimals: number, name: string, symbol: string, type?: TokenType | null, avatar?: string | null, thumbnail?: string | null, tokenAddress: string } } | null> | null } | null, fundsClaims?: { __typename?: 'ModelColonyFundsClaimConnection', items: Array<{ __typename?: 'ColonyFundsClaim', id: string, createdAtBlock: number, createdAt: string, amount: string, token: { __typename?: 'Token', decimals: number, name: string, symbol: string, type?: TokenType | null, avatar?: string | null, thumbnail?: string | null, tokenAddress: string } } | null> } | null, chainFundsClaim?: { __typename?: 'ColonyChainFundsClaim', id: string, createdAtBlock: number, createdAt: string, amount: string } | null, roles?: { __typename?: 'ModelColonyRoleConnection', items: Array<{ __typename?: 'ColonyRole', id: string, targetAddress?: string | null, role_0?: boolean | null, role_1?: boolean | null, role_2?: boolean | null, role_3?: boolean | null, role_5?: boolean | null, role_6?: boolean | null, domain: { __typename?: 'Domain', nativeId: number } } | null> } | null } | null, recipientExtension?: { __typename?: 'ColonyExtension', hash: string, installedBy: string, installedAt: any, isDeprecated: boolean, isDeleted: boolean, isInitialized: boolean, address: string, colonyAddress: string, currentVersion: number, params?: { __typename?: 'ExtensionParams', votingReputation?: { __typename?: 'VotingReputationParams', maxVoteFraction: string } | null } | null } | null, recipientToken?: { __typename?: 'Token', decimals: number, name: string, symbol: string, type?: TokenType | null, avatar?: string | null, thumbnail?: string | null, tokenAddress: string } | null, token?: { __typename?: 'Token', decimals: number, name: string, symbol: string, type?: TokenType | null, avatar?: string | null, thumbnail?: string | null, tokenAddress: string } | null, fromDomain?: { __typename?: 'Domain', id: string, nativeId: number, isRoot: boolean, nativeFundingPotId: number, metadata?: { __typename?: 'DomainMetadata', name: string, color: DomainColor, description: string, changelog?: Array<{ __typename?: 'DomainMetadataChangelog', transactionHash: string, oldName: string, newName: string, oldColor: DomainColor, newColor: DomainColor, oldDescription: string, newDescription: string }> | null } | null } | null, toDomain?: { __typename?: 'Domain', id: string, nativeId: number, isRoot: boolean, nativeFundingPotId: number, metadata?: { __typename?: 'DomainMetadata', name: string, color: DomainColor, description: string, changelog?: Array<{ __typename?: 'DomainMetadataChangelog', transactionHash: string, oldName: string, newName: string, oldColor: DomainColor, newColor: DomainColor, oldDescription: string, newDescription: string }> | null } | null } | null, roles?: { __typename?: 'ColonyActionRoles', role_0?: boolean | null, role_1?: boolean | null, role_2?: boolean | null, role_3?: boolean | null, role_5?: boolean | null, role_6?: boolean | null } | null, motionData?: { __typename?: 'ColonyMotion', remainingStakes: Array, userMinStake: string, requiredStake: string, rootHash: string, nativeMotionDomainId: string, isFinalized: boolean, skillRep: string, repSubmitted: string, hasObjection: boolean, databaseMotionId: string, motionId: string, motionStakes: { __typename?: 'MotionStakes', raw: { __typename?: 'MotionStakeValues', yay: string, nay: string }, percentage: { __typename?: 'MotionStakeValues', yay: string, nay: string } }, usersStakes: Array<{ __typename?: 'UserStakes', address: string, stakes: { __typename?: 'MotionStakes', raw: { __typename?: 'MotionStakeValues', yay: string, nay: string }, percentage: { __typename?: 'MotionStakeValues', yay: string, nay: string } } }>, motionDomain: { __typename?: 'Domain', id: string, nativeId: number, isRoot: boolean, nativeFundingPotId: number, metadata?: { __typename?: 'DomainMetadata', name: string, color: DomainColor, description: string, changelog?: Array<{ __typename?: 'DomainMetadataChangelog', transactionHash: string, oldName: string, newName: string, oldColor: DomainColor, newColor: DomainColor, oldDescription: string, newDescription: string }> | null } | null }, stakerRewards: Array<{ __typename?: 'StakerRewards', address: string, isClaimed: boolean, rewards: { __typename?: 'MotionStakeValues', yay: string, nay: string } }>, voterRecord: Array<{ __typename?: 'VoterRecord', address: string, voteCount: string, vote?: number | null }>, revealedVotes: { __typename?: 'MotionStakes', raw: { __typename?: 'MotionStakeValues', yay: string, nay: string }, percentage: { __typename?: 'MotionStakeValues', yay: string, nay: string } }, motionStateHistory: { __typename?: 'MotionStateHistory', hasVoted: boolean, hasPassed: boolean, hasFailed: boolean, hasFailedNotFinalizable: boolean, inRevealPhase: boolean }, messages?: { __typename?: 'ModelMotionMessageConnection', items: Array<{ __typename?: 'MotionMessage', initiatorAddress: string, name: string, messageKey: string, vote?: string | null, amount?: string | null, initiatorUser?: { __typename?: 'User', name: string, walletAddress: string, profile?: { __typename?: 'Profile', avatar?: string | null, bio?: string | null, displayName?: string | null, email?: string | null, location?: string | null, thumbnail?: string | null, website?: string | null } | null, watchlist?: { __typename?: 'ModelWatchedColoniesConnection', items: Array<{ __typename?: 'WatchedColonies', id: string, createdAt: string, colony: { __typename?: 'Colony', name: string, colonyAddress: string, chainMetadata: { __typename?: 'ChainMetadata', chainId: number }, metadata?: { __typename?: 'ColonyMetadata', displayName: string, avatar?: string | null, thumbnail?: string | null, isWhitelistActivated?: boolean | null, whitelistedAddresses?: Array | null, changelog?: Array<{ __typename?: 'ColonyMetadataChangelog', transactionHash: string, newDisplayName: string, oldDisplayName: string, hasAvatarChanged: boolean, hasWhitelistChanged: boolean, haveTokensChanged: boolean }> | null } | null } } | null> } | null } | null } | null> } | null } | null, colony: { __typename?: 'Colony', colonyAddress: string, nativeToken: { __typename?: 'Token', nativeTokenDecimals: number, nativeTokenSymbol: string, tokenAddress: string } }, pendingDomainMetadata?: { __typename?: 'DomainMetadata', name: string, color: DomainColor, description: string, changelog?: Array<{ __typename?: 'DomainMetadataChangelog', transactionHash: string, oldName: string, newName: string, oldColor: DomainColor, newColor: DomainColor, oldDescription: string, newDescription: string }> | null } | null, pendingColonyMetadata?: { __typename?: 'ColonyMetadata', displayName: string, avatar?: string | null, thumbnail?: string | null, isWhitelistActivated?: boolean | null, whitelistedAddresses?: Array | null, changelog?: Array<{ __typename?: 'ColonyMetadataChangelog', transactionHash: string, newDisplayName: string, oldDisplayName: string, hasAvatarChanged: boolean, hasWhitelistChanged: boolean, haveTokensChanged: boolean }> | null } | null } | null> } | null }; +export type GetColonyActionsQuery = { __typename?: 'Query', getActionsByColony?: { __typename?: 'ModelColonyActionConnection', nextToken?: string | null, items: Array<{ __typename?: 'ColonyAction', type: ColonyActionType, blockNumber: number, initiatorAddress: string, recipientAddress?: string | null, amount?: string | null, tokenAddress?: string | null, createdAt: string, newColonyVersion?: number | null, individualEvents?: string | null, isMotion?: boolean | null, showInActionsList: boolean, transactionHash: string, colonyAddress: string, initiatorUser?: { __typename?: 'User', name: string, walletAddress: string, profile?: { __typename?: 'Profile', displayName?: string | null, avatar?: string | null, thumbnail?: string | null } | null } | null, initiatorColony?: { __typename?: 'Colony', name: string, version: number, colonyAddress: string, metadata?: { __typename?: 'ColonyMetadata', displayName: string, avatar?: string | null, thumbnail?: string | null, isWhitelistActivated?: boolean | null, whitelistedAddresses?: Array | null, changelog?: Array<{ __typename?: 'ColonyMetadataChangelog', transactionHash: string, newDisplayName: string, oldDisplayName: string, hasAvatarChanged: boolean, hasWhitelistChanged: boolean, haveTokensChanged: boolean }> | null } | null, nativeToken: { __typename?: 'Token', decimals: number, name: string, symbol: string, type?: TokenType | null, avatar?: string | null, thumbnail?: string | null, tokenAddress: string }, status?: { __typename?: 'ColonyStatus', recovery?: boolean | null, nativeToken?: { __typename?: 'NativeTokenStatus', mintable?: boolean | null, unlockable?: boolean | null, unlocked?: boolean | null } | null } | null, chainMetadata: { __typename?: 'ChainMetadata', chainId: number }, tokens?: { __typename?: 'ModelColonyTokensConnection', items: Array<{ __typename?: 'ColonyTokens', colonyTokensId: string, token: { __typename?: 'Token', decimals: number, name: string, symbol: string, type?: TokenType | null, avatar?: string | null, thumbnail?: string | null, tokenAddress: string } } | null> } | null, motionsWithUnclaimedStakes?: Array<{ __typename?: 'ColonyUnclaimedStake', motionId: string, unclaimedRewards: Array<{ __typename?: 'StakerRewards', address: string, rewards: { __typename?: 'MotionStakeValues', nay: string, yay: string } }> }> | null, domains?: { __typename?: 'ModelDomainConnection', items: Array<{ __typename?: 'Domain', id: string, nativeId: number, isRoot: boolean, nativeFundingPotId: number, metadata?: { __typename?: 'DomainMetadata', name: string, color: DomainColor, description: string, changelog?: Array<{ __typename?: 'DomainMetadataChangelog', transactionHash: string, oldName: string, newName: string, oldColor: DomainColor, newColor: DomainColor, oldDescription: string, newDescription: string }> | null } | null } | null> } | null, balances?: { __typename?: 'ColonyBalances', items?: Array<{ __typename?: 'ColonyBalance', id: string, balance: string, domain?: { __typename?: 'Domain', id: string, nativeId: number, isRoot: boolean, nativeFundingPotId: number, metadata?: { __typename?: 'DomainMetadata', name: string, color: DomainColor, description: string, changelog?: Array<{ __typename?: 'DomainMetadataChangelog', transactionHash: string, oldName: string, newName: string, oldColor: DomainColor, newColor: DomainColor, oldDescription: string, newDescription: string }> | null } | null } | null, token: { __typename?: 'Token', decimals: number, name: string, symbol: string, type?: TokenType | null, avatar?: string | null, thumbnail?: string | null, tokenAddress: string } } | null> | null } | null, fundsClaims?: { __typename?: 'ModelColonyFundsClaimConnection', items: Array<{ __typename?: 'ColonyFundsClaim', id: string, createdAtBlock: number, createdAt: string, amount: string, token: { __typename?: 'Token', decimals: number, name: string, symbol: string, type?: TokenType | null, avatar?: string | null, thumbnail?: string | null, tokenAddress: string } } | null> } | null, chainFundsClaim?: { __typename?: 'ColonyChainFundsClaim', id: string, createdAtBlock: number, createdAt: string, amount: string } | null, roles?: { __typename?: 'ModelColonyRoleConnection', items: Array<{ __typename?: 'ColonyRole', id: string, targetAddress?: string | null, role_0?: boolean | null, role_1?: boolean | null, role_2?: boolean | null, role_3?: boolean | null, role_5?: boolean | null, role_6?: boolean | null, domain: { __typename?: 'Domain', nativeId: number } } | null> } | null } | null, initiatorExtension?: { __typename?: 'ColonyExtension', hash: string, installedBy: string, installedAt: number, isDeprecated: boolean, isDeleted: boolean, isInitialized: boolean, address: string, colonyAddress: string, currentVersion: number, params?: { __typename?: 'ExtensionParams', votingReputation?: { __typename?: 'VotingReputationParams', maxVoteFraction: string } | null } | null } | null, initiatorToken?: { __typename?: 'Token', decimals: number, name: string, symbol: string, type?: TokenType | null, avatar?: string | null, thumbnail?: string | null, tokenAddress: string } | null, recipientUser?: { __typename?: 'User', name: string, walletAddress: string, profile?: { __typename?: 'Profile', displayName?: string | null, avatar?: string | null, thumbnail?: string | null } | null } | null, recipientColony?: { __typename?: 'Colony', name: string, version: number, colonyAddress: string, metadata?: { __typename?: 'ColonyMetadata', displayName: string, avatar?: string | null, thumbnail?: string | null, isWhitelistActivated?: boolean | null, whitelistedAddresses?: Array | null, changelog?: Array<{ __typename?: 'ColonyMetadataChangelog', transactionHash: string, newDisplayName: string, oldDisplayName: string, hasAvatarChanged: boolean, hasWhitelistChanged: boolean, haveTokensChanged: boolean }> | null } | null, nativeToken: { __typename?: 'Token', decimals: number, name: string, symbol: string, type?: TokenType | null, avatar?: string | null, thumbnail?: string | null, tokenAddress: string }, status?: { __typename?: 'ColonyStatus', recovery?: boolean | null, nativeToken?: { __typename?: 'NativeTokenStatus', mintable?: boolean | null, unlockable?: boolean | null, unlocked?: boolean | null } | null } | null, chainMetadata: { __typename?: 'ChainMetadata', chainId: number }, tokens?: { __typename?: 'ModelColonyTokensConnection', items: Array<{ __typename?: 'ColonyTokens', colonyTokensId: string, token: { __typename?: 'Token', decimals: number, name: string, symbol: string, type?: TokenType | null, avatar?: string | null, thumbnail?: string | null, tokenAddress: string } } | null> } | null, motionsWithUnclaimedStakes?: Array<{ __typename?: 'ColonyUnclaimedStake', motionId: string, unclaimedRewards: Array<{ __typename?: 'StakerRewards', address: string, rewards: { __typename?: 'MotionStakeValues', nay: string, yay: string } }> }> | null, domains?: { __typename?: 'ModelDomainConnection', items: Array<{ __typename?: 'Domain', id: string, nativeId: number, isRoot: boolean, nativeFundingPotId: number, metadata?: { __typename?: 'DomainMetadata', name: string, color: DomainColor, description: string, changelog?: Array<{ __typename?: 'DomainMetadataChangelog', transactionHash: string, oldName: string, newName: string, oldColor: DomainColor, newColor: DomainColor, oldDescription: string, newDescription: string }> | null } | null } | null> } | null, balances?: { __typename?: 'ColonyBalances', items?: Array<{ __typename?: 'ColonyBalance', id: string, balance: string, domain?: { __typename?: 'Domain', id: string, nativeId: number, isRoot: boolean, nativeFundingPotId: number, metadata?: { __typename?: 'DomainMetadata', name: string, color: DomainColor, description: string, changelog?: Array<{ __typename?: 'DomainMetadataChangelog', transactionHash: string, oldName: string, newName: string, oldColor: DomainColor, newColor: DomainColor, oldDescription: string, newDescription: string }> | null } | null } | null, token: { __typename?: 'Token', decimals: number, name: string, symbol: string, type?: TokenType | null, avatar?: string | null, thumbnail?: string | null, tokenAddress: string } } | null> | null } | null, fundsClaims?: { __typename?: 'ModelColonyFundsClaimConnection', items: Array<{ __typename?: 'ColonyFundsClaim', id: string, createdAtBlock: number, createdAt: string, amount: string, token: { __typename?: 'Token', decimals: number, name: string, symbol: string, type?: TokenType | null, avatar?: string | null, thumbnail?: string | null, tokenAddress: string } } | null> } | null, chainFundsClaim?: { __typename?: 'ColonyChainFundsClaim', id: string, createdAtBlock: number, createdAt: string, amount: string } | null, roles?: { __typename?: 'ModelColonyRoleConnection', items: Array<{ __typename?: 'ColonyRole', id: string, targetAddress?: string | null, role_0?: boolean | null, role_1?: boolean | null, role_2?: boolean | null, role_3?: boolean | null, role_5?: boolean | null, role_6?: boolean | null, domain: { __typename?: 'Domain', nativeId: number } } | null> } | null } | null, recipientExtension?: { __typename?: 'ColonyExtension', hash: string, installedBy: string, installedAt: number, isDeprecated: boolean, isDeleted: boolean, isInitialized: boolean, address: string, colonyAddress: string, currentVersion: number, params?: { __typename?: 'ExtensionParams', votingReputation?: { __typename?: 'VotingReputationParams', maxVoteFraction: string } | null } | null } | null, recipientToken?: { __typename?: 'Token', decimals: number, name: string, symbol: string, type?: TokenType | null, avatar?: string | null, thumbnail?: string | null, tokenAddress: string } | null, token?: { __typename?: 'Token', decimals: number, name: string, symbol: string, type?: TokenType | null, avatar?: string | null, thumbnail?: string | null, tokenAddress: string } | null, fromDomain?: { __typename?: 'Domain', id: string, nativeId: number, isRoot: boolean, nativeFundingPotId: number, metadata?: { __typename?: 'DomainMetadata', name: string, color: DomainColor, description: string, changelog?: Array<{ __typename?: 'DomainMetadataChangelog', transactionHash: string, oldName: string, newName: string, oldColor: DomainColor, newColor: DomainColor, oldDescription: string, newDescription: string }> | null } | null } | null, toDomain?: { __typename?: 'Domain', id: string, nativeId: number, isRoot: boolean, nativeFundingPotId: number, metadata?: { __typename?: 'DomainMetadata', name: string, color: DomainColor, description: string, changelog?: Array<{ __typename?: 'DomainMetadataChangelog', transactionHash: string, oldName: string, newName: string, oldColor: DomainColor, newColor: DomainColor, oldDescription: string, newDescription: string }> | null } | null } | null, roles?: { __typename?: 'ColonyActionRoles', role_0?: boolean | null, role_1?: boolean | null, role_2?: boolean | null, role_3?: boolean | null, role_5?: boolean | null, role_6?: boolean | null } | null, motionData?: { __typename?: 'ColonyMotion', remainingStakes: Array, userMinStake: string, requiredStake: string, rootHash: string, nativeMotionDomainId: string, isFinalized: boolean, skillRep: string, repSubmitted: string, hasObjection: boolean, databaseMotionId: string, motionId: string, motionStakes: { __typename?: 'MotionStakes', raw: { __typename?: 'MotionStakeValues', yay: string, nay: string }, percentage: { __typename?: 'MotionStakeValues', yay: string, nay: string } }, usersStakes: Array<{ __typename?: 'UserStakes', address: string, stakes: { __typename?: 'MotionStakes', raw: { __typename?: 'MotionStakeValues', yay: string, nay: string }, percentage: { __typename?: 'MotionStakeValues', yay: string, nay: string } } }>, motionDomain: { __typename?: 'Domain', id: string, nativeId: number, isRoot: boolean, nativeFundingPotId: number, metadata?: { __typename?: 'DomainMetadata', name: string, color: DomainColor, description: string, changelog?: Array<{ __typename?: 'DomainMetadataChangelog', transactionHash: string, oldName: string, newName: string, oldColor: DomainColor, newColor: DomainColor, oldDescription: string, newDescription: string }> | null } | null }, stakerRewards: Array<{ __typename?: 'StakerRewards', address: string, isClaimed: boolean, rewards: { __typename?: 'MotionStakeValues', yay: string, nay: string } }>, voterRecord: Array<{ __typename?: 'VoterRecord', address: string, voteCount: string, vote?: number | null }>, revealedVotes: { __typename?: 'MotionStakes', raw: { __typename?: 'MotionStakeValues', yay: string, nay: string }, percentage: { __typename?: 'MotionStakeValues', yay: string, nay: string } }, motionStateHistory: { __typename?: 'MotionStateHistory', hasVoted: boolean, hasPassed: boolean, hasFailed: boolean, hasFailedNotFinalizable: boolean, inRevealPhase: boolean }, messages?: { __typename?: 'ModelMotionMessageConnection', items: Array<{ __typename?: 'MotionMessage', initiatorAddress: string, name: string, messageKey: string, vote?: string | null, amount?: string | null, initiatorUser?: { __typename?: 'User', name: string, walletAddress: string, profile?: { __typename?: 'Profile', avatar?: string | null, bio?: string | null, displayName?: string | null, email?: string | null, location?: string | null, thumbnail?: string | null, website?: string | null } | null, watchlist?: { __typename?: 'ModelWatchedColoniesConnection', items: Array<{ __typename?: 'WatchedColonies', id: string, createdAt: string, colony: { __typename?: 'Colony', name: string, colonyAddress: string, chainMetadata: { __typename?: 'ChainMetadata', chainId: number }, metadata?: { __typename?: 'ColonyMetadata', displayName: string, avatar?: string | null, thumbnail?: string | null, isWhitelistActivated?: boolean | null, whitelistedAddresses?: Array | null, changelog?: Array<{ __typename?: 'ColonyMetadataChangelog', transactionHash: string, newDisplayName: string, oldDisplayName: string, hasAvatarChanged: boolean, hasWhitelistChanged: boolean, haveTokensChanged: boolean }> | null } | null } } | null> } | null } | null } | null> } | null } | null, colony: { __typename?: 'Colony', colonyAddress: string, nativeToken: { __typename?: 'Token', nativeTokenDecimals: number, nativeTokenSymbol: string, tokenAddress: string } }, pendingDomainMetadata?: { __typename?: 'DomainMetadata', name: string, color: DomainColor, description: string, changelog?: Array<{ __typename?: 'DomainMetadataChangelog', transactionHash: string, oldName: string, newName: string, oldColor: DomainColor, newColor: DomainColor, oldDescription: string, newDescription: string }> | null } | null, pendingColonyMetadata?: { __typename?: 'ColonyMetadata', displayName: string, avatar?: string | null, thumbnail?: string | null, isWhitelistActivated?: boolean | null, whitelistedAddresses?: Array | null, changelog?: Array<{ __typename?: 'ColonyMetadataChangelog', transactionHash: string, newDisplayName: string, oldDisplayName: string, hasAvatarChanged: boolean, hasWhitelistChanged: boolean, haveTokensChanged: boolean }> | null } | null } | null> } | null }; export type GetColonyActionQueryVariables = Exact<{ transactionHash: Scalars['ID']; }>; -export type GetColonyActionQuery = { __typename?: 'Query', getColonyAction?: { __typename?: 'ColonyAction', type: ColonyActionType, blockNumber: number, initiatorAddress: string, recipientAddress?: string | null, amount?: string | null, tokenAddress?: string | null, createdAt: string, newColonyVersion?: number | null, individualEvents?: string | null, isMotion?: boolean | null, showInActionsList: boolean, transactionHash: string, colonyAddress: string, initiatorUser?: { __typename?: 'User', name: string, walletAddress: string, profile?: { __typename?: 'Profile', displayName?: string | null, avatar?: string | null, thumbnail?: string | null } | null } | null, initiatorColony?: { __typename?: 'Colony', name: string, version: number, colonyAddress: string, metadata?: { __typename?: 'ColonyMetadata', displayName: string, avatar?: string | null, thumbnail?: string | null, isWhitelistActivated?: boolean | null, whitelistedAddresses?: Array | null, changelog?: Array<{ __typename?: 'ColonyMetadataChangelog', transactionHash: string, newDisplayName: string, oldDisplayName: string, hasAvatarChanged: boolean, hasWhitelistChanged: boolean, haveTokensChanged: boolean }> | null } | null, nativeToken: { __typename?: 'Token', decimals: number, name: string, symbol: string, type?: TokenType | null, avatar?: string | null, thumbnail?: string | null, tokenAddress: string }, status?: { __typename?: 'ColonyStatus', recovery?: boolean | null, nativeToken?: { __typename?: 'NativeTokenStatus', mintable?: boolean | null, unlockable?: boolean | null, unlocked?: boolean | null } | null } | null, chainMetadata: { __typename?: 'ChainMetadata', chainId: number }, tokens?: { __typename?: 'ModelColonyTokensConnection', items: Array<{ __typename?: 'ColonyTokens', colonyTokensId: string, token: { __typename?: 'Token', decimals: number, name: string, symbol: string, type?: TokenType | null, avatar?: string | null, thumbnail?: string | null, tokenAddress: string } } | null> } | null, motionsWithUnclaimedStakes?: Array<{ __typename?: 'ColonyUnclaimedStake', motionId: string, unclaimedRewards: Array<{ __typename?: 'StakerRewards', address: string, rewards: { __typename?: 'MotionStakeValues', nay: string, yay: string } }> }> | null, domains?: { __typename?: 'ModelDomainConnection', items: Array<{ __typename?: 'Domain', id: string, nativeId: number, isRoot: boolean, nativeFundingPotId: number, metadata?: { __typename?: 'DomainMetadata', name: string, color: DomainColor, description: string, changelog?: Array<{ __typename?: 'DomainMetadataChangelog', transactionHash: string, oldName: string, newName: string, oldColor: DomainColor, newColor: DomainColor, oldDescription: string, newDescription: string }> | null } | null } | null> } | null, balances?: { __typename?: 'ColonyBalances', items?: Array<{ __typename?: 'ColonyBalance', id: string, balance: string, domain?: { __typename?: 'Domain', id: string, nativeId: number, isRoot: boolean, nativeFundingPotId: number, metadata?: { __typename?: 'DomainMetadata', name: string, color: DomainColor, description: string, changelog?: Array<{ __typename?: 'DomainMetadataChangelog', transactionHash: string, oldName: string, newName: string, oldColor: DomainColor, newColor: DomainColor, oldDescription: string, newDescription: string }> | null } | null } | null, token: { __typename?: 'Token', decimals: number, name: string, symbol: string, type?: TokenType | null, avatar?: string | null, thumbnail?: string | null, tokenAddress: string } } | null> | null } | null, fundsClaims?: { __typename?: 'ModelColonyFundsClaimConnection', items: Array<{ __typename?: 'ColonyFundsClaim', id: string, createdAtBlock: number, createdAt: string, amount: string, token: { __typename?: 'Token', decimals: number, name: string, symbol: string, type?: TokenType | null, avatar?: string | null, thumbnail?: string | null, tokenAddress: string } } | null> } | null, chainFundsClaim?: { __typename?: 'ColonyChainFundsClaim', id: string, createdAtBlock: number, createdAt: string, amount: string } | null, roles?: { __typename?: 'ModelColonyRoleConnection', items: Array<{ __typename?: 'ColonyRole', id: string, targetAddress?: string | null, role_0?: boolean | null, role_1?: boolean | null, role_2?: boolean | null, role_3?: boolean | null, role_5?: boolean | null, role_6?: boolean | null, domain: { __typename?: 'Domain', nativeId: number } } | null> } | null } | null, initiatorExtension?: { __typename?: 'ColonyExtension', hash: string, installedBy: string, installedAt: any, isDeprecated: boolean, isDeleted: boolean, isInitialized: boolean, address: string, colonyAddress: string, currentVersion: number, params?: { __typename?: 'ExtensionParams', votingReputation?: { __typename?: 'VotingReputationParams', maxVoteFraction: string } | null } | null } | null, initiatorToken?: { __typename?: 'Token', decimals: number, name: string, symbol: string, type?: TokenType | null, avatar?: string | null, thumbnail?: string | null, tokenAddress: string } | null, recipientUser?: { __typename?: 'User', name: string, walletAddress: string, profile?: { __typename?: 'Profile', displayName?: string | null, avatar?: string | null, thumbnail?: string | null } | null } | null, recipientColony?: { __typename?: 'Colony', name: string, version: number, colonyAddress: string, metadata?: { __typename?: 'ColonyMetadata', displayName: string, avatar?: string | null, thumbnail?: string | null, isWhitelistActivated?: boolean | null, whitelistedAddresses?: Array | null, changelog?: Array<{ __typename?: 'ColonyMetadataChangelog', transactionHash: string, newDisplayName: string, oldDisplayName: string, hasAvatarChanged: boolean, hasWhitelistChanged: boolean, haveTokensChanged: boolean }> | null } | null, nativeToken: { __typename?: 'Token', decimals: number, name: string, symbol: string, type?: TokenType | null, avatar?: string | null, thumbnail?: string | null, tokenAddress: string }, status?: { __typename?: 'ColonyStatus', recovery?: boolean | null, nativeToken?: { __typename?: 'NativeTokenStatus', mintable?: boolean | null, unlockable?: boolean | null, unlocked?: boolean | null } | null } | null, chainMetadata: { __typename?: 'ChainMetadata', chainId: number }, tokens?: { __typename?: 'ModelColonyTokensConnection', items: Array<{ __typename?: 'ColonyTokens', colonyTokensId: string, token: { __typename?: 'Token', decimals: number, name: string, symbol: string, type?: TokenType | null, avatar?: string | null, thumbnail?: string | null, tokenAddress: string } } | null> } | null, motionsWithUnclaimedStakes?: Array<{ __typename?: 'ColonyUnclaimedStake', motionId: string, unclaimedRewards: Array<{ __typename?: 'StakerRewards', address: string, rewards: { __typename?: 'MotionStakeValues', nay: string, yay: string } }> }> | null, domains?: { __typename?: 'ModelDomainConnection', items: Array<{ __typename?: 'Domain', id: string, nativeId: number, isRoot: boolean, nativeFundingPotId: number, metadata?: { __typename?: 'DomainMetadata', name: string, color: DomainColor, description: string, changelog?: Array<{ __typename?: 'DomainMetadataChangelog', transactionHash: string, oldName: string, newName: string, oldColor: DomainColor, newColor: DomainColor, oldDescription: string, newDescription: string }> | null } | null } | null> } | null, balances?: { __typename?: 'ColonyBalances', items?: Array<{ __typename?: 'ColonyBalance', id: string, balance: string, domain?: { __typename?: 'Domain', id: string, nativeId: number, isRoot: boolean, nativeFundingPotId: number, metadata?: { __typename?: 'DomainMetadata', name: string, color: DomainColor, description: string, changelog?: Array<{ __typename?: 'DomainMetadataChangelog', transactionHash: string, oldName: string, newName: string, oldColor: DomainColor, newColor: DomainColor, oldDescription: string, newDescription: string }> | null } | null } | null, token: { __typename?: 'Token', decimals: number, name: string, symbol: string, type?: TokenType | null, avatar?: string | null, thumbnail?: string | null, tokenAddress: string } } | null> | null } | null, fundsClaims?: { __typename?: 'ModelColonyFundsClaimConnection', items: Array<{ __typename?: 'ColonyFundsClaim', id: string, createdAtBlock: number, createdAt: string, amount: string, token: { __typename?: 'Token', decimals: number, name: string, symbol: string, type?: TokenType | null, avatar?: string | null, thumbnail?: string | null, tokenAddress: string } } | null> } | null, chainFundsClaim?: { __typename?: 'ColonyChainFundsClaim', id: string, createdAtBlock: number, createdAt: string, amount: string } | null, roles?: { __typename?: 'ModelColonyRoleConnection', items: Array<{ __typename?: 'ColonyRole', id: string, targetAddress?: string | null, role_0?: boolean | null, role_1?: boolean | null, role_2?: boolean | null, role_3?: boolean | null, role_5?: boolean | null, role_6?: boolean | null, domain: { __typename?: 'Domain', nativeId: number } } | null> } | null } | null, recipientExtension?: { __typename?: 'ColonyExtension', hash: string, installedBy: string, installedAt: any, isDeprecated: boolean, isDeleted: boolean, isInitialized: boolean, address: string, colonyAddress: string, currentVersion: number, params?: { __typename?: 'ExtensionParams', votingReputation?: { __typename?: 'VotingReputationParams', maxVoteFraction: string } | null } | null } | null, recipientToken?: { __typename?: 'Token', decimals: number, name: string, symbol: string, type?: TokenType | null, avatar?: string | null, thumbnail?: string | null, tokenAddress: string } | null, token?: { __typename?: 'Token', decimals: number, name: string, symbol: string, type?: TokenType | null, avatar?: string | null, thumbnail?: string | null, tokenAddress: string } | null, fromDomain?: { __typename?: 'Domain', id: string, nativeId: number, isRoot: boolean, nativeFundingPotId: number, metadata?: { __typename?: 'DomainMetadata', name: string, color: DomainColor, description: string, changelog?: Array<{ __typename?: 'DomainMetadataChangelog', transactionHash: string, oldName: string, newName: string, oldColor: DomainColor, newColor: DomainColor, oldDescription: string, newDescription: string }> | null } | null } | null, toDomain?: { __typename?: 'Domain', id: string, nativeId: number, isRoot: boolean, nativeFundingPotId: number, metadata?: { __typename?: 'DomainMetadata', name: string, color: DomainColor, description: string, changelog?: Array<{ __typename?: 'DomainMetadataChangelog', transactionHash: string, oldName: string, newName: string, oldColor: DomainColor, newColor: DomainColor, oldDescription: string, newDescription: string }> | null } | null } | null, roles?: { __typename?: 'ColonyActionRoles', role_0?: boolean | null, role_1?: boolean | null, role_2?: boolean | null, role_3?: boolean | null, role_5?: boolean | null, role_6?: boolean | null } | null, motionData?: { __typename?: 'ColonyMotion', remainingStakes: Array, userMinStake: string, requiredStake: string, rootHash: string, nativeMotionDomainId: string, isFinalized: boolean, skillRep: string, repSubmitted: string, hasObjection: boolean, databaseMotionId: string, motionId: string, motionStakes: { __typename?: 'MotionStakes', raw: { __typename?: 'MotionStakeValues', yay: string, nay: string }, percentage: { __typename?: 'MotionStakeValues', yay: string, nay: string } }, usersStakes: Array<{ __typename?: 'UserStakes', address: string, stakes: { __typename?: 'MotionStakes', raw: { __typename?: 'MotionStakeValues', yay: string, nay: string }, percentage: { __typename?: 'MotionStakeValues', yay: string, nay: string } } }>, motionDomain: { __typename?: 'Domain', id: string, nativeId: number, isRoot: boolean, nativeFundingPotId: number, metadata?: { __typename?: 'DomainMetadata', name: string, color: DomainColor, description: string, changelog?: Array<{ __typename?: 'DomainMetadataChangelog', transactionHash: string, oldName: string, newName: string, oldColor: DomainColor, newColor: DomainColor, oldDescription: string, newDescription: string }> | null } | null }, stakerRewards: Array<{ __typename?: 'StakerRewards', address: string, isClaimed: boolean, rewards: { __typename?: 'MotionStakeValues', yay: string, nay: string } }>, voterRecord: Array<{ __typename?: 'VoterRecord', address: string, voteCount: string, vote?: number | null }>, revealedVotes: { __typename?: 'MotionStakes', raw: { __typename?: 'MotionStakeValues', yay: string, nay: string }, percentage: { __typename?: 'MotionStakeValues', yay: string, nay: string } }, motionStateHistory: { __typename?: 'MotionStateHistory', hasVoted: boolean, hasPassed: boolean, hasFailed: boolean, hasFailedNotFinalizable: boolean, inRevealPhase: boolean }, messages?: { __typename?: 'ModelMotionMessageConnection', items: Array<{ __typename?: 'MotionMessage', initiatorAddress: string, name: string, messageKey: string, vote?: string | null, amount?: string | null, initiatorUser?: { __typename?: 'User', name: string, walletAddress: string, profile?: { __typename?: 'Profile', avatar?: string | null, bio?: string | null, displayName?: string | null, email?: string | null, location?: string | null, thumbnail?: string | null, website?: string | null } | null, watchlist?: { __typename?: 'ModelWatchedColoniesConnection', items: Array<{ __typename?: 'WatchedColonies', id: string, createdAt: string, colony: { __typename?: 'Colony', name: string, colonyAddress: string, chainMetadata: { __typename?: 'ChainMetadata', chainId: number }, metadata?: { __typename?: 'ColonyMetadata', displayName: string, avatar?: string | null, thumbnail?: string | null, isWhitelistActivated?: boolean | null, whitelistedAddresses?: Array | null, changelog?: Array<{ __typename?: 'ColonyMetadataChangelog', transactionHash: string, newDisplayName: string, oldDisplayName: string, hasAvatarChanged: boolean, hasWhitelistChanged: boolean, haveTokensChanged: boolean }> | null } | null } } | null> } | null } | null } | null> } | null } | null, colony: { __typename?: 'Colony', colonyAddress: string, nativeToken: { __typename?: 'Token', nativeTokenDecimals: number, nativeTokenSymbol: string, tokenAddress: string } }, pendingDomainMetadata?: { __typename?: 'DomainMetadata', name: string, color: DomainColor, description: string, changelog?: Array<{ __typename?: 'DomainMetadataChangelog', transactionHash: string, oldName: string, newName: string, oldColor: DomainColor, newColor: DomainColor, oldDescription: string, newDescription: string }> | null } | null, pendingColonyMetadata?: { __typename?: 'ColonyMetadata', displayName: string, avatar?: string | null, thumbnail?: string | null, isWhitelistActivated?: boolean | null, whitelistedAddresses?: Array | null, changelog?: Array<{ __typename?: 'ColonyMetadataChangelog', transactionHash: string, newDisplayName: string, oldDisplayName: string, hasAvatarChanged: boolean, hasWhitelistChanged: boolean, haveTokensChanged: boolean }> | null } | null } | null }; +export type GetColonyActionQuery = { __typename?: 'Query', getColonyAction?: { __typename?: 'ColonyAction', type: ColonyActionType, blockNumber: number, initiatorAddress: string, recipientAddress?: string | null, amount?: string | null, tokenAddress?: string | null, createdAt: string, newColonyVersion?: number | null, individualEvents?: string | null, isMotion?: boolean | null, showInActionsList: boolean, transactionHash: string, colonyAddress: string, initiatorUser?: { __typename?: 'User', name: string, walletAddress: string, profile?: { __typename?: 'Profile', displayName?: string | null, avatar?: string | null, thumbnail?: string | null } | null } | null, initiatorColony?: { __typename?: 'Colony', name: string, version: number, colonyAddress: string, metadata?: { __typename?: 'ColonyMetadata', displayName: string, avatar?: string | null, thumbnail?: string | null, isWhitelistActivated?: boolean | null, whitelistedAddresses?: Array | null, changelog?: Array<{ __typename?: 'ColonyMetadataChangelog', transactionHash: string, newDisplayName: string, oldDisplayName: string, hasAvatarChanged: boolean, hasWhitelistChanged: boolean, haveTokensChanged: boolean }> | null } | null, nativeToken: { __typename?: 'Token', decimals: number, name: string, symbol: string, type?: TokenType | null, avatar?: string | null, thumbnail?: string | null, tokenAddress: string }, status?: { __typename?: 'ColonyStatus', recovery?: boolean | null, nativeToken?: { __typename?: 'NativeTokenStatus', mintable?: boolean | null, unlockable?: boolean | null, unlocked?: boolean | null } | null } | null, chainMetadata: { __typename?: 'ChainMetadata', chainId: number }, tokens?: { __typename?: 'ModelColonyTokensConnection', items: Array<{ __typename?: 'ColonyTokens', colonyTokensId: string, token: { __typename?: 'Token', decimals: number, name: string, symbol: string, type?: TokenType | null, avatar?: string | null, thumbnail?: string | null, tokenAddress: string } } | null> } | null, motionsWithUnclaimedStakes?: Array<{ __typename?: 'ColonyUnclaimedStake', motionId: string, unclaimedRewards: Array<{ __typename?: 'StakerRewards', address: string, rewards: { __typename?: 'MotionStakeValues', nay: string, yay: string } }> }> | null, domains?: { __typename?: 'ModelDomainConnection', items: Array<{ __typename?: 'Domain', id: string, nativeId: number, isRoot: boolean, nativeFundingPotId: number, metadata?: { __typename?: 'DomainMetadata', name: string, color: DomainColor, description: string, changelog?: Array<{ __typename?: 'DomainMetadataChangelog', transactionHash: string, oldName: string, newName: string, oldColor: DomainColor, newColor: DomainColor, oldDescription: string, newDescription: string }> | null } | null } | null> } | null, balances?: { __typename?: 'ColonyBalances', items?: Array<{ __typename?: 'ColonyBalance', id: string, balance: string, domain?: { __typename?: 'Domain', id: string, nativeId: number, isRoot: boolean, nativeFundingPotId: number, metadata?: { __typename?: 'DomainMetadata', name: string, color: DomainColor, description: string, changelog?: Array<{ __typename?: 'DomainMetadataChangelog', transactionHash: string, oldName: string, newName: string, oldColor: DomainColor, newColor: DomainColor, oldDescription: string, newDescription: string }> | null } | null } | null, token: { __typename?: 'Token', decimals: number, name: string, symbol: string, type?: TokenType | null, avatar?: string | null, thumbnail?: string | null, tokenAddress: string } } | null> | null } | null, fundsClaims?: { __typename?: 'ModelColonyFundsClaimConnection', items: Array<{ __typename?: 'ColonyFundsClaim', id: string, createdAtBlock: number, createdAt: string, amount: string, token: { __typename?: 'Token', decimals: number, name: string, symbol: string, type?: TokenType | null, avatar?: string | null, thumbnail?: string | null, tokenAddress: string } } | null> } | null, chainFundsClaim?: { __typename?: 'ColonyChainFundsClaim', id: string, createdAtBlock: number, createdAt: string, amount: string } | null, roles?: { __typename?: 'ModelColonyRoleConnection', items: Array<{ __typename?: 'ColonyRole', id: string, targetAddress?: string | null, role_0?: boolean | null, role_1?: boolean | null, role_2?: boolean | null, role_3?: boolean | null, role_5?: boolean | null, role_6?: boolean | null, domain: { __typename?: 'Domain', nativeId: number } } | null> } | null } | null, initiatorExtension?: { __typename?: 'ColonyExtension', hash: string, installedBy: string, installedAt: number, isDeprecated: boolean, isDeleted: boolean, isInitialized: boolean, address: string, colonyAddress: string, currentVersion: number, params?: { __typename?: 'ExtensionParams', votingReputation?: { __typename?: 'VotingReputationParams', maxVoteFraction: string } | null } | null } | null, initiatorToken?: { __typename?: 'Token', decimals: number, name: string, symbol: string, type?: TokenType | null, avatar?: string | null, thumbnail?: string | null, tokenAddress: string } | null, recipientUser?: { __typename?: 'User', name: string, walletAddress: string, profile?: { __typename?: 'Profile', displayName?: string | null, avatar?: string | null, thumbnail?: string | null } | null } | null, recipientColony?: { __typename?: 'Colony', name: string, version: number, colonyAddress: string, metadata?: { __typename?: 'ColonyMetadata', displayName: string, avatar?: string | null, thumbnail?: string | null, isWhitelistActivated?: boolean | null, whitelistedAddresses?: Array | null, changelog?: Array<{ __typename?: 'ColonyMetadataChangelog', transactionHash: string, newDisplayName: string, oldDisplayName: string, hasAvatarChanged: boolean, hasWhitelistChanged: boolean, haveTokensChanged: boolean }> | null } | null, nativeToken: { __typename?: 'Token', decimals: number, name: string, symbol: string, type?: TokenType | null, avatar?: string | null, thumbnail?: string | null, tokenAddress: string }, status?: { __typename?: 'ColonyStatus', recovery?: boolean | null, nativeToken?: { __typename?: 'NativeTokenStatus', mintable?: boolean | null, unlockable?: boolean | null, unlocked?: boolean | null } | null } | null, chainMetadata: { __typename?: 'ChainMetadata', chainId: number }, tokens?: { __typename?: 'ModelColonyTokensConnection', items: Array<{ __typename?: 'ColonyTokens', colonyTokensId: string, token: { __typename?: 'Token', decimals: number, name: string, symbol: string, type?: TokenType | null, avatar?: string | null, thumbnail?: string | null, tokenAddress: string } } | null> } | null, motionsWithUnclaimedStakes?: Array<{ __typename?: 'ColonyUnclaimedStake', motionId: string, unclaimedRewards: Array<{ __typename?: 'StakerRewards', address: string, rewards: { __typename?: 'MotionStakeValues', nay: string, yay: string } }> }> | null, domains?: { __typename?: 'ModelDomainConnection', items: Array<{ __typename?: 'Domain', id: string, nativeId: number, isRoot: boolean, nativeFundingPotId: number, metadata?: { __typename?: 'DomainMetadata', name: string, color: DomainColor, description: string, changelog?: Array<{ __typename?: 'DomainMetadataChangelog', transactionHash: string, oldName: string, newName: string, oldColor: DomainColor, newColor: DomainColor, oldDescription: string, newDescription: string }> | null } | null } | null> } | null, balances?: { __typename?: 'ColonyBalances', items?: Array<{ __typename?: 'ColonyBalance', id: string, balance: string, domain?: { __typename?: 'Domain', id: string, nativeId: number, isRoot: boolean, nativeFundingPotId: number, metadata?: { __typename?: 'DomainMetadata', name: string, color: DomainColor, description: string, changelog?: Array<{ __typename?: 'DomainMetadataChangelog', transactionHash: string, oldName: string, newName: string, oldColor: DomainColor, newColor: DomainColor, oldDescription: string, newDescription: string }> | null } | null } | null, token: { __typename?: 'Token', decimals: number, name: string, symbol: string, type?: TokenType | null, avatar?: string | null, thumbnail?: string | null, tokenAddress: string } } | null> | null } | null, fundsClaims?: { __typename?: 'ModelColonyFundsClaimConnection', items: Array<{ __typename?: 'ColonyFundsClaim', id: string, createdAtBlock: number, createdAt: string, amount: string, token: { __typename?: 'Token', decimals: number, name: string, symbol: string, type?: TokenType | null, avatar?: string | null, thumbnail?: string | null, tokenAddress: string } } | null> } | null, chainFundsClaim?: { __typename?: 'ColonyChainFundsClaim', id: string, createdAtBlock: number, createdAt: string, amount: string } | null, roles?: { __typename?: 'ModelColonyRoleConnection', items: Array<{ __typename?: 'ColonyRole', id: string, targetAddress?: string | null, role_0?: boolean | null, role_1?: boolean | null, role_2?: boolean | null, role_3?: boolean | null, role_5?: boolean | null, role_6?: boolean | null, domain: { __typename?: 'Domain', nativeId: number } } | null> } | null } | null, recipientExtension?: { __typename?: 'ColonyExtension', hash: string, installedBy: string, installedAt: number, isDeprecated: boolean, isDeleted: boolean, isInitialized: boolean, address: string, colonyAddress: string, currentVersion: number, params?: { __typename?: 'ExtensionParams', votingReputation?: { __typename?: 'VotingReputationParams', maxVoteFraction: string } | null } | null } | null, recipientToken?: { __typename?: 'Token', decimals: number, name: string, symbol: string, type?: TokenType | null, avatar?: string | null, thumbnail?: string | null, tokenAddress: string } | null, token?: { __typename?: 'Token', decimals: number, name: string, symbol: string, type?: TokenType | null, avatar?: string | null, thumbnail?: string | null, tokenAddress: string } | null, fromDomain?: { __typename?: 'Domain', id: string, nativeId: number, isRoot: boolean, nativeFundingPotId: number, metadata?: { __typename?: 'DomainMetadata', name: string, color: DomainColor, description: string, changelog?: Array<{ __typename?: 'DomainMetadataChangelog', transactionHash: string, oldName: string, newName: string, oldColor: DomainColor, newColor: DomainColor, oldDescription: string, newDescription: string }> | null } | null } | null, toDomain?: { __typename?: 'Domain', id: string, nativeId: number, isRoot: boolean, nativeFundingPotId: number, metadata?: { __typename?: 'DomainMetadata', name: string, color: DomainColor, description: string, changelog?: Array<{ __typename?: 'DomainMetadataChangelog', transactionHash: string, oldName: string, newName: string, oldColor: DomainColor, newColor: DomainColor, oldDescription: string, newDescription: string }> | null } | null } | null, roles?: { __typename?: 'ColonyActionRoles', role_0?: boolean | null, role_1?: boolean | null, role_2?: boolean | null, role_3?: boolean | null, role_5?: boolean | null, role_6?: boolean | null } | null, motionData?: { __typename?: 'ColonyMotion', remainingStakes: Array, userMinStake: string, requiredStake: string, rootHash: string, nativeMotionDomainId: string, isFinalized: boolean, skillRep: string, repSubmitted: string, hasObjection: boolean, databaseMotionId: string, motionId: string, motionStakes: { __typename?: 'MotionStakes', raw: { __typename?: 'MotionStakeValues', yay: string, nay: string }, percentage: { __typename?: 'MotionStakeValues', yay: string, nay: string } }, usersStakes: Array<{ __typename?: 'UserStakes', address: string, stakes: { __typename?: 'MotionStakes', raw: { __typename?: 'MotionStakeValues', yay: string, nay: string }, percentage: { __typename?: 'MotionStakeValues', yay: string, nay: string } } }>, motionDomain: { __typename?: 'Domain', id: string, nativeId: number, isRoot: boolean, nativeFundingPotId: number, metadata?: { __typename?: 'DomainMetadata', name: string, color: DomainColor, description: string, changelog?: Array<{ __typename?: 'DomainMetadataChangelog', transactionHash: string, oldName: string, newName: string, oldColor: DomainColor, newColor: DomainColor, oldDescription: string, newDescription: string }> | null } | null }, stakerRewards: Array<{ __typename?: 'StakerRewards', address: string, isClaimed: boolean, rewards: { __typename?: 'MotionStakeValues', yay: string, nay: string } }>, voterRecord: Array<{ __typename?: 'VoterRecord', address: string, voteCount: string, vote?: number | null }>, revealedVotes: { __typename?: 'MotionStakes', raw: { __typename?: 'MotionStakeValues', yay: string, nay: string }, percentage: { __typename?: 'MotionStakeValues', yay: string, nay: string } }, motionStateHistory: { __typename?: 'MotionStateHistory', hasVoted: boolean, hasPassed: boolean, hasFailed: boolean, hasFailedNotFinalizable: boolean, inRevealPhase: boolean }, messages?: { __typename?: 'ModelMotionMessageConnection', items: Array<{ __typename?: 'MotionMessage', initiatorAddress: string, name: string, messageKey: string, vote?: string | null, amount?: string | null, initiatorUser?: { __typename?: 'User', name: string, walletAddress: string, profile?: { __typename?: 'Profile', avatar?: string | null, bio?: string | null, displayName?: string | null, email?: string | null, location?: string | null, thumbnail?: string | null, website?: string | null } | null, watchlist?: { __typename?: 'ModelWatchedColoniesConnection', items: Array<{ __typename?: 'WatchedColonies', id: string, createdAt: string, colony: { __typename?: 'Colony', name: string, colonyAddress: string, chainMetadata: { __typename?: 'ChainMetadata', chainId: number }, metadata?: { __typename?: 'ColonyMetadata', displayName: string, avatar?: string | null, thumbnail?: string | null, isWhitelistActivated?: boolean | null, whitelistedAddresses?: Array | null, changelog?: Array<{ __typename?: 'ColonyMetadataChangelog', transactionHash: string, newDisplayName: string, oldDisplayName: string, hasAvatarChanged: boolean, hasWhitelistChanged: boolean, haveTokensChanged: boolean }> | null } | null } } | null> } | null } | null } | null> } | null } | null, colony: { __typename?: 'Colony', colonyAddress: string, nativeToken: { __typename?: 'Token', nativeTokenDecimals: number, nativeTokenSymbol: string, tokenAddress: string } }, pendingDomainMetadata?: { __typename?: 'DomainMetadata', name: string, color: DomainColor, description: string, changelog?: Array<{ __typename?: 'DomainMetadataChangelog', transactionHash: string, oldName: string, newName: string, oldColor: DomainColor, newColor: DomainColor, oldDescription: string, newDescription: string }> | null } | null, pendingColonyMetadata?: { __typename?: 'ColonyMetadata', displayName: string, avatar?: string | null, thumbnail?: string | null, isWhitelistActivated?: boolean | null, whitelistedAddresses?: Array | null, changelog?: Array<{ __typename?: 'ColonyMetadataChangelog', transactionHash: string, newDisplayName: string, oldDisplayName: string, hasAvatarChanged: boolean, hasWhitelistChanged: boolean, haveTokensChanged: boolean }> | null } | null } | null }; export type GetColonyMotionQueryVariables = Exact<{ id: Scalars['ID']; @@ -5546,7 +5546,7 @@ export type GetColonyExtensionsQueryVariables = Exact<{ }>; -export type GetColonyExtensionsQuery = { __typename?: 'Query', getColony?: { __typename?: 'Colony', id: string, extensions?: { __typename?: 'ModelColonyExtensionConnection', items: Array<{ __typename?: 'ColonyExtension', hash: string, installedBy: string, installedAt: any, isDeprecated: boolean, isDeleted: boolean, isInitialized: boolean, address: string, colonyAddress: string, currentVersion: number, params?: { __typename?: 'ExtensionParams', votingReputation?: { __typename?: 'VotingReputationParams', maxVoteFraction: string } | null } | null } | null> } | null } | null }; +export type GetColonyExtensionsQuery = { __typename?: 'Query', getColony?: { __typename?: 'Colony', id: string, extensions?: { __typename?: 'ModelColonyExtensionConnection', items: Array<{ __typename?: 'ColonyExtension', hash: string, installedBy: string, installedAt: number, isDeprecated: boolean, isDeleted: boolean, isInitialized: boolean, address: string, colonyAddress: string, currentVersion: number, params?: { __typename?: 'ExtensionParams', votingReputation?: { __typename?: 'VotingReputationParams', maxVoteFraction: string } | null } | null } | null> } | null } | null }; export type GetColonyExtensionQueryVariables = Exact<{ colonyAddress: Scalars['ID']; @@ -5554,7 +5554,7 @@ export type GetColonyExtensionQueryVariables = Exact<{ }>; -export type GetColonyExtensionQuery = { __typename?: 'Query', getExtensionByColonyAndHash?: { __typename?: 'ModelColonyExtensionConnection', items: Array<{ __typename?: 'ColonyExtension', hash: string, installedBy: string, installedAt: any, isDeprecated: boolean, isDeleted: boolean, isInitialized: boolean, address: string, colonyAddress: string, currentVersion: number, params?: { __typename?: 'ExtensionParams', votingReputation?: { __typename?: 'VotingReputationParams', maxVoteFraction: string } | null } | null } | null> } | null }; +export type GetColonyExtensionQuery = { __typename?: 'Query', getExtensionByColonyAndHash?: { __typename?: 'ModelColonyExtensionConnection', items: Array<{ __typename?: 'ColonyExtension', hash: string, installedBy: string, installedAt: number, isDeprecated: boolean, isDeleted: boolean, isInitialized: boolean, address: string, colonyAddress: string, currentVersion: number, params?: { __typename?: 'ExtensionParams', votingReputation?: { __typename?: 'VotingReputationParams', maxVoteFraction: string } | null } | null } | null> } | null }; export type GetMembersForColonyQueryVariables = Exact<{ input: MembersForColonyInput; @@ -5575,7 +5575,7 @@ export type GetExpenditureQueryVariables = Exact<{ }>; -export type GetExpenditureQuery = { __typename?: 'Query', getExpenditure?: { __typename?: 'Expenditure', id: string, nativeId: number, ownerAddress: string, status: ExpenditureStatus, nativeFundingPotId: number, nativeDomainId: number, slots: Array<{ __typename?: 'ExpenditureSlot', id: number, recipientAddress?: string | null, claimDelay?: number | null, payoutModifier?: number | null, payouts?: Array<{ __typename?: 'ExpenditurePayout', tokenAddress: string, amount: string }> | null }>, metadata?: { __typename?: 'ExpenditureMetadata', fundFromDomainNativeId: number } | null, balances?: Array<{ __typename?: 'ExpenditureBalance', tokenAddress: string, amount: string, requiredAmount: string }> | null } | null }; +export type GetExpenditureQuery = { __typename?: 'Query', getExpenditure?: { __typename?: 'Expenditure', id: string, nativeId: number, ownerAddress: string, status: ExpenditureStatus, nativeFundingPotId: number, nativeDomainId: number, finalizedAt?: number | null, slots: Array<{ __typename?: 'ExpenditureSlot', id: number, recipientAddress?: string | null, claimDelay?: number | null, payoutModifier?: number | null, payouts?: Array<{ __typename?: 'ExpenditurePayout', tokenAddress: string, amount: string }> | null }>, metadata?: { __typename?: 'ExpenditureMetadata', fundFromDomainNativeId: number } | null, balances?: Array<{ __typename?: 'ExpenditureBalance', tokenAddress: string, amount: string, requiredAmount: string }> | null } | null }; export type GetMotionStateQueryVariables = Exact<{ input: GetMotionStateInput; @@ -6214,6 +6214,7 @@ export const ExpenditureFragmentDoc = gql` amount requiredAmount } + finalizedAt } ${ExpenditureSlotFragmentDoc}`; export const UserTokenBalanceDataFragmentDoc = gql` From aea17518f5c1bb8b53b0e4e029b9ac1c7bc6c63f Mon Sep 17 00:00:00 2001 From: Jakub Zajac Date: Sun, 20 Aug 2023 22:37:19 +0100 Subject: [PATCH 09/18] Fix: 0 showing in UI if no expenditure slots claimable --- .../ExpenditureClaimButton/ExpenditureClaimButton.tsx | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/components/common/Expenditures/ExpenditureDetailsPage/ExpenditureClaimButton/ExpenditureClaimButton.tsx b/src/components/common/Expenditures/ExpenditureDetailsPage/ExpenditureClaimButton/ExpenditureClaimButton.tsx index dabfdcf3a8d..8142285756b 100644 --- a/src/components/common/Expenditures/ExpenditureDetailsPage/ExpenditureClaimButton/ExpenditureClaimButton.tsx +++ b/src/components/common/Expenditures/ExpenditureDetailsPage/ExpenditureClaimButton/ExpenditureClaimButton.tsx @@ -1,4 +1,5 @@ import React from 'react'; + import { ExpenditureStatus } from '~gql'; import { ActionTypes } from '~redux'; import { ActionButton } from '~shared/Button'; @@ -49,7 +50,7 @@ const ExpenditureClaimButton = ({
Next claim at {new Date(nextClaimableAt).toString()}
)} - {claimableSlots.length && ( + {claimableSlots.length > 0 && ( Date: Sun, 20 Aug 2023 23:15:47 +0100 Subject: [PATCH 10/18] Feat: Claiming expenditure payouts in different tokens --- src/graphql/fragments/expenditures.graphql | 8 ++- src/graphql/generated.ts | 13 +++-- .../sagas/expenditures/claimExpenditure.ts | 51 ++++++++++++------- src/types/graphql.ts | 3 ++ 4 files changed, 52 insertions(+), 23 deletions(-) diff --git a/src/graphql/fragments/expenditures.graphql b/src/graphql/fragments/expenditures.graphql index 56c7a28a6e4..f22256cc5c6 100644 --- a/src/graphql/fragments/expenditures.graphql +++ b/src/graphql/fragments/expenditures.graphql @@ -25,7 +25,11 @@ fragment ExpenditureSlot on ExpenditureSlot { claimDelay payoutModifier payouts { - tokenAddress - amount + ...ExpenditurePayout } } + +fragment ExpenditurePayout on ExpenditurePayout { + tokenAddress + amount +} diff --git a/src/graphql/generated.ts b/src/graphql/generated.ts index 5862d38afb4..71a18d0509b 100644 --- a/src/graphql/generated.ts +++ b/src/graphql/generated.ts @@ -5372,6 +5372,8 @@ export type ExpenditureFragment = { __typename?: 'Expenditure', id: string, nati export type ExpenditureSlotFragment = { __typename?: 'ExpenditureSlot', id: number, recipientAddress?: string | null, claimDelay?: number | null, payoutModifier?: number | null, payouts?: Array<{ __typename?: 'ExpenditurePayout', tokenAddress: string, amount: string }> | null }; +export type ExpenditurePayoutFragment = { __typename?: 'ExpenditurePayout', tokenAddress: string, amount: string }; + export type ExtensionFragment = { __typename?: 'ColonyExtension', hash: string, installedBy: string, installedAt: number, isDeprecated: boolean, isDeleted: boolean, isInitialized: boolean, address: string, colonyAddress: string, currentVersion: number, params?: { __typename?: 'ExtensionParams', votingReputation?: { __typename?: 'VotingReputationParams', maxVoteFraction: string } | null } | null }; export type ExtensionDisplayFragmentFragment = { __typename?: 'ColonyExtension', hash: string, address: string }; @@ -6183,6 +6185,12 @@ export const WatchListItemFragmentDoc = gql` createdAt } ${WatchedColonyFragmentDoc}`; +export const ExpenditurePayoutFragmentDoc = gql` + fragment ExpenditurePayout on ExpenditurePayout { + tokenAddress + amount +} + `; export const ExpenditureSlotFragmentDoc = gql` fragment ExpenditureSlot on ExpenditureSlot { id @@ -6190,11 +6198,10 @@ export const ExpenditureSlotFragmentDoc = gql` claimDelay payoutModifier payouts { - tokenAddress - amount + ...ExpenditurePayout } } - `; + ${ExpenditurePayoutFragmentDoc}`; export const ExpenditureFragmentDoc = gql` fragment Expenditure on Expenditure { id diff --git a/src/redux/sagas/expenditures/claimExpenditure.ts b/src/redux/sagas/expenditures/claimExpenditure.ts index a851fa662d3..4bcc23cadd1 100644 --- a/src/redux/sagas/expenditures/claimExpenditure.ts +++ b/src/redux/sagas/expenditures/claimExpenditure.ts @@ -3,6 +3,7 @@ import { takeEvery, fork, call, put, all } from 'redux-saga/effects'; import { Action, ActionTypes, AllActions } from '~redux'; import { transactionPending, transactionReady } from '~redux/actionCreators'; +import { ExpenditurePayout } from '~types'; import { createTransaction, @@ -11,6 +12,13 @@ import { } from '../transactions'; import { putError, takeFrom } from '../utils'; +type PayoutWithSlotId = ExpenditurePayout & { + slotId: number; +}; + +const getPayoutChannelId = (payout: PayoutWithSlotId) => + `${payout.slotId}-${payout.tokenAddress}`; + function* claimExpenditure({ meta, payload: { colonyAddress, expenditure }, @@ -18,28 +26,32 @@ function* claimExpenditure({ const txChannel = yield call(getTxChannel, meta.id); const batchKey = 'claimExpenditure'; + const payoutsWithSlotIds = expenditure.slots.flatMap( + (slot) => + slot.payouts?.map((payout) => ({ + ...payout, + slotId: slot.id, + })) ?? [], + ); + try { const channels = yield createTransactionChannels(meta.id, [ - ...expenditure.slots.map((slot) => slot.id.toString()), + ...payoutsWithSlotIds.map(getPayoutChannelId), ]); // Create one claim transaction for each slot // @TODO: We should create one transaction for each token address yield all( - expenditure.slots.map((slot) => - fork(createTransaction, channels[slot.id].id, { + payoutsWithSlotIds.map((payout, index) => + fork(createTransaction, channels[getPayoutChannelId(payout)].id, { context: ClientType.ColonyClient, methodName: 'claimExpenditurePayout', identifier: colonyAddress, - params: [ - expenditure.nativeId, - slot.id, - slot.payouts?.[0].tokenAddress ?? '', - ], + params: [expenditure.nativeId, payout.slotId, payout.tokenAddress], group: { key: batchKey, id: meta.id, - index: 0, + index, }, ready: false, }), @@ -47,15 +59,18 @@ function* claimExpenditure({ ); yield all( - expenditure.slots - .map((slot) => [ - put(transactionPending(channels[slot.id].id)), - put(transactionReady(channels[slot.id].id)), - takeFrom( - channels[slot.id].channel, - ActionTypes.TRANSACTION_SUCCEEDED, - ), - ]) + payoutsWithSlotIds + .map((payout) => { + const payoutChannelId = getPayoutChannelId(payout); + return [ + put(transactionPending(channels[payoutChannelId].id)), + put(transactionReady(channels[payoutChannelId].id)), + takeFrom( + channels[payoutChannelId].channel, + ActionTypes.TRANSACTION_SUCCEEDED, + ), + ]; + }) .flat(), ); diff --git a/src/types/graphql.ts b/src/types/graphql.ts index fa45cf19dc3..e39e6bfd4bd 100644 --- a/src/types/graphql.ts +++ b/src/types/graphql.ts @@ -28,6 +28,7 @@ import { UnclaimedStakesFragment, ExpenditureFragment, ExpenditureSlotFragment, + ExpenditurePayoutFragment, } from '~gql'; export type User = UserFragment; @@ -109,3 +110,5 @@ export type UnclaimedStakes = UnclaimedStakesFragment; export type Expenditure = ExpenditureFragment; export type ExpenditureSlot = ExpenditureSlotFragment; + +export type ExpenditurePayout = ExpenditurePayoutFragment; From b98e42de9624379e105ac7e2b9c7d08659f1b0ce Mon Sep 17 00:00:00 2001 From: Jakub Zajac Date: Mon, 21 Aug 2023 18:22:08 +0100 Subject: [PATCH 11/18] Upgrade colony network and colony-js --- .../fetchExpenditureBalances/src/package-lock.json | 14 +++++++------- .../fetchExpenditureBalances/src/package.json | 2 +- docker/colony-cdapp-dev-env-network | 2 +- docker/files/network/run.sh.base | 2 +- package-lock.json | 14 +++++++------- package.json | 2 +- 6 files changed, 18 insertions(+), 18 deletions(-) diff --git a/amplify/backend/function/fetchExpenditureBalances/src/package-lock.json b/amplify/backend/function/fetchExpenditureBalances/src/package-lock.json index da4f2865d1c..a6c2032a57e 100644 --- a/amplify/backend/function/fetchExpenditureBalances/src/package-lock.json +++ b/amplify/backend/function/fetchExpenditureBalances/src/package-lock.json @@ -9,7 +9,7 @@ "version": "2.0.0", "license": "Apache-2.0", "dependencies": { - "@colony/colony-js": "^6.4.0", + "@colony/colony-js": "^6.5.0-next.0", "ethers": "^5.7.2" }, "devDependencies": { @@ -17,9 +17,9 @@ } }, "node_modules/@colony/colony-js": { - "version": "6.4.0", - "resolved": "https://registry.npmjs.org/@colony/colony-js/-/colony-js-6.4.0.tgz", - "integrity": "sha512-QVHPITi0Uv8cBfzRMUueQBl2pzuHwoYTjxSutTxgqx3wFfzgDJkBiKvS0iC2BEjXKeHRvUqsI4Lnk0EXu9NlCg==", + "version": "6.5.0-next.0", + "resolved": "https://registry.npmjs.org/@colony/colony-js/-/colony-js-6.5.0-next.0.tgz", + "integrity": "sha512-Tr0j5PTA99ZocFxDNNRGfUglgsOR/xfH7GLEEVVDhQTkv3eMlPHwgE5jF+RrcEPgebpIUPvLK84CTFzy/OJc/Q==", "dependencies": { "cross-fetch": "^3.1.5" }, @@ -907,9 +907,9 @@ }, "dependencies": { "@colony/colony-js": { - "version": "6.4.0", - "resolved": "https://registry.npmjs.org/@colony/colony-js/-/colony-js-6.4.0.tgz", - "integrity": "sha512-QVHPITi0Uv8cBfzRMUueQBl2pzuHwoYTjxSutTxgqx3wFfzgDJkBiKvS0iC2BEjXKeHRvUqsI4Lnk0EXu9NlCg==", + "version": "6.5.0-next.0", + "resolved": "https://registry.npmjs.org/@colony/colony-js/-/colony-js-6.5.0-next.0.tgz", + "integrity": "sha512-Tr0j5PTA99ZocFxDNNRGfUglgsOR/xfH7GLEEVVDhQTkv3eMlPHwgE5jF+RrcEPgebpIUPvLK84CTFzy/OJc/Q==", "requires": { "cross-fetch": "^3.1.5" } diff --git a/amplify/backend/function/fetchExpenditureBalances/src/package.json b/amplify/backend/function/fetchExpenditureBalances/src/package.json index 5c2ac673be6..9731f37046d 100644 --- a/amplify/backend/function/fetchExpenditureBalances/src/package.json +++ b/amplify/backend/function/fetchExpenditureBalances/src/package.json @@ -8,7 +8,7 @@ "@types/aws-lambda": "^8.10.92" }, "dependencies": { - "@colony/colony-js": "^6.4.0", + "@colony/colony-js": "^6.5.0-next.0", "ethers": "^5.7.2" } } diff --git a/docker/colony-cdapp-dev-env-network b/docker/colony-cdapp-dev-env-network index b679087beb1..476ee3d37f2 100644 --- a/docker/colony-cdapp-dev-env-network +++ b/docker/colony-cdapp-dev-env-network @@ -1,6 +1,6 @@ FROM colony-cdapp-dev-env/base:latest -ENV NETWORK_HASH=0b78037610a96c0f27b1d78122b467a6c413afae +ENV NETWORK_HASH=094e338910fb31c1f058f76e1a14176b15ef99dd # Declare volumes to set up metadata VOLUME [ "/colonyCDapp/amplify/mock-data" ] diff --git a/docker/files/network/run.sh.base b/docker/files/network/run.sh.base index 16bc664f39c..4c4289e7349 100644 --- a/docker/files/network/run.sh.base +++ b/docker/files/network/run.sh.base @@ -6,7 +6,7 @@ cd colonyNetwork # Uncomment the line below if you need ganache to run in verbose mode # sed -i 's/100000000000000000000" >\/dev\/null 2>&1/100000000000000000000" --verbose/g' scripts/start-blockchain-client.sh -sed -i 's/--db .\/ganache-chain-db\//--db .\/ganache-chain-db\/ --server.host "0.0.0.0" --server.port "8545"/g' scripts/start-blockchain-client.sh +sed -i 's/--db $DBPATH/--db $DBPATH --server.host "0.0.0.0"/g' scripts/start-blockchain-client.sh yarn start:blockchain:client & # Colony Network Contracts diff --git a/package-lock.json b/package-lock.json index 36b641a9e6d..7c026a26f36 100644 --- a/package-lock.json +++ b/package-lock.json @@ -10,7 +10,7 @@ "hasInstallScript": true, "dependencies": { "@apollo/client": "^3.6.9", - "@colony/colony-js": "^6.4.0", + "@colony/colony-js": "^6.5.0-next.0", "@colony/redux-promise-listener": "^1.2.0", "@colony/unicode-confusables-noascii": "^0.1.2", "@formatjs/intl-pluralrules": "^5.0.2", @@ -2525,9 +2525,9 @@ } }, "node_modules/@colony/colony-js": { - "version": "6.4.0", - "resolved": "https://registry.npmjs.org/@colony/colony-js/-/colony-js-6.4.0.tgz", - "integrity": "sha512-QVHPITi0Uv8cBfzRMUueQBl2pzuHwoYTjxSutTxgqx3wFfzgDJkBiKvS0iC2BEjXKeHRvUqsI4Lnk0EXu9NlCg==", + "version": "6.5.0-next.0", + "resolved": "https://registry.npmjs.org/@colony/colony-js/-/colony-js-6.5.0-next.0.tgz", + "integrity": "sha512-Tr0j5PTA99ZocFxDNNRGfUglgsOR/xfH7GLEEVVDhQTkv3eMlPHwgE5jF+RrcEPgebpIUPvLK84CTFzy/OJc/Q==", "dependencies": { "cross-fetch": "^3.1.5" }, @@ -62727,9 +62727,9 @@ } }, "@colony/colony-js": { - "version": "6.4.0", - "resolved": "https://registry.npmjs.org/@colony/colony-js/-/colony-js-6.4.0.tgz", - "integrity": "sha512-QVHPITi0Uv8cBfzRMUueQBl2pzuHwoYTjxSutTxgqx3wFfzgDJkBiKvS0iC2BEjXKeHRvUqsI4Lnk0EXu9NlCg==", + "version": "6.5.0-next.0", + "resolved": "https://registry.npmjs.org/@colony/colony-js/-/colony-js-6.5.0-next.0.tgz", + "integrity": "sha512-Tr0j5PTA99ZocFxDNNRGfUglgsOR/xfH7GLEEVVDhQTkv3eMlPHwgE5jF+RrcEPgebpIUPvLK84CTFzy/OJc/Q==", "requires": { "cross-fetch": "^3.1.5" } diff --git a/package.json b/package.json index 0d57ae9ed69..bf8bfb3e46d 100644 --- a/package.json +++ b/package.json @@ -132,7 +132,7 @@ }, "dependencies": { "@apollo/client": "^3.6.9", - "@colony/colony-js": "^6.4.0", + "@colony/colony-js": "^6.5.0-next.0", "@colony/redux-promise-listener": "^1.2.0", "@colony/unicode-confusables-noascii": "^0.1.2", "@formatjs/intl-pluralrules": "^5.0.2", From d0ab4b2797412c5a4014f6a1e8c3afdc7edcfd47 Mon Sep 17 00:00:00 2001 From: Jakub Zajac Date: Mon, 21 Aug 2023 18:45:03 +0100 Subject: [PATCH 12/18] Only claim payouts with non-zero amounts --- src/redux/sagas/expenditures/claimExpenditure.ts | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/src/redux/sagas/expenditures/claimExpenditure.ts b/src/redux/sagas/expenditures/claimExpenditure.ts index 4bcc23cadd1..b003d2a85bb 100644 --- a/src/redux/sagas/expenditures/claimExpenditure.ts +++ b/src/redux/sagas/expenditures/claimExpenditure.ts @@ -28,10 +28,12 @@ function* claimExpenditure({ const payoutsWithSlotIds = expenditure.slots.flatMap( (slot) => - slot.payouts?.map((payout) => ({ - ...payout, - slotId: slot.id, - })) ?? [], + slot.payouts + ?.filter((payout) => payout.amount !== '0') + .map((payout) => ({ + ...payout, + slotId: slot.id, + })) ?? [], ); try { From 4df188caeb79973a964d8d7c44647ee5b49a8c75 Mon Sep 17 00:00:00 2001 From: Jakub Zajac Date: Mon, 21 Aug 2023 18:45:26 +0100 Subject: [PATCH 13/18] Only move funds for non-zero expenditure balances --- src/redux/sagas/expenditures/fundExpenditure.ts | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/redux/sagas/expenditures/fundExpenditure.ts b/src/redux/sagas/expenditures/fundExpenditure.ts index 9fa9fe6d74f..d2d71336013 100644 --- a/src/redux/sagas/expenditures/fundExpenditure.ts +++ b/src/redux/sagas/expenditures/fundExpenditure.ts @@ -29,8 +29,13 @@ function* fundExpenditure({ const balancesByTokenAddresses = new Map(); expenditure.slots.forEach((slot) => { slot.payouts?.forEach((payout) => { + if (payout.amount === '0') { + return; + } + const currentBalance = balancesByTokenAddresses.get(payout.tokenAddress) ?? '0'; + balancesByTokenAddresses.set( payout.tokenAddress, BigNumber.from(payout.amount).add(currentBalance), From 21dc18c58bd19e60c60060e06aafb212af76fb6f Mon Sep 17 00:00:00 2001 From: Jakub Zajac Date: Mon, 21 Aug 2023 19:04:42 +0100 Subject: [PATCH 14/18] Bump ingestor image hash --- docker/colony-cdapp-dev-env-block-ingestor | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docker/colony-cdapp-dev-env-block-ingestor b/docker/colony-cdapp-dev-env-block-ingestor index 8c578cbbea7..7d56deca488 100644 --- a/docker/colony-cdapp-dev-env-block-ingestor +++ b/docker/colony-cdapp-dev-env-block-ingestor @@ -1,6 +1,6 @@ FROM colony-cdapp-dev-env/base:latest -ENV BLOCK_INGESTOR_HASH=f4a8b4ea57d777a11d0575f10a97b033bf47738b +ENV BLOCK_INGESTOR_HASH=cb6d7ec631360fe9106b11ff4f3cc3dc8e3044f9 # Declare volumes to set up metadata VOLUME [ "/colonyCDapp/amplify/mock-data" ] From 6af4906c1198a99f6e1f609e842f2c7d115bfae1 Mon Sep 17 00:00:00 2001 From: Jakub Zajac Date: Tue, 22 Aug 2023 18:28:37 +0100 Subject: [PATCH 15/18] Add `upgrade-colony-js` script --- package.json | 3 ++- scripts/upgrade-colony-js.sh | 35 +++++++++++++++++++++++++++++++++++ 2 files changed, 37 insertions(+), 1 deletion(-) create mode 100755 scripts/upgrade-colony-js.sh diff --git a/package.json b/package.json index bf8bfb3e46d..cfa68438f1d 100644 --- a/package.json +++ b/package.json @@ -23,7 +23,8 @@ "DEPRECATED:webpack:prod": "NODE_OPTIONS=\"--max-old-space-size=4096\" NODE_ENV=production webpack-cli --config webpack.prod.js", "voyager": "ts-node temp-voyager/voyager", "codegen": "node codegen", - "postinstall": "./scripts/lambda-functions-dependencies.sh" + "postinstall": "./scripts/lambda-functions-dependencies.sh", + "upgrade-colony-js": "./scripts/upgrade-colony-js.sh" }, "repository": { "type": "git", diff --git a/scripts/upgrade-colony-js.sh b/scripts/upgrade-colony-js.sh new file mode 100755 index 00000000000..90573c82fb1 --- /dev/null +++ b/scripts/upgrade-colony-js.sh @@ -0,0 +1,35 @@ +#!/usr/bin/env bash + +# This scripts accepts a target version as an argument and upgrades colony-js version +# in CDapp and all the lambda functions that use it + +# Check if a version argument was provided +if [ "$#" -ne 1 ]; then + echo "Usage: $0 " + exit 1 +fi + +version=$1 +pwd=$(pwd) +directory="amplify/backend/function" + +npm install "@colony/colony-js@$version" + +if [ -d "$directory" ]; then + for d in amplify/backend/function/*/ ; do + [ -L "${d%/}" ] && continue + fnName=$(echo "${d}" | cut -c 26- | rev | cut -c 2- | rev) + # Check if src directory exists + if [ -d "${pwd}/${d}src" ]; then + cd "${pwd}/${d}src" || exit + # Skip if the folder doesn't contain package.json + ! [ -f "package.json" ] && continue + # Check if @colony/colony-js is in package.json's dependencies + if grep -q "@colony/colony-js" "package.json"; then + echo "Upgrading @colony/colony-js to version $version for Lambda Function \"${fnName}\"" + npm install "@colony/colony-js@$version" + echo + fi + fi + done +fi \ No newline at end of file From 598f259baae38e29d6acfed5830fd24cd5ae5571 Mon Sep 17 00:00:00 2001 From: Jakub Zajac Date: Tue, 22 Aug 2023 18:38:18 +0100 Subject: [PATCH 16/18] Upgrade colony-js in lambdas --- .../fetchMotionState/src/package-lock.json | 14 +++++++------- .../function/fetchMotionState/src/package.json | 3 +-- .../src/package-lock.json | 14 +++++++------- .../fetchMotionTimeoutPeriods/src/package.json | 2 +- .../fetchVoterRewards/src/package-lock.json | 14 +++++++------- .../function/fetchVoterRewards/src/package.json | 2 +- .../getMembersForColony/src/package-lock.json | 14 +++++++------- .../function/getMembersForColony/src/package.json | 2 +- .../src/package-lock.json | 14 +++++++------- .../getReputationForTopDomains/src/package.json | 6 +++--- .../getUserReputation/src/package-lock.json | 14 +++++++------- .../function/getUserReputation/src/package.json | 2 +- .../getUserTokenBalance/src/package-lock.json | 14 +++++++------- .../function/getUserTokenBalance/src/package.json | 3 +-- .../function/qaSSMtest/src/package-lock.json | 14 +++++++------- .../backend/function/qaSSMtest/src/package.json | 7 +++---- 16 files changed, 68 insertions(+), 71 deletions(-) diff --git a/amplify/backend/function/fetchMotionState/src/package-lock.json b/amplify/backend/function/fetchMotionState/src/package-lock.json index efcc4937527..3efaf678a42 100644 --- a/amplify/backend/function/fetchMotionState/src/package-lock.json +++ b/amplify/backend/function/fetchMotionState/src/package-lock.json @@ -9,7 +9,7 @@ "version": "2.0.0", "license": "Apache-2.0", "dependencies": { - "@colony/colony-js": "^6.3.5", + "@colony/colony-js": "^6.5.0-next.0", "ethers": "^5.1.3", "node-fetch": "2.6.7" }, @@ -18,9 +18,9 @@ } }, "node_modules/@colony/colony-js": { - "version": "6.3.5", - "resolved": "https://registry.npmjs.org/@colony/colony-js/-/colony-js-6.3.5.tgz", - "integrity": "sha512-dJ8e/oshAfUNRkDiZL7Dzpasp0vEunQjZhguOqR7YCrJVJ4wLJs5lFf8EBMtUcwp5UEy977s3aUHvhDDqYQDMQ==", + "version": "6.5.0-next.0", + "resolved": "https://registry.npmjs.org/@colony/colony-js/-/colony-js-6.5.0-next.0.tgz", + "integrity": "sha512-Tr0j5PTA99ZocFxDNNRGfUglgsOR/xfH7GLEEVVDhQTkv3eMlPHwgE5jF+RrcEPgebpIUPvLK84CTFzy/OJc/Q==", "dependencies": { "cross-fetch": "^3.1.5" }, @@ -899,9 +899,9 @@ }, "dependencies": { "@colony/colony-js": { - "version": "6.3.5", - "resolved": "https://registry.npmjs.org/@colony/colony-js/-/colony-js-6.3.5.tgz", - "integrity": "sha512-dJ8e/oshAfUNRkDiZL7Dzpasp0vEunQjZhguOqR7YCrJVJ4wLJs5lFf8EBMtUcwp5UEy977s3aUHvhDDqYQDMQ==", + "version": "6.5.0-next.0", + "resolved": "https://registry.npmjs.org/@colony/colony-js/-/colony-js-6.5.0-next.0.tgz", + "integrity": "sha512-Tr0j5PTA99ZocFxDNNRGfUglgsOR/xfH7GLEEVVDhQTkv3eMlPHwgE5jF+RrcEPgebpIUPvLK84CTFzy/OJc/Q==", "requires": { "cross-fetch": "^3.1.5" } diff --git a/amplify/backend/function/fetchMotionState/src/package.json b/amplify/backend/function/fetchMotionState/src/package.json index b6ef56a6643..05c18194d7b 100644 --- a/amplify/backend/function/fetchMotionState/src/package.json +++ b/amplify/backend/function/fetchMotionState/src/package.json @@ -8,9 +8,8 @@ "@types/aws-lambda": "^8.10.92" }, "dependencies": { - "@colony/colony-js": "^6.3.5", + "@colony/colony-js": "^6.5.0-next.0", "ethers": "^5.1.3", "node-fetch": "2.6.7" - } } diff --git a/amplify/backend/function/fetchMotionTimeoutPeriods/src/package-lock.json b/amplify/backend/function/fetchMotionTimeoutPeriods/src/package-lock.json index 6579ec7668f..343834d1244 100644 --- a/amplify/backend/function/fetchMotionTimeoutPeriods/src/package-lock.json +++ b/amplify/backend/function/fetchMotionTimeoutPeriods/src/package-lock.json @@ -9,7 +9,7 @@ "version": "2.0.0", "license": "Apache-2.0", "dependencies": { - "@colony/colony-js": "^6.3.6", + "@colony/colony-js": "^6.5.0-next.0", "ethers": "^5.7.2" }, "devDependencies": { @@ -17,9 +17,9 @@ } }, "node_modules/@colony/colony-js": { - "version": "6.3.6", - "resolved": "https://registry.npmjs.org/@colony/colony-js/-/colony-js-6.3.6.tgz", - "integrity": "sha512-vfmby0kKiwKjmBt1O/YD5iv8SGVebHg5DucTYYleW6gc7I5VtMonlgFCwGEwWtgPZWEgvJskDUcya/bZYrTBTg==", + "version": "6.5.0-next.0", + "resolved": "https://registry.npmjs.org/@colony/colony-js/-/colony-js-6.5.0-next.0.tgz", + "integrity": "sha512-Tr0j5PTA99ZocFxDNNRGfUglgsOR/xfH7GLEEVVDhQTkv3eMlPHwgE5jF+RrcEPgebpIUPvLK84CTFzy/OJc/Q==", "dependencies": { "cross-fetch": "^3.1.5" }, @@ -907,9 +907,9 @@ }, "dependencies": { "@colony/colony-js": { - "version": "6.3.6", - "resolved": "https://registry.npmjs.org/@colony/colony-js/-/colony-js-6.3.6.tgz", - "integrity": "sha512-vfmby0kKiwKjmBt1O/YD5iv8SGVebHg5DucTYYleW6gc7I5VtMonlgFCwGEwWtgPZWEgvJskDUcya/bZYrTBTg==", + "version": "6.5.0-next.0", + "resolved": "https://registry.npmjs.org/@colony/colony-js/-/colony-js-6.5.0-next.0.tgz", + "integrity": "sha512-Tr0j5PTA99ZocFxDNNRGfUglgsOR/xfH7GLEEVVDhQTkv3eMlPHwgE5jF+RrcEPgebpIUPvLK84CTFzy/OJc/Q==", "requires": { "cross-fetch": "^3.1.5" } diff --git a/amplify/backend/function/fetchMotionTimeoutPeriods/src/package.json b/amplify/backend/function/fetchMotionTimeoutPeriods/src/package.json index 7977a789fec..accf6599dce 100644 --- a/amplify/backend/function/fetchMotionTimeoutPeriods/src/package.json +++ b/amplify/backend/function/fetchMotionTimeoutPeriods/src/package.json @@ -8,7 +8,7 @@ "@types/aws-lambda": "^8.10.92" }, "dependencies": { - "@colony/colony-js": "^6.3.6", + "@colony/colony-js": "^6.5.0-next.0", "ethers": "^5.7.2" } } diff --git a/amplify/backend/function/fetchVoterRewards/src/package-lock.json b/amplify/backend/function/fetchVoterRewards/src/package-lock.json index 44b5c8ece9d..f3ff8fdd502 100644 --- a/amplify/backend/function/fetchVoterRewards/src/package-lock.json +++ b/amplify/backend/function/fetchVoterRewards/src/package-lock.json @@ -9,7 +9,7 @@ "version": "2.0.0", "license": "Apache-2.0", "dependencies": { - "@colony/colony-js": "^6.3.5", + "@colony/colony-js": "^6.5.0-next.0", "ethers": "^5.1.3", "node-fetch": "2.6.7" }, @@ -18,9 +18,9 @@ } }, "node_modules/@colony/colony-js": { - "version": "6.3.6", - "resolved": "https://registry.npmjs.org/@colony/colony-js/-/colony-js-6.3.6.tgz", - "integrity": "sha512-vfmby0kKiwKjmBt1O/YD5iv8SGVebHg5DucTYYleW6gc7I5VtMonlgFCwGEwWtgPZWEgvJskDUcya/bZYrTBTg==", + "version": "6.5.0-next.0", + "resolved": "https://registry.npmjs.org/@colony/colony-js/-/colony-js-6.5.0-next.0.tgz", + "integrity": "sha512-Tr0j5PTA99ZocFxDNNRGfUglgsOR/xfH7GLEEVVDhQTkv3eMlPHwgE5jF+RrcEPgebpIUPvLK84CTFzy/OJc/Q==", "dependencies": { "cross-fetch": "^3.1.5" }, @@ -908,9 +908,9 @@ }, "dependencies": { "@colony/colony-js": { - "version": "6.3.6", - "resolved": "https://registry.npmjs.org/@colony/colony-js/-/colony-js-6.3.6.tgz", - "integrity": "sha512-vfmby0kKiwKjmBt1O/YD5iv8SGVebHg5DucTYYleW6gc7I5VtMonlgFCwGEwWtgPZWEgvJskDUcya/bZYrTBTg==", + "version": "6.5.0-next.0", + "resolved": "https://registry.npmjs.org/@colony/colony-js/-/colony-js-6.5.0-next.0.tgz", + "integrity": "sha512-Tr0j5PTA99ZocFxDNNRGfUglgsOR/xfH7GLEEVVDhQTkv3eMlPHwgE5jF+RrcEPgebpIUPvLK84CTFzy/OJc/Q==", "requires": { "cross-fetch": "^3.1.5" } diff --git a/amplify/backend/function/fetchVoterRewards/src/package.json b/amplify/backend/function/fetchVoterRewards/src/package.json index cd6064261e6..1f6accceaf2 100644 --- a/amplify/backend/function/fetchVoterRewards/src/package.json +++ b/amplify/backend/function/fetchVoterRewards/src/package.json @@ -8,7 +8,7 @@ "@types/aws-lambda": "^8.10.92" }, "dependencies": { - "@colony/colony-js": "^6.3.5", + "@colony/colony-js": "^6.5.0-next.0", "ethers": "^5.1.3", "node-fetch": "2.6.7" } diff --git a/amplify/backend/function/getMembersForColony/src/package-lock.json b/amplify/backend/function/getMembersForColony/src/package-lock.json index 7833b19b44f..a480ea9e258 100644 --- a/amplify/backend/function/getMembersForColony/src/package-lock.json +++ b/amplify/backend/function/getMembersForColony/src/package-lock.json @@ -9,7 +9,7 @@ "version": "2.0.0", "license": "Apache-2.0", "dependencies": { - "@colony/colony-js": "^6.3.6", + "@colony/colony-js": "^6.5.0-next.0", "decimal.js": "^10.2.1", "ethers": "^5.7.1", "node-fetch": "2.6.7" @@ -19,9 +19,9 @@ } }, "node_modules/@colony/colony-js": { - "version": "6.3.6", - "resolved": "https://registry.npmjs.org/@colony/colony-js/-/colony-js-6.3.6.tgz", - "integrity": "sha512-vfmby0kKiwKjmBt1O/YD5iv8SGVebHg5DucTYYleW6gc7I5VtMonlgFCwGEwWtgPZWEgvJskDUcya/bZYrTBTg==", + "version": "6.5.0-next.0", + "resolved": "https://registry.npmjs.org/@colony/colony-js/-/colony-js-6.5.0-next.0.tgz", + "integrity": "sha512-Tr0j5PTA99ZocFxDNNRGfUglgsOR/xfH7GLEEVVDhQTkv3eMlPHwgE5jF+RrcEPgebpIUPvLK84CTFzy/OJc/Q==", "dependencies": { "cross-fetch": "^3.1.5" }, @@ -914,9 +914,9 @@ }, "dependencies": { "@colony/colony-js": { - "version": "6.3.6", - "resolved": "https://registry.npmjs.org/@colony/colony-js/-/colony-js-6.3.6.tgz", - "integrity": "sha512-vfmby0kKiwKjmBt1O/YD5iv8SGVebHg5DucTYYleW6gc7I5VtMonlgFCwGEwWtgPZWEgvJskDUcya/bZYrTBTg==", + "version": "6.5.0-next.0", + "resolved": "https://registry.npmjs.org/@colony/colony-js/-/colony-js-6.5.0-next.0.tgz", + "integrity": "sha512-Tr0j5PTA99ZocFxDNNRGfUglgsOR/xfH7GLEEVVDhQTkv3eMlPHwgE5jF+RrcEPgebpIUPvLK84CTFzy/OJc/Q==", "requires": { "cross-fetch": "^3.1.5" } diff --git a/amplify/backend/function/getMembersForColony/src/package.json b/amplify/backend/function/getMembersForColony/src/package.json index a7e00143163..38a0e382ba6 100644 --- a/amplify/backend/function/getMembersForColony/src/package.json +++ b/amplify/backend/function/getMembersForColony/src/package.json @@ -8,7 +8,7 @@ "@types/aws-lambda": "^8.10.92" }, "dependencies": { - "@colony/colony-js": "^6.3.6", + "@colony/colony-js": "^6.5.0-next.0", "decimal.js": "^10.2.1", "ethers": "^5.7.1", "node-fetch": "2.6.7" diff --git a/amplify/backend/function/getReputationForTopDomains/src/package-lock.json b/amplify/backend/function/getReputationForTopDomains/src/package-lock.json index 6758066a3f1..d0bba2347e8 100644 --- a/amplify/backend/function/getReputationForTopDomains/src/package-lock.json +++ b/amplify/backend/function/getReputationForTopDomains/src/package-lock.json @@ -9,7 +9,7 @@ "version": "2.0.0", "license": "Apache-2.0", "dependencies": { - "@colony/colony-js": "^6.3.6", + "@colony/colony-js": "^6.5.0-next.0", "decimal.js": "^10.2.1", "ethers": "^5.7.2" }, @@ -18,9 +18,9 @@ } }, "node_modules/@colony/colony-js": { - "version": "6.3.6", - "resolved": "https://registry.npmjs.org/@colony/colony-js/-/colony-js-6.3.6.tgz", - "integrity": "sha512-vfmby0kKiwKjmBt1O/YD5iv8SGVebHg5DucTYYleW6gc7I5VtMonlgFCwGEwWtgPZWEgvJskDUcya/bZYrTBTg==", + "version": "6.5.0-next.0", + "resolved": "https://registry.npmjs.org/@colony/colony-js/-/colony-js-6.5.0-next.0.tgz", + "integrity": "sha512-Tr0j5PTA99ZocFxDNNRGfUglgsOR/xfH7GLEEVVDhQTkv3eMlPHwgE5jF+RrcEPgebpIUPvLK84CTFzy/OJc/Q==", "dependencies": { "cross-fetch": "^3.1.5" }, @@ -913,9 +913,9 @@ }, "dependencies": { "@colony/colony-js": { - "version": "6.3.6", - "resolved": "https://registry.npmjs.org/@colony/colony-js/-/colony-js-6.3.6.tgz", - "integrity": "sha512-vfmby0kKiwKjmBt1O/YD5iv8SGVebHg5DucTYYleW6gc7I5VtMonlgFCwGEwWtgPZWEgvJskDUcya/bZYrTBTg==", + "version": "6.5.0-next.0", + "resolved": "https://registry.npmjs.org/@colony/colony-js/-/colony-js-6.5.0-next.0.tgz", + "integrity": "sha512-Tr0j5PTA99ZocFxDNNRGfUglgsOR/xfH7GLEEVVDhQTkv3eMlPHwgE5jF+RrcEPgebpIUPvLK84CTFzy/OJc/Q==", "requires": { "cross-fetch": "^3.1.5" } diff --git a/amplify/backend/function/getReputationForTopDomains/src/package.json b/amplify/backend/function/getReputationForTopDomains/src/package.json index 638f38227e8..c6069ecc5aa 100644 --- a/amplify/backend/function/getReputationForTopDomains/src/package.json +++ b/amplify/backend/function/getReputationForTopDomains/src/package.json @@ -8,8 +8,8 @@ "@types/aws-lambda": "^8.10.92" }, "dependencies": { - "@colony/colony-js": "^6.3.6", - "ethers": "^5.7.2", - "decimal.js": "^10.2.1" + "@colony/colony-js": "^6.5.0-next.0", + "decimal.js": "^10.2.1", + "ethers": "^5.7.2" } } diff --git a/amplify/backend/function/getUserReputation/src/package-lock.json b/amplify/backend/function/getUserReputation/src/package-lock.json index 0bf087659b6..127dbb8d9c0 100644 --- a/amplify/backend/function/getUserReputation/src/package-lock.json +++ b/amplify/backend/function/getUserReputation/src/package-lock.json @@ -9,7 +9,7 @@ "version": "2.0.0", "license": "Apache-2.0", "dependencies": { - "@colony/colony-js": "^6.3.6", + "@colony/colony-js": "^6.5.0-next.0", "ethers": "^5.7.2" }, "devDependencies": { @@ -17,9 +17,9 @@ } }, "node_modules/@colony/colony-js": { - "version": "6.3.6", - "resolved": "https://registry.npmjs.org/@colony/colony-js/-/colony-js-6.3.6.tgz", - "integrity": "sha512-vfmby0kKiwKjmBt1O/YD5iv8SGVebHg5DucTYYleW6gc7I5VtMonlgFCwGEwWtgPZWEgvJskDUcya/bZYrTBTg==", + "version": "6.5.0-next.0", + "resolved": "https://registry.npmjs.org/@colony/colony-js/-/colony-js-6.5.0-next.0.tgz", + "integrity": "sha512-Tr0j5PTA99ZocFxDNNRGfUglgsOR/xfH7GLEEVVDhQTkv3eMlPHwgE5jF+RrcEPgebpIUPvLK84CTFzy/OJc/Q==", "dependencies": { "cross-fetch": "^3.1.5" }, @@ -907,9 +907,9 @@ }, "dependencies": { "@colony/colony-js": { - "version": "6.3.6", - "resolved": "https://registry.npmjs.org/@colony/colony-js/-/colony-js-6.3.6.tgz", - "integrity": "sha512-vfmby0kKiwKjmBt1O/YD5iv8SGVebHg5DucTYYleW6gc7I5VtMonlgFCwGEwWtgPZWEgvJskDUcya/bZYrTBTg==", + "version": "6.5.0-next.0", + "resolved": "https://registry.npmjs.org/@colony/colony-js/-/colony-js-6.5.0-next.0.tgz", + "integrity": "sha512-Tr0j5PTA99ZocFxDNNRGfUglgsOR/xfH7GLEEVVDhQTkv3eMlPHwgE5jF+RrcEPgebpIUPvLK84CTFzy/OJc/Q==", "requires": { "cross-fetch": "^3.1.5" } diff --git a/amplify/backend/function/getUserReputation/src/package.json b/amplify/backend/function/getUserReputation/src/package.json index ce270761ae7..6e214b7e240 100644 --- a/amplify/backend/function/getUserReputation/src/package.json +++ b/amplify/backend/function/getUserReputation/src/package.json @@ -8,7 +8,7 @@ "@types/aws-lambda": "^8.10.92" }, "dependencies": { - "@colony/colony-js": "^6.3.6", + "@colony/colony-js": "^6.5.0-next.0", "ethers": "^5.7.2" } } diff --git a/amplify/backend/function/getUserTokenBalance/src/package-lock.json b/amplify/backend/function/getUserTokenBalance/src/package-lock.json index 25abb3720da..453e01c02d0 100644 --- a/amplify/backend/function/getUserTokenBalance/src/package-lock.json +++ b/amplify/backend/function/getUserTokenBalance/src/package-lock.json @@ -9,7 +9,7 @@ "version": "2.0.0", "license": "Apache-2.0", "dependencies": { - "@colony/colony-js": "^6.3.6", + "@colony/colony-js": "^6.5.0-next.0", "ethers": "^5.7.2", "node-fetch": "2.6.7" }, @@ -18,9 +18,9 @@ } }, "node_modules/@colony/colony-js": { - "version": "6.3.6", - "resolved": "https://registry.npmjs.org/@colony/colony-js/-/colony-js-6.3.6.tgz", - "integrity": "sha512-vfmby0kKiwKjmBt1O/YD5iv8SGVebHg5DucTYYleW6gc7I5VtMonlgFCwGEwWtgPZWEgvJskDUcya/bZYrTBTg==", + "version": "6.5.0-next.0", + "resolved": "https://registry.npmjs.org/@colony/colony-js/-/colony-js-6.5.0-next.0.tgz", + "integrity": "sha512-Tr0j5PTA99ZocFxDNNRGfUglgsOR/xfH7GLEEVVDhQTkv3eMlPHwgE5jF+RrcEPgebpIUPvLK84CTFzy/OJc/Q==", "dependencies": { "cross-fetch": "^3.1.5" }, @@ -908,9 +908,9 @@ }, "dependencies": { "@colony/colony-js": { - "version": "6.3.6", - "resolved": "https://registry.npmjs.org/@colony/colony-js/-/colony-js-6.3.6.tgz", - "integrity": "sha512-vfmby0kKiwKjmBt1O/YD5iv8SGVebHg5DucTYYleW6gc7I5VtMonlgFCwGEwWtgPZWEgvJskDUcya/bZYrTBTg==", + "version": "6.5.0-next.0", + "resolved": "https://registry.npmjs.org/@colony/colony-js/-/colony-js-6.5.0-next.0.tgz", + "integrity": "sha512-Tr0j5PTA99ZocFxDNNRGfUglgsOR/xfH7GLEEVVDhQTkv3eMlPHwgE5jF+RrcEPgebpIUPvLK84CTFzy/OJc/Q==", "requires": { "cross-fetch": "^3.1.5" } diff --git a/amplify/backend/function/getUserTokenBalance/src/package.json b/amplify/backend/function/getUserTokenBalance/src/package.json index 8b1a0b2ce01..db408648373 100644 --- a/amplify/backend/function/getUserTokenBalance/src/package.json +++ b/amplify/backend/function/getUserTokenBalance/src/package.json @@ -8,9 +8,8 @@ "@types/aws-lambda": "^8.10.92" }, "dependencies": { - "@colony/colony-js": "^6.3.6", + "@colony/colony-js": "^6.5.0-next.0", "ethers": "^5.7.2", "node-fetch": "2.6.7" - } } diff --git a/amplify/backend/function/qaSSMtest/src/package-lock.json b/amplify/backend/function/qaSSMtest/src/package-lock.json index aa4417d29b8..d59b5c088b3 100644 --- a/amplify/backend/function/qaSSMtest/src/package-lock.json +++ b/amplify/backend/function/qaSSMtest/src/package-lock.json @@ -9,7 +9,7 @@ "version": "2.0.0", "license": "Apache-2.0", "dependencies": { - "@colony/colony-js": "^6.3.6", + "@colony/colony-js": "^6.5.0-next.0", "ethers": "^5.7.2", "node-fetch": "2.6.7" }, @@ -18,9 +18,9 @@ } }, "node_modules/@colony/colony-js": { - "version": "6.3.6", - "resolved": "https://registry.npmjs.org/@colony/colony-js/-/colony-js-6.3.6.tgz", - "integrity": "sha512-vfmby0kKiwKjmBt1O/YD5iv8SGVebHg5DucTYYleW6gc7I5VtMonlgFCwGEwWtgPZWEgvJskDUcya/bZYrTBTg==", + "version": "6.5.0-next.0", + "resolved": "https://registry.npmjs.org/@colony/colony-js/-/colony-js-6.5.0-next.0.tgz", + "integrity": "sha512-Tr0j5PTA99ZocFxDNNRGfUglgsOR/xfH7GLEEVVDhQTkv3eMlPHwgE5jF+RrcEPgebpIUPvLK84CTFzy/OJc/Q==", "dependencies": { "cross-fetch": "^3.1.5" }, @@ -927,9 +927,9 @@ }, "dependencies": { "@colony/colony-js": { - "version": "6.3.6", - "resolved": "https://registry.npmjs.org/@colony/colony-js/-/colony-js-6.3.6.tgz", - "integrity": "sha512-vfmby0kKiwKjmBt1O/YD5iv8SGVebHg5DucTYYleW6gc7I5VtMonlgFCwGEwWtgPZWEgvJskDUcya/bZYrTBTg==", + "version": "6.5.0-next.0", + "resolved": "https://registry.npmjs.org/@colony/colony-js/-/colony-js-6.5.0-next.0.tgz", + "integrity": "sha512-Tr0j5PTA99ZocFxDNNRGfUglgsOR/xfH7GLEEVVDhQTkv3eMlPHwgE5jF+RrcEPgebpIUPvLK84CTFzy/OJc/Q==", "requires": { "cross-fetch": "^3.1.5" } diff --git a/amplify/backend/function/qaSSMtest/src/package.json b/amplify/backend/function/qaSSMtest/src/package.json index be66e6e2e01..79da339d471 100644 --- a/amplify/backend/function/qaSSMtest/src/package.json +++ b/amplify/backend/function/qaSSMtest/src/package.json @@ -5,10 +5,9 @@ "main": "index.js", "license": "Apache-2.0", "dependencies": { - "node-fetch": "2.6.7", - "@colony/colony-js": "^6.3.6", - "ethers": "^5.7.2" - + "@colony/colony-js": "^6.5.0-next.0", + "ethers": "^5.7.2", + "node-fetch": "2.6.7" }, "devDependencies": { "@types/aws-lambda": "^8.10.92" From 42616c8eaaa5cbea9f24310fbead6475d10f0f3e Mon Sep 17 00:00:00 2001 From: Jakub Zajac Date: Tue, 22 Aug 2023 19:05:45 +0100 Subject: [PATCH 17/18] Update README --- Readme.md | 25 ++++++++++++++++++++----- scripts/upgrade-colony-js.sh | 2 +- 2 files changed, 21 insertions(+), 6 deletions(-) diff --git a/Readme.md b/Readme.md index 78d935af5f6..0a0150eab12 100644 --- a/Readme.md +++ b/Readme.md @@ -3,9 +3,10 @@ An iteration of the Colony Dapp sporting both a fully decentralized operating mode, as well as a mode enhanced by a metadata caching layer. ## Prerequisites -* `node` `v16.16.x` (Best use [nvm](https://github.com/nvm-sh/nvm)) -* `npm` `v8.11.x` _(At least. The newer, the better)_ -* `docker` `v19.03.0+` (See [install instructions](https://docs.docker.com/engine/install/)) + +- `node` `v16.16.x` (Best use [nvm](https://github.com/nvm-sh/nvm)) +- `npm` `v8.11.x` _(At least. The newer, the better)_ +- `docker` `v19.03.0+` (See [install instructions](https://docs.docker.com/engine/install/)) ## Installation @@ -33,13 +34,14 @@ _Note: at the end of the install there's a post-install script that will recursi npm run dev ``` -This will build your local docker images, then attempt to start them _(the local dev environment runs inside a couple of docker containers). +This will build your local docker images, then attempt to start them \_(the local dev environment runs inside a couple of docker containers). On the next start, assuming no key cache files changed, it will skip the image building step _(as it will just used the cached version)_, and go straight to starting your environment. ## Running the dev web server Once the above dev environment is up and running, you need to start your dev web server, running through webpack: + ```bash npm run webpack ``` @@ -63,6 +65,7 @@ You can also view the status of the reputation monitor using the following URL: ### Truffle If needed, the truffle console is available to you via: + ```bash npm run truffle console ``` @@ -72,20 +75,23 @@ _NOTE: This only works while the environment is running_ ## Building the bundle locally If you want to build the bundle locally for inspection, you can do it via: + ```bash npm run webpack:build -```` +``` _Note: It's a straight-up dev build. Just bundled, no code optimizations whatsoever._ ## Linting Linting your code via `eslint` can be done as such: + ```bash npm run lint ``` To lint the project's style sheets you run: + ```bash npm run stylelint ``` @@ -93,6 +99,7 @@ npm run stylelint ## Type checking Type checking using TypeScript can be accessed using this npm script: + ```bash npm run typecheck @@ -108,4 +115,12 @@ To run unit tests you have the following npm script: npm run test ``` +## Upgrading `colony-js` + +When upgrading `colony-js` package, you usually want to do it for not just CDapp but also all the lambdas that depend on it. There's an `upgrade-colony-js` script that does it for you: + +```bash +npm run upgrade-colony-js +``` + Twemoji graphics made by Twitter and other contributors, licensed under CC-BY 4.0: https://creativecommons.org/licenses/by/4.0/ diff --git a/scripts/upgrade-colony-js.sh b/scripts/upgrade-colony-js.sh index 90573c82fb1..203edbbd2e0 100755 --- a/scripts/upgrade-colony-js.sh +++ b/scripts/upgrade-colony-js.sh @@ -32,4 +32,4 @@ if [ -d "$directory" ]; then fi fi done -fi \ No newline at end of file +fi From c61a8dd35c505927adceaa1536f9ac18d9707c5f Mon Sep 17 00:00:00 2001 From: Jakub Zajac Date: Tue, 22 Aug 2023 19:54:02 +0100 Subject: [PATCH 18/18] Upgrade colony-js in fetchColonyBalances --- .../fetchColonyBalances/src/package-lock.json | 14 +++++++------- .../function/fetchColonyBalances/src/package.json | 2 +- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/amplify/backend/function/fetchColonyBalances/src/package-lock.json b/amplify/backend/function/fetchColonyBalances/src/package-lock.json index 30a69f97624..da93faf01c2 100644 --- a/amplify/backend/function/fetchColonyBalances/src/package-lock.json +++ b/amplify/backend/function/fetchColonyBalances/src/package-lock.json @@ -9,7 +9,7 @@ "version": "2.0.0", "license": "Apache-2.0", "dependencies": { - "@colony/colony-js": "^6.3.6", + "@colony/colony-js": "^6.5.0-next.0", "ethers": "^5.7.2", "node-fetch": "2.6.7" }, @@ -18,9 +18,9 @@ } }, "node_modules/@colony/colony-js": { - "version": "6.3.6", - "resolved": "https://registry.npmjs.org/@colony/colony-js/-/colony-js-6.3.6.tgz", - "integrity": "sha512-vfmby0kKiwKjmBt1O/YD5iv8SGVebHg5DucTYYleW6gc7I5VtMonlgFCwGEwWtgPZWEgvJskDUcya/bZYrTBTg==", + "version": "6.5.0-next.0", + "resolved": "https://registry.npmjs.org/@colony/colony-js/-/colony-js-6.5.0-next.0.tgz", + "integrity": "sha512-Tr0j5PTA99ZocFxDNNRGfUglgsOR/xfH7GLEEVVDhQTkv3eMlPHwgE5jF+RrcEPgebpIUPvLK84CTFzy/OJc/Q==", "dependencies": { "cross-fetch": "^3.1.5" }, @@ -908,9 +908,9 @@ }, "dependencies": { "@colony/colony-js": { - "version": "6.3.6", - "resolved": "https://registry.npmjs.org/@colony/colony-js/-/colony-js-6.3.6.tgz", - "integrity": "sha512-vfmby0kKiwKjmBt1O/YD5iv8SGVebHg5DucTYYleW6gc7I5VtMonlgFCwGEwWtgPZWEgvJskDUcya/bZYrTBTg==", + "version": "6.5.0-next.0", + "resolved": "https://registry.npmjs.org/@colony/colony-js/-/colony-js-6.5.0-next.0.tgz", + "integrity": "sha512-Tr0j5PTA99ZocFxDNNRGfUglgsOR/xfH7GLEEVVDhQTkv3eMlPHwgE5jF+RrcEPgebpIUPvLK84CTFzy/OJc/Q==", "requires": { "cross-fetch": "^3.1.5" } diff --git a/amplify/backend/function/fetchColonyBalances/src/package.json b/amplify/backend/function/fetchColonyBalances/src/package.json index 80cb066c66e..934afa6501a 100644 --- a/amplify/backend/function/fetchColonyBalances/src/package.json +++ b/amplify/backend/function/fetchColonyBalances/src/package.json @@ -8,7 +8,7 @@ "@types/aws-lambda": "^8.10.92" }, "dependencies": { - "@colony/colony-js": "^6.3.6", + "@colony/colony-js": "^6.5.0-next.0", "ethers": "^5.7.2", "node-fetch": "2.6.7" }