From 4cec641d428114f4a2d8790e1c7021834cdab984 Mon Sep 17 00:00:00 2001 From: roll Date: Tue, 17 Sep 2019 17:37:31 +0300 Subject: [PATCH 1/2] Added support for s3 scheme --- datapackage/resource.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/datapackage/resource.py b/datapackage/resource.py index 3fef6e1..9979b92 100644 --- a/datapackage/resource.py +++ b/datapackage/resource.py @@ -489,7 +489,7 @@ def _inspect_source(data, path, base_path, storage): elif len(path) == 1: # Remote - if path[0].startswith('http'): + if path[0].startswith('http') or path[0].startswith('s3'): inspection['source'] = path[0] inspection['remote'] = True elif base_path and base_path.startswith('http'): From 5dca445c3ce4634e47d7b859324ae4eea8f14dde Mon Sep 17 00:00:00 2001 From: roll Date: Tue, 17 Sep 2019 17:44:43 +0300 Subject: [PATCH 2/2] Added ftp as well --- datapackage/resource.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/datapackage/resource.py b/datapackage/resource.py index 9979b92..4875fcb 100644 --- a/datapackage/resource.py +++ b/datapackage/resource.py @@ -489,7 +489,7 @@ def _inspect_source(data, path, base_path, storage): elif len(path) == 1: # Remote - if path[0].startswith('http') or path[0].startswith('s3'): + if path[0].startswith('http') or path[0].startswith('ftp') or path[0].startswith('s3'): inspection['source'] = path[0] inspection['remote'] = True elif base_path and base_path.startswith('http'):