Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

No module named 'ethtx.semantics'

See original GitHub issue

Windows 10. Python version 3.10.4. Latest version for ethtx is installed with pip install ethtx.

I created a file with the following content:

from ethtx import EthTx, EthTxConfig
from ethtx.models.decoded_model import DecodedTransaction

ethtx_config = EthTxConfig(
    etherscan_api_key="my etherscan API key",  ##Etherscan API key,
        "mainnet": {
            "hook": "my Infura url",  # multiple nodes supported, separate them with comma
            "poa": False  # represented by bool value
    etherscan_urls={"mainnet": "" }

ethtx = EthTx.initialize(ethtx_config)
transaction: DecodedTransaction = ethtx.decoders.decode_transaction(

Once I try to execute the file with py, I get the following error:

Traceback (most recent call last):
  File "C:\Users\Utente\Desktop\ethtx\", line 1, in <module>
    from ethtx import EthTx, EthTxConfig
  File "C:\Users\Utente\AppData\Local\Programs\Python\Python310\lib\site-packages\ethtx\", line 13, in <module>
    from .ethtx import EthTx, EthTxConfig
  File "C:\Users\Utente\AppData\Local\Programs\Python\Python310\lib\site-packages\ethtx\", line 18, in <module>
    from .decoders.abi.decoder import ABIDecoder
  File "C:\Users\Utente\AppData\Local\Programs\Python\Python310\lib\site-packages\ethtx\decoders\abi\", line 32, in <module>
    from .abc import IABIDecoder
  File "C:\Users\Utente\AppData\Local\Programs\Python\Python310\lib\site-packages\ethtx\decoders\abi\", line 25, in <module>
    from ethtx.providers.semantic_providers import SemanticsRepository
  File "C:\Users\Utente\AppData\Local\Programs\Python\Python310\lib\site-packages\ethtx\providers\semantic_providers\", line 15, in <module>
    from .repository import SemanticsRepository
  File "C:\Users\Utente\AppData\Local\Programs\Python\Python310\lib\site-packages\ethtx\providers\semantic_providers\", line 30, in <module>
    from ethtx.semantics.protocols_router import amend_contract_semantics
  File "C:\Users\Utente\AppData\Local\Programs\Python\Python310\lib\site-packages\ethtx\semantics\", line 21, in <module>
    def amend_contract_semantics(semantics: ContractSemantics, router_=Router()):
  File "C:\Users\Utente\AppData\Local\Programs\Python\Python310\lib\site-packages\ethtx\semantics\", line 30, in __new__
    return cls._get_semantics()
  File "C:\Users\Utente\AppData\Local\Programs\Python\Python310\lib\site-packages\ethtx\semantics\", line 52, in _get_semantics
    imported_module = importlib.import_module(
  File "C:\Users\Utente\AppData\Local\Programs\Python\Python310\lib\importlib\", line 126, in import_module
    return _bootstrap._gcd_import(name[level:], package, level)
ModuleNotFoundError: No module named 'ethtx.semanticsC:\\Users\\Utente\\AppData\\Local\\Programs\\Python\\Python310\\lib\\site-packages\\ethtx\\semantics\\base'

What’s the issue? Thanks for the help.

Issue Analytics

  • State:closed
  • Created a year ago
  • Comments:10

github_iconTop GitHub Comments

kchojncommented, Apr 6, 2022

Np! Glad to help! If you need any help with ethtx, you can always write to us on discord 🤠 Best regards!

enmohsinalicommented, Apr 6, 2022

Hey @yuripaoloni, provides full node which kept historical state of last 64 blocks. So if you wanna decode latest transaction then getblocks might be helpful .

Read more comments on GitHub >

github_iconTop Results From Across the Web

ModuleNotFoundError: No module named 'eth_utils.toolz' #1101
Version: 4.7.2 Python: 3.6.6 OS: linux What was wrong? getting this exception raised on import web3 Please include any of the following that ......
Read more >
ModuleNotFoundError: No module named 'semantic-version'
Hi, My Python program is throwing following error: ModuleNotFoundError: No module named 'semantic-version' How to remove the M.
Read more >
EthTx · PyPI
EthTx transaction decoder. ... EthTx - Ethereum transactions decoder ... required to store smart contracts' ABI and semantics used in the decoding process....
Read more >
ModuleNotFoundError: No module named 'ethereum'
I am trying to run cert-issuer using Ethereum but I have the error No module named 'ethereum' as could be seen below.
Read more >
Cisco MDS 9000 Series Command Reference, Release 9.x
This command has no other arguments or keywords. ... show analytics query { "query_string" [clear] [differential] | all | name query_name [result]} ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Post

No results found

github_iconTop Related Hashnode Post

No results found