cloud-volume
cloud-volume copied to clipboard
AttributeError: module 'cloudfiles.paths' has no attribute 'update_aliases_from_file'
Hi Will, me again. Thanks for fixing the zfpc issue so quickly - that works now.
Unfortunately another issue popped up:
>>> vol = cv.CloudVolume(FLYWIRE_PRODUCTION_DATASET_URL, use_https=True, mip=0)
---------------------------------------------------------------------------
AttributeError Traceback (most recent call last)
Input In [5], in <cell line: 1>()
----> 1 vol = cv.CloudVolume('graphene://https://prod.flywire-daf.com/segmentation/table/fly_v31', use_https=True, mip=0)
File ~/.pyenv/versions/3.8.10/lib/python3.8/site-packages/cloudvolume/cloudvolume.py:233, in CloudVolume.__new__(cls, cloudpath, mip, bounded, autocrop, fill_missing, cache, compress_cache, cdn_cache, progress, info, provenance, compress, compress_level, non_aligned_writes, parallel, delete_black_uploads, background_color, green_threads, use_https, max_redirects, mesh_dir, skel_dir, agglomerate, secrets, spatial_index_db, lru_bytes)
231 path = strict_extract(cloudpath)
232 if path.format in REGISTERED_PLUGINS:
--> 233 return REGISTERED_PLUGINS[path.format](**kwargs)
234 else:
235 raise UnsupportedFormatError(
236 "Unknown format {}".format(path.format)
237 )
File ~/.pyenv/versions/3.8.10/lib/python3.8/site-packages/cloudvolume/datasource/graphene/__init__.py:63, in create_graphene(cloudpath, mip, bounded, autocrop, fill_missing, cache, compress_cache, cdn_cache, progress, info, provenance, compress, parallel, delete_black_uploads, background_color, green_threads, use_https, mesh_dir, skel_dir, agglomerate, secrets, spatial_index_db, lru_bytes, **kwargs)
54 meta = GrapheneMetadata(
55 cloudpath, config=config, cache=mkcache(cloudpath),
56 info=info, provenance=provenance,
57 use_https=use_https, agglomerate=agglomerate,
58 auth_token=config.secrets,
59 )
60 # Resetting the cache is necessary because
61 # graphene retrieves a data_dir from the info file
62 # that reflects the real cache location.
---> 63 cache_service = mkcache(meta.cloudpath)
64 meta.cache = cache_service
65 cache_service.meta = meta
File ~/.pyenv/versions/3.8.10/lib/python3.8/site-packages/cloudvolume/datasource/graphene/__init__.py:49, in create_graphene.<locals>.mkcache(cloudpath)
47 def mkcache(cloudpath):
48 return CacheService(
---> 49 cloudpath=get_cache_path(cache, cloudpath),
50 enabled=bool(cache),
51 config=config,
52 compress=compress_cache,
53 )
File ~/.pyenv/versions/3.8.10/lib/python3.8/site-packages/cloudvolume/datasource/__init__.py:88, in get_cache_path(cache, cloudpath)
85 return get_cache_path_helper(CLOUD_VOLUME_CACHE_DIR, cloudpath)
87 base = os.path.join(CLOUD_VOLUME_DIR, 'cache')
---> 88 return get_cache_path_helper(base, cloudpath)
File ~/.pyenv/versions/3.8.10/lib/python3.8/site-packages/cloudvolume/datasource/__init__.py:91, in get_cache_path_helper(base, cloudpath)
90 def get_cache_path_helper(base, cloudpath):
---> 91 path = paths.extract(cloudpath)
92 basepath = path.basepath
93 if basepath[0] == os.path.sep:
File ~/.pyenv/versions/3.8.10/lib/python3.8/site-packages/cloudvolume/paths.py:151, in extract(cloudpath, windows, disable_toabs)
148 else:
149 abspath = toabs
--> 151 fmt, protocol, cloudpath = extract_format_protocol(cloudpath)
153 split_char = '/'
154 if protocol == 'file':
File ~/.pyenv/versions/3.8.10/lib/python3.8/site-packages/cloudvolume/paths.py:81, in extract_format_protocol(cloudpath)
78 (proto, cloudpath) = pop_protocol(cloudpath)
80 if proto not in (ALLOWED_PROTOCOLS + ALLOWED_FORMATS):
---> 81 cloudfiles.paths.update_aliases_from_file()
82 ALLOWED_PROTOCOLS = cloudfiles.paths.ALLOWED_PROTOCOLS
84 if proto in ALLOWED_FORMATS:
AttributeError: module 'cloudfiles.paths' has no attribute 'update_aliases_from_file'
With FLYWIRE_PRODUCTION_DATASET_URL
being the graphene://https://..._v31
.
Never mind - I was running 4.4.0
of cloud-files
and updating solved the issue. Perhaps a good idea to bump the minimum version for cloud-files?
Not a bad idea! I'll consider doing that in the next release.
On Fri, Aug 5, 2022 at 11:46 AM Philipp Schlegel @.***> wrote:
Never mind - I was running 4.4.0 of cloud-files and updating solved the issue. Perhaps a good idea to bump the minimum version for cloud-files?
— Reply to this email directly, view it on GitHub https://github.com/seung-lab/cloud-volume/issues/551#issuecomment-1206599716, or unsubscribe https://github.com/notifications/unsubscribe-auth/AATGQSLQR263MAGWHVV4BHLVXUZM5ANCNFSM55WQA3WQ . You are receiving this because you are subscribed to this thread.Message ID: @.***>
Minimum version of CloudFiles has been bumped for some time.