Skip to content

Tweaks to reflect breaking changes in ethpm refactor #1374

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 1 commit into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
25 changes: 10 additions & 15 deletions web3/pm.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,11 @@
Tuple,
)

from eth_typing import (
URI,
Address,
Manifest,
)
from eth_utils import (
is_canonical_address,
is_checksum_address,
Expand All @@ -31,25 +36,15 @@
ASSETS_DIR,
Package,
)
from ethpm.typing import (
URI,
Address,
Manifest,
)
from ethpm.utils.backend import (
from ethpm.uri import (
is_supported_content_addressed_uri,
resolve_uri_contents,
)
from ethpm.utils.ipfs import (
is_ipfs_uri,
)
from ethpm.utils.manifest_validation import (
from ethpm.validation.manifest import (
validate_manifest_against_schema,
validate_raw_manifest_format,
)
from ethpm.utils.uri import (
is_valid_content_addressed_github_uri,
)
from ethpm.validation import (
from ethpm.validation.package import (
validate_package_name,
validate_package_version,
)
Expand Down Expand Up @@ -659,7 +654,7 @@ def get_solidity_registry_manifest() -> Dict[str, Any]:


def validate_is_supported_manifest_uri(uri):
if not is_ipfs_uri(uri) and not is_valid_content_addressed_github_uri(uri):
if not is_supported_content_addressed_uri(uri):
raise ManifestValidationError(
f"URI: {uri} is not a valid content-addressed URI. "
"Currently only IPFS and Github content-addressed URIs are supported."
Expand Down