Skip to content

Remove unused code#5

Open
chowbao wants to merge 7 commits intomasterfrom
chore/remove-unused-code
Open

Remove unused code#5
chowbao wants to merge 7 commits intomasterfrom
chore/remove-unused-code

Conversation

@chowbao
Copy link
Copy Markdown
Owner

@chowbao chowbao commented Feb 19, 2026

PR Checklist

PR Structure

  • This PR has reasonably narrow scope (if not, break it down into smaller PRs).
  • This PR avoids mixing refactoring changes with feature changes (split into two PRs otherwise).
  • This PR's title starts with the jira ticket associated with the PR.

Thoroughness

  • This PR adds tests for the most critical parts of the new functionality or fixes.
  • I've updated the README with the added features, breaking changes, new instructions on how to use the repository.

Release planning

  • I've decided if this PR requires a new major/minor/patch version accordingly to semver, and I've changed the name of the BRANCH to major/_ , minor/_ or patch/*.

What

Removes unused code that is no longer referenced anywhere in the codebase:

  • cmd/export_ledger_transaction.go — the export_ledger_transaction CLI command and its tests
  • internal/input/all_history.go — the all_history input module
  • internal/input/orderbooks.go — the orderbooks input module
  • internal/transform/ledger_transaction.go — the ledger_transaction transform and its tests
  • internal/transform/offer_normalized.go — the offer_normalized transform and its tests
  • testdata/ledger_transactions/ledger_transactions.golden — associated test golden file
  • Removes unused functions/types from internal/toid, internal/transform/schema.go, and internal/utils/main.go

Why

These modules were dead code — not referenced by any active command or pipeline. Removing them reduces maintenance burden, keeps the codebase easier to navigate, and avoids confusion about whether these exports are still supported.

Known limitations

N/A

@chowbao
Copy link
Copy Markdown
Owner Author

chowbao commented Feb 19, 2026

@claude fill out the PR description

@claude
Copy link
Copy Markdown

claude bot commented Feb 19, 2026

Claude finished @chowbao's task in 1m 11s —— View job


PR Description

Here is the filled-out PR description based on the changes in this PR:


What

Removes unused code across multiple packages, including deleted files and unused functions/types:

  • cmd/export_ledger_transaction.go — Removed the export_ledger_transaction CLI command and its test file.
  • internal/input/all_history.go — Removed the GetAllHistory input function for fetching operations, trades, and transactions across a ledger range.
  • internal/input/orderbooks.go — Removed the OrderbookParser and OrderbookBatch types and all associated orderbook parsing logic.
  • internal/transform/ledger_transaction.go — Removed the TransformLedgerTransaction transform function and its test file.
  • internal/transform/offer_normalized.go — Removed the TransformOfferNormalized transform function and its test file.
  • internal/transform/schema.go — Removed unused schema types: LedgerTransactionOutput, LiquidityPoolAsset, DimAccount, DimOffer, DimMarket, FactOfferEvent, NormalizedOfferOutput, and TradeEffectDetails.
  • internal/toid/main.go — Removed AfterLedger and LedgerRangeInclusive helper functions.
  • internal/utils/main.go — Removed GetMostRecentCheckpoint utility function.
  • testdata/ledger_transactions/ — Removed golden test data associated with the deleted ledger transaction transform.

Why

These code paths were no longer referenced anywhere in the codebase and were dead code. Removing them reduces maintenance burden, eliminates confusion about supported export types, and keeps the codebase aligned with the features that are actively used and maintained.

Known limitations

N/A


Note: I cannot directly edit the PR description body — please copy the above into the PR description. Let me know if you'd like any adjustments to the wording.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant