Skip to content

Conversation

@jakeloo
Copy link
Member

@jakeloo jakeloo commented Mar 20, 2025

This pull request focuses on refining the event and transaction retrieval methods in the insight.py file, improving the flexibility and consistency of the API. The key changes include renaming methods, adding sorting options, and removing redundant parameters.

Improvements to event and transaction retrieval methods:

  • Method Renaming and Parameter Updates:

    • Renamed get_events to get_all_events and updated the method signature to include sorting options and default parameters.
    • Removed the decode and block_number parameters from get_all_events to streamline the method.
    • Added sort_order parameter to get_all_events and set default parameters for sorting and decoding.
  • Enhancements to get_contract_events:

    • Removed the decode parameter and added sort_order to allow sorting of events.
    • Set default sorting and decoding parameters in get_contract_events.
  • Removal of Redundant Methods:

    • Removed the get_contract_events_by_signature method to reduce redundancy and simplify the codebase.
  • Transaction Retrieval Improvements:

    • Removed the decode parameter from get_all_transactions and set default sorting and decoding parameters. [1] [2] [3]
  • Other Method Updates:

    • Updated the description and parameters of get_token_prices to include native tokens and removed the currencies parameter.
    • Merged get_contract_abi functionality into get_contract_metadata to consolidate contract-related information retrieval.
    • Updated the resolve method description to provide a more comprehensive explanation of its capabilities.

@jakeloo jakeloo merged commit ed71815 into main Mar 20, 2025
2 checks passed
@jakeloo jakeloo deleted the jl/improve-insight branch March 20, 2025 06:29
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.

2 participants