It would be nice to come up with criteria for vdcore loaders.
E.g.:
add-row.This way:
This is an open discussion for the community. =)
Some that come to mind:
This is a great idea. When implemented it should help increase the quality and stability of the code. I've encountered a few breakages that I think might have been caught by basic and standard tests like you are suggesting.
Some that come to mind:
One idea is a have a standardized generic test that can be applied to a fixed dataset. The standardized test would do regular visidata operations, and it could look for expected results. With a standard dataset, the expected results will already be known. This would not take advantage of any specialized features of a given loader or file type, but would make sure the loaded data works with the core of Visidata. This would be a test you could use as part of loader development and might not take much to convert to the new datatype. I'm not sure about the fine details that would make this difficult.
:sleepy:
Thanks @frosencrantz and @ajkerrigan for helping me put together an attribute list!
@frosencrantz My initial instinct was :sleepy: because that feels like a major infrastructure addition and a lot of work.
I do think these lists are useful, and I do agree having automation would be useful. Here are the various levels this can go:
We can see which level we end up going with, based on who works on this, and how much energy they allocate! =)
@anjakefala, I'm glad you are feeling better about this. I like having the spectrum of manual to complete automation. It allows your idea of compatibility chart and testing to move forward over time as effort can be applied.
I added a baby file on dev/loader-compatibility.tsv (which we will definitely possibly rename, I just wanted to get this work started).
Anyone who has the energy can feel free to populate it!
I added all the filetypes and indicated whether they had a loader or a saver and what the requirements are. We should find a place to post this as part of the docs. (visidata.org/formats?) Next we should collect all the current docs about loader internals and combine/review/update them for 2.0. (visidata.org/loaders?)
visidata.org/formats is the perfect place for this :+1:
Next we should collect all the current docs about loader internals and combine/review/update them for 2.0. (visidata.org/loaders?)
I started that work, and have not finished it, yet. we should definitely not forget to finish that.
https://github.com/saulpw/visidata-book/pull/6/files#diff-204f5a19390e8bce4c1fa6c641d1b0a4
We created a basic formats.jsonl where we track information about the loaders we support. This data is also displayed at https://visidata.org/formats.
We decided to not make a checklist of minimal expected behaviour from a loader, because it is pretty hard to define a precise list for everything. I want to encourage loader creation to develop organically alongside usage of the loader, based on how people want to interact with the data.
:bee: