Skip to main content

Solc Event Extractor

Solc Event Extractor is a Python library for extracting metadata (events and functions) from Solidity contracts. It allows you to parse Solidity source files or URLs pointing to Solidity code and retrieve detailed information about contract events and functions.

Features

  • Extracts events and functions from Solidity contracts.
  • Supports both local files and URLs.
  • Handles different Solidity compiler versions.
  • Provides detailed metadata including inputs, outputs, and state mutability.

Installation

You can install the library via pip:

bash uv pip install solc-event-extractor

Usage

In order to use the library, provide a raw github contract path or filepath to a .sol file. Make sure that the correct solidity version is also selected.

from solc_event_extractor import extract_contract_details

contract_source = 'path/to/your/contract.sol'
details = extract_contract_details(contract_source, version='0.8.26')

if details:
    print("Events:")
    for event in details['events']:
        print(f" - {event.name}: {event.signature}")

    print("\nFunctions:")
    for function in details['functions']:
        print(f" - {function.name}: {function.signature}")
else:
    print("Failed to extract contract details.")

Metadata

Release files for solc-event-extractor 0.1.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for solc-event-extractor 0.1.0
File Size Uploaded Provenance Actions
solc_event_extractor-0.1.0.tar.gz 5.1 kB Without provenance Details for solc_event_extractor-0.1.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for solc-event-extractor 0.1.0
File Interpreter ABI Platform Actions
solc_event_extractor-0.1.0-py3-none-any.whl Python 3 none any Details for solc_event_extractor-0.1.0-py3-none-any.whl

Total release size: 8.9 kB

Release files / solc_event_extractor-0.1.0.tar.gz

Download URL solc_event_extractor-0.1.0.tar.gz
Size 5.1 kB
Tags Source
SHA-256 checksum
How to use checksums
10a3c138ec42bb0326e764cb8325c639caed805b143922b528cfaee76c0ab5ce
BLAKE2b-256 checksum
How to use checksums
0d7e004259c46b7c5ec8e87ee573bdde1a4cd411b9982f59bec65e77f825bcd0
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.1.1 CPython/3.12.2

Release files / solc_event_extractor-0.1.0-py3-none-any.whl

Download URL solc_event_extractor-0.1.0-py3-none-any.whl
Size 3.9 kB
Tags Python 3
SHA-256 checksum
How to use checksums
f23e0233c89966391703d8393c346e80c64c4d2eb6973c306350f10adf3c33a7
BLAKE2b-256 checksum
How to use checksums
0192d5bda6e67b793f88a0a2e7def58b7d39e6b9dc51d65091ac9965c8dcaec9
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.1.1 CPython/3.12.2

Security for solc-event-extractor 0.1.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

0.1.0 This release

2 release files No provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page