Skip to content

No module named parse #8

@Cappuccinuo

Description

@Cappuccinuo

Situation: I want to start a blockchain node

Action: sudo python blockchain.py -p 5000

Result:

Traceback (most recent call last):
  File "blockchain.py", line 33, in <module>
    from urllib.parse import urlparse
ImportError: No module named parse

Attemption:
pip install parse(install success, does not solve problem)
pip install urllib(No matching distribution found for urllib)
pip install urlparse(No matching distribution found for urlparse)

Solution:
In blockchain.py, change
from urllib.parse import urlparse
to
from urlparse import urlparse

Could you please tell me the reason why we cannot import urlparse from urllib.parse?

And I wonder if we can only execute all the command like create node, start the blockchain client under root? As it notify me "cannot import Crypto" when I type python blockchain_client.py without sudo.

Thanks.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions