Skip to content

Commit

Permalink
refactor: remove unused events from ethereum-governance
Browse files Browse the repository at this point in the history
  • Loading branch information
katamarinaki committed Oct 28, 2024
1 parent e218aa6 commit 55cf492
Show file tree
Hide file tree
Showing 13 changed files with 13 additions and 370 deletions.
3 changes: 1 addition & 2 deletions ethereum-governance/src/services/easy-track/EasyTrack.srv.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ import { ethers, Finding, FindingSeverity, FindingType, getEthersProvider } from
import { elapsedTime } from '../../shared/time'
import { etherscanAddress, formatEth, getMotionLink, getMotionType } from '../../shared/string'
import { TransactionEvent } from 'forta-agent/dist/sdk/transaction.event'
import { MOTION_CREATED_EVENT } from '../../shared/events/motion_created_events'

import { Logger } from 'winston'
import { IEasyTrackClient } from './contract'
Expand All @@ -17,7 +16,7 @@ import {
} from 'constants/easy-track'
import * as E from 'fp-ts/Either'
import { networkAlert } from '../../shared/errors'
import { EASY_TRACK_EVENTS } from '../../shared/events/easytrack_events'
import { EASY_TRACK_EVENTS, MOTION_CREATED_EVENT } from '../../shared/events/easytrack_events'
import { TopUpAllowedRecipients__factory } from '../../generated'
import { getMotionCreatorNamedLink, getSafeNameByAddress, getStonksContractInfo } from './utils'

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import { handleEventsOfNotice } from '../../shared/notice'

import { Finding, TransactionEvent } from 'forta-agent'

import { TRP_EVENTS_OF_NOTICE } from '../../shared/events/trp_changes'
import { TRP_EVENTS_OF_NOTICE } from '../../shared/events/trp_events'

export class TrpChangesSrv {
private readonly logger: Logger
Expand Down
35 changes: 0 additions & 35 deletions ethereum-governance/src/shared/events/burner_events.ts

This file was deleted.

72 changes: 0 additions & 72 deletions ethereum-governance/src/shared/events/deposit_security_events.ts

This file was deleted.

13 changes: 11 additions & 2 deletions ethereum-governance/src/shared/events/easytrack_events.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,18 @@ import { EventOfNotice } from '../../entity/events'
import { FindingSeverity, FindingType } from 'forta-agent'
import { etherscanAddress } from '../string'
import { EASY_TRACK_ADDRESS, REWARD_PROGRAMS_REGISTRY_ADDRESS, EVM_SCRIPT_EXECUTOR_ADDRESS } from 'constants/easy-track'
import { MOTION_ENACTED_EVENT } from './motion_enacted_events'
import { Result } from '@ethersproject/abi/lib'

export const MOTION_CREATED_EVENT = `
event MotionCreated(
uint256 indexed _motionId,
address _creator,
address indexed _evmScriptFactory,
bytes _evmScriptCallData,
bytes _evmScript
)
`

export const EASY_TRACK_EVENTS: EventOfNotice[] = [
{
address: EASY_TRACK_ADDRESS,
Expand Down Expand Up @@ -50,7 +59,7 @@ export const EASY_TRACK_EVENTS: EventOfNotice[] = [
},
{
address: EASY_TRACK_ADDRESS,
event: MOTION_ENACTED_EVENT,
event: 'event MotionEnacted(uint256 indexed _motionId)',
alertId: 'EASY-TRACK-MOTION-ENACTED',
name: '✅ EasyTrack: Motion executed successfully 🎉',
description: (args: Result) => `EasyTrack motion ${args._motionId} was enacted`,
Expand Down
4 changes: 0 additions & 4 deletions ethereum-governance/src/shared/events/gate_seal_events.ts

This file was deleted.

81 changes: 0 additions & 81 deletions ethereum-governance/src/shared/events/insurance_fund_events.ts

This file was deleted.

109 changes: 0 additions & 109 deletions ethereum-governance/src/shared/events/lido_events.ts

This file was deleted.

This file was deleted.

This file was deleted.

7 changes: 0 additions & 7 deletions ethereum-governance/src/shared/events/vault_events.ts

This file was deleted.

Loading

0 comments on commit 55cf492

Please sign in to comment.