Extend TaskDatabaseInterface to include artifact category and data
This will allow tasks to include more useful information in dynamic data that they can't do using only artifact IDs.
Doing this does mean that artifact data is now validated in more places, so it's possible for this to result in new failures for old artifacts. In practice this should mostly affect tests (and indeed I had to fix several of those) since production code normally already goes through some kind of validation of artifact data; if we encounter failures on production then we can decide whether to fix artifacts or relax validation.
Part of #510 (closed).