BrainLesion / tutorials

BrainLes tutotrials
MIT License
9 stars 2 forks source link

Github viewer does not support too long text lines, outputs appear truncated #17

Closed neuronflow closed 1 month ago

neuronflow commented 8 months ago

If a code line becomes too long it cannot be previewed using GitHub's internal viewer. Example: https://github.com/BrainLesion/tutorials/blob/main/AURORA/tutorial.ipynb

We can certainly not change the way GitHub operates (easily, but is there a way we can mitigate this? E.g. by specifying a shorter line character limit in our code formatter? https://github.com/BrainLesion/tutorials/blob/main/AURORA/tutorial.ipynb

Also see: https://stackoverflow.com/questions/75721979/github-jupyter-notebook-cells-are-truncated

MarcelRosier commented 8 months ago

Black already dictates a max line length of 88 characters which is fine, however black does not split comments or notebook outputs which is our issue. Hence, the formatter can not help here.

For comments, we can simply try to limit our self to the code line lengths, for outputs things are not easily solvable. However, every notebook can be opened in Colab which does not have the line restriction so the issue is not as pressing i guess.