Use Node.js test runner instead of mocha and chai#877
Conversation
…ce PG converts everything to lowercase
|
Caution Review failedFailed to post review comments 📝 WalkthroughWalkthroughThis PR refactors the core indexer architecture from Handlers-based to Indexer-based execution, introduces context-based parameter passing, expands TypeScript configuration types, adds a terminal UI, migrates database access to PgStorage, and updates code generation templates and test frameworks across the codebase. Changes
Sequence Diagram(s)sequenceDiagram
participant Main as Main.start()
participant Config as Config.fromPublic()
participant ChainMgr as ChainManager
participant GlobalState as GlobalState
participant EventProc as EventProcessing
participant Persistence as Persistence/PgStorage
participant TUI as TUI/Server
Main->>Config: Parse internalConfigJson + codegenChains
Config->>Persistence: Initialize DB client (PgStorage.makeClient)
Config-->>Main: Return Config with merged contracts/ABIs
Main->>ChainMgr: Create with Config
Main->>Persistence: Load initial state from DB
Main->>GlobalState: Create with ctx (Config + Persistence)
Main->>TUI: Start TUI + HTTP server
Main->>Main: Dispatch NextQuery(CheckAllChains)
loop Event Processing
EventProc->>GlobalState: Get state via ctx
EventProc->>Persistence: Read batches via ctx.persistence
EventProc->>EventProc: Process events with single chain context
EventProc->>Persistence: Write entities via ctx.persistence
EventProc->>GlobalState: Update progress
GlobalState->>TUI: Emit state changes
end
TUI->>GlobalState: Poll getState()
TUI-->>User: Render chain progress/metrics
Estimated code review effort🎯 4 (Complex) | ⏱️ ~75 minutes Possibly related PRs
Suggested reviewers
Pre-merge checks and finishing touches❌ Failed checks (1 warning)
✅ Passed checks (2 passed)
✨ Finishing touches
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
Closed in favor of Vitest #884 |
Summary by CodeRabbit
New Features
Chores
✏️ Tip: You can customize this high-level summary in your review settings.