This PR focuses on error handling. It changes the way errors are handled in the library and the way the printProgress function prints these errors. An internal error type is specified which can be used to determine the source of an error.
All potential error codes that can be returned by the server are handled and appropriate error messages are printed to the user. doc/weberrors.md outlines the error codes and their cause.
git, git-annex, and system call errors are handled with more descriptive messages. This is not exhaustive like in the case of http errors. More situations need to be covered.
Failure on file operations:
Attempting to unlock files when content isn't available locally notifies the user, but does not result in an error condition.
git-annex operations on untracked files, such as lock, unlock, get (get-content), and drop (remove-content) produces no output. This is in-line with the behaviour of git-annex, but may not be perfect.
doc/errors.md describes potential ways to handle such failures and their merits. The current implementation may not be final.
Added CHANGELOG file to the repository root that lists changes for each version release.
This PR focuses on error handling. It changes the way errors are handled in the library and the way the
printProgress
function prints these errors. An internal error type is specified which can be used to determine the source of an error.doc/weberrors.md
outlines the error codes and their cause.lock
,unlock
,get
(get-content
), anddrop
(remove-content
) produces no output. This is in-line with the behaviour of git-annex, but may not be perfect.doc/errors.md
describes potential ways to handle such failures and their merits. The current implementation may not be final.