Implement load-vocab and list-vocab commands#614
Conversation
Codecov Report
@@ Coverage Diff @@
## master #614 +/- ##
==========================================
+ Coverage 99.58% 99.61% +0.02%
==========================================
Files 87 87
Lines 5848 6034 +186
==========================================
+ Hits 5824 6011 +187
+ Misses 24 23 -1
Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here. |
…deprecated loadvoc command from docs
|
SonarCloud Quality Gate failed.
|
juhoinkinen
left a comment
There was a problem hiding this comment.
LGTM
Wiki pages need update to align to these chages too.
Right, many wiki pages (e.g. all the backend pages) show use of the loadvoc command. Also vocabulary id's in example configurations and commands should be edited to remove the language suffixes that are no longer useful. I think it's best to do all the wiki edits synchronized with the 0.59 release. |








This PR adds two new CLI commands,
annif load-vocabandannif list-vocabs. It also deprecates the oldannif loadvoccommand. The main difference betweenload-vocabandloadvocis thatload-vocaboperates directly on the vocabulary and takes a vocabulary ID as argument, whileloadvoctakes a project ID as argument. See #602 for more details on these.Here are examples of running the new commands:
As is apparent, the
load-vocabcommand is more verbose thanloadvocwhich produced little or no output.The new
list-vocabscommand shows some basic information about the vocabularies:The
loadvoccommand now shows a deprecation message (in red color when possible) and has also become slightly more verbose:There are also changes to the CLI commands documentation that is nowadays published on ReadTheDocs (see #611). The section on
loadvoccommand has been deleted, since we don't want to encourage its use. I will file a separate issue on removing theloadvoccommand in a future release, probably 0.60.Fixes #602