bids-standard / bids-specification

Brain Imaging Data Structure (BIDS) Specification
https://bids-specification.readthedocs.io/
Creative Commons Attribution 4.0 International
264 stars 154 forks source link

ENH: Render code blocks with language "tsv" as tables #1794

Open effigies opened 2 months ago

effigies commented 2 months ago

This is another go at https://github.com/bids-standard/bids-specification/issues/644 along the lines of https://github.com/bids-standard/bids-specification/pull/1783#issuecomment-2062890572.

It's not working 100% for me, but I've maxed out my time on this. Pushed to upstream so others can take it up or open PRs against it.

The code for this does not need to live in bidsschematools, but that's the quickest way to get something into the import namespace.

cc @Remi-Gau

effigies commented 2 months ago

Does not render for:

image

Does render, but with inserted None for:

image

Similarly successful but with additional None for the other files. The first one might be an effect of using it twice in a file? The two bugs may be related. I think the problem is probably upstream.

Remi-Gau commented 2 months ago

that's way quicker than anything I would have done

I can try tweaking this to see if I can make it work

effigies commented 2 months ago

FWIW I think this is not an exclude-from-changelog contribution, as it affects how to interpret what's seen in the spec.

Remi-Gau commented 2 months ago

FWIW I think this is not an exclude-from-changelog contribution, as it affects how to interpret what's seen in the spec.

that's fair