tag!
and parent functions allow keywordwarn
.- Keyword
warn
is propagated togitdescribe
and now can be set tofalse
to silence the warning that the git repo is dirty. It can also be set at an ENV variable level.
- Update compat bounds for JLD2 to include v0.5
- Add
load_function
keyword argument tocollect_results
to customize how data is loaded from file before being converted to a dataframe bycollect_results
- Add
wload_kwargs
toproduce_or_load
to allow passing kwargs towload
- Add keyword argument
folders_to_gitignore
to theinitialize_project
to customize the.gitignore
file creation during project setup
- Add
commmit_message
option intag!
, which add an additional"gitmessage"
field in dictionaryd
and include the git message associated with the commit.
- Crucial bugfix to
produce_or_load
. When used with a prefix, it attached double prefix to the file (one coming as a duplicate fromsavename
). This is now fixed, but it means that some files produced with prefix andproduce_or_load
in v2.12 may be re-produced after this update.
- Arbitrary functions extracting strings from data can be used in
produce_or_load
instead ofsavename
.hash
is the most useful function here. An example in Real World Examples highlights this. - Additional keywords in
produce_or_load
propagated tosavename
are deprecated. - The example project created in the Workflow Tutorial no longer has spaces in its name
- Now the default project with
initialize_project
will include a documentation and a test folder, and setup CI for both automatically. @produce_or_load
was broken but because CI was disabled this was silently ignored.produce_or_load
now has call signatureproduce_or_load(f::Function, config, path::String = "")
and same signature for the macro withpath
mandatory.
- Add
Derived
type and function to allowdict_list
to compute some parameters from the value of other parameters. - Add
DRWATSON_UPDATE_MSG
ENV VAR for suppressing update messages
- Add
filename
option inproduce_or_load
, possibly overriding the default filename generated bysavename
- Add filtering of
collect_results
usingrinclude
andrexclude
keyword arguments.
- By default
storepatch
keywords arefalse
. This means thatgitpatch
is NOT stored by default. This is a BUGFIX, because there is an unknown problem of non-halting when storing the patch.
- DrWatson-related
ENV
ironment variables are now available to globally set the default values for e.g. story git patches, tagging, or safe-saving in various functions liketagsave
orproduce_or_load
.
- Use
JLD2
's jldopen incollect_results!
to speed up loading of metadata.
- Add an
update
option ofcollect_results!
allowing the updating of an existing results collection if data files were modified or deleted.
savename
's default options now havesigdigits = 3
instead ofdigits = 3
as stated in the documentation string. This was supposed to happen already since 2.0 but did not because of a bug. (#284)- Any subtypes of
AbstractDict
now work with DrWatson (#283).
- Add the macro version of
produce_or_load
to enable tagging with the calling source file and line.
- Enable pass through of kwargs to
wsave
inproduce_or_load
,tagsave
andsafesave
(to e.g. allow compression in JLD2 files).
isdirty(gitpath = projectdir())
function for checking ifgitpath
points to a dirty Git repository. (#263)
initialize_project
now allows for custom templates.
produce_or_load
now will not attempt totagsave
for inappropriate file formats, like.csv
.
- Added a kwarg
equals
tosavename
to extend applicability.
- DrWatson has moved entirely on using JLD2.jl instead of BSON.jl for saving files, and also suggests the same to its users through the documentation.
tmpsave
now saves as JLD2.jl and requires loading explicitly the"params"
field.collect_results
saves as JLD2.jl by default now.produce_or_load
saves as JLD2.jl by default now.savename
will no longer replace a floating point number with its integer version, if they coincide with respect to rounding. Thus, "integer"AbstractFloat
s will always end with.0
insavename
.savename
'sscientific
keyword has been replaced bysigdigits
, as this was the only thing it was doing.savename
's default options now havesigdigits = 3
instead ofdigits = 3
.
savename
now allows a keywordval_to_string
for customization.
- Remove type constraints on
produce_or_load
path argument (#229)
- Keyword
storepatch
now exists inproduce_or_load
as well.
- Fix
dict_list_count
returns wrong number of elements with@onlyif
. (#223) - Fix
gitpatch
for git versions not supporting submodules. (#224)
- Two new functions
tostringdict, tosymboldict
for changing dictionary key types.
produce_or_load
now supports passing function as the first argument to support the do-block syntax.
@onlyif
now doesn't expand vector arguments if it's placed inside another vector. (#209)@onlyif
now supports chaining. See real world examples: "Defining parameter sets with restrictions". (#210)
- The patch information for a dirty repository now also contains the diff for submodules.
dict_list
now retains the value's type from the passed dictionary.
- Add a
sort
option tosavename
.
- Better default readme file for a new project.
- new keyword argument
rpath
forcollect_results!
that allows storing relative paths
- New macro
@onlyif
that allows placing restrictions on values in a dictionary used for expansion withdict_list
gitpach
now shows a warning ifgit
was not found in PATH
savename
now includesTimeType
(dates) in the default allowed types.
wsave/wload
now support keyword arguments.
- Macros
@pack!, @unpack
are re-exported by DrWatson.
- New function
struct2ntuple
that converts a struct to a NamedTuple (for saving)
savename
now has theignore
option.
@quickactivate
was enhanced to allow projects that also represent a module.initialize_project
no resolves the folder name for naming the project if the path is given as "." or ".."
- Improve the introductory file created by DrWatson.
@tag!
and@tagsave
now support using;
as keywords separator (#111)
quickactivate
doesn't do anything anymore if you try to activate to already active project.- New macro
@quickactivate
- Started to add support for overloading save/load for custom files. See the updated docs around
wsave
andwload
.
- Fix a bug that created incompatible version strings in generated
Project.toml
files on release candidate versions of Julia.
savename
now supports rounding to significant digits with the keyword argumentscientific
, wherescientific
defines the number of significant digits.
initialize_project
now adds a Julia version undercompat
in the createdProject.toml
when it is called.- The functions
tag!, tagsave
and their respective macros now obtain their arguments (besides the first two) as keywords instead of positional arguments. The positional versions are deprecated (#93). - New keyword
force = false
fortag!
and co. which replaces the existinggitcommit
field.
- Improved behavior of
savename
with respect to nested containers. If a nested container is empty, it is not printed instead. For example,T=100_p=()_x=2
now becomesT=100_x=2
. (ifp
is not empty then it is expanded as usual)
initialize_project
no longer makes a test directory.
- Allow
tag!
and derivatives to handle dictionaries with key typeAny
.
First major release (no notable change from 0.8.0).
- [BREAKING] : The
gitpath
argument used among many functions can now also point to a subdirectory within a git repository. Previously it had to be the top directory (i.e. the one containing.git/
). - [BREAKING] : Slightly changed how
produce_or_load
usespath
and interacts withsavename
, to better incorporate the changes done in version 0.6.0.prefix
is now also supported. tag!
and co now also store the git diff patch if the repo is dirty, seegitpatch
(#80).- [BREAKING] :
tag!
now saves the commit information into a fieldgitcommit
instead of justcommit
.
projectdir()
now warns if no project (other than the standard one) is active
- New macro
@savename
that is a shortcut forsavename(@dict vars...)
- New function
gitdescribe
(see below) - [DEPRECATED]
current_commit()
has been deprecated and replaced bygitdescribe()
which now replaces the output ofgit describe
if an annotated tag exists, otherwise it will return the latest commit hash.
- [BREAKING] Reworked the way the functions
projectdir
and derivatives work (#47, #64, #66). Nowprojectdir(args...)
usesjoinpath
to connect arguments. None of the functions likeprojectdir
and derivatives now end in/
as well, to ensure more stability and motivate users to usejoinpath
or the new functionality ofprojectdir(args...)
instead of using string multiplication*
. - New function
parse_savename
that attempts to reverse engineer the result ofsavename
.
- Improvements to
.gitignore
(#55 , #54)
This release has breaking changes.
- Adjusted return value of
produce_or_load
(#52). It now always return the file and the path it is saved. Ifloadfile = false
it returnsnothing, path
. - The functionality of
default_prefix
has been modified (#51). Now there is a nice interplay between defining adefault_prefix
and passing a prefix tosavename
. They are merged likejoinpath(prefix, default_prefix)
. This is valid only whendefault_prefix
has a value other than""
(the default).
- Add expand functionality to
savename
, which handles better containers with nested containers (#50) produce_or_load
now allows the possibility of not loading the file- New function
struct2dict
that converts a struct to a dictionary (for saving)
- Added
test
as a directory of the default project (#43) - Added
tmpsave
functionality: save the result ofdict_list
in temporary files and conveniently work with sequential clusters (#45) - Now all saving related functions of DrWatson first
mkpath
of the path to save at and then save (#45)
- Improve type-stability of return value of
dict_list
(#41)
- Changed
path
andprojectpath
arguments of various functions (e.g.tagsave
,current_commit
) togitpath
universally. - make keyword arguments of
tagsave
positional arguments instead (to work with the macros) - Added two new macros:
@tag!
and@tagsave
: these do the same thing astag!, tagsave
but in addition are able to record both the script name that called them as well as the line of code that they were called at.
This is the first beta release! Changelog is kept with respect to here!