Please see the detailed documentation linked above.
DataDeps 1.0 includes breaking changes in the download/fetch API.
Downloading has been refactored to always use Downloads.download(). This removes the dependency on HTTP.jl, which is comparatively large and has had recent breaking changes.
fetch_baseandfetch_httpwere removed.fetch_defaultwas removed.- The default
fetch_methodis nowfetch.
These are not quite the same but are similar enough for most use cases.
If your code used one of the removed fetch wrappers:
- Replace
fetch_default(remote, dir)withfetch(remote, dir). - Replace
fetch_base(remote, dir)withfetch(remote, dir; update_period=Inf). - Replace
fetch_http(remote, dir; update_period=...)withfetch(remote, dir; update_period=...). - Overload
Downloads.download(::YourType)instead ofBase.download(::YourType).
The built-in fetch method now supports a keyword progress_callback additional to update_period.
progress_callbacktakes a function with three arguments:(total_bytes, downloaded_bytes, filename_hint) -> <... function core ...>.- If
progress_callbackis not provided andupdate_periodis finite, a default logging callback is used, which replaces the previous logging from HTTP.jl
It might help to look at how DataDeps.jl is being used to understand how it may be used in your project. Some of these add some additional abstraction or niceness for users on top of the DataDeps.jl core functionality.
(Feel free to submit a PR adding a link to your package, or research script here.)
- ANN: thread on Discourse
- MLOSS
- Release Blog Post
- DataDepsGenerators.jl
- JuliaCon 2018 Slides, and Video