dotnet / interactive

.NET Interactive combines the power of .NET with many other languages to create notebooks, REPLs, and embedded coding experiences. Share code, explore data, write, and learn across your apps in ways you couldn't before.
MIT License
2.9k stars 389 forks source link

.dib files are not handled as text in Azure DevOps repos #1583

Open gemolnar opened 3 years ago

gemolnar commented 3 years ago

When I commit a .dib file to repo in Azure DevOps it cannot display the file on the web interface. It tries to handle it as a binary file. Can I do anything about it?

Notebooks are great and I try to convince my teammates to use them, but my pull request looks like I'm trying to sneak in some binary bloat.

image

jonsequitur commented 3 years ago

The only workaround I'm aware of at the moment is to use the .ipynb extension. It's not as friendly for diff tools.

We'll likely be adding additional supported file formats in the future.

jhoneill commented 3 years ago

DIB was already in use as a file extension which is why various things think it is a device independent bitmap.

efficienthacks commented 1 year ago

Can someone reach out to the ADO team to get this fixed? I'm starting to check in a lot of .dib Notebook files into ADO and none of it renders correctly

edit: I think I found where to file a bug to the ADO team. Hoping they fix it...

bjanousek commented 1 year ago

@jonsequitur - can you confirm why the .dib is used when that extension is historically reserved for "device independent bitmap"? I'd suggest using the ".dnb" or ".idnb".

On Azure DevOps side we:

So, we'll keep the current handling that is using hardcoded list of extensions that are treated as binary files. We'll not remove the ".dib" extension from that list as it's "device independent bitmap" as already explained above.

jonsequitur commented 1 year ago

We could consider adding support for an alternative file extension for this format.

The decision to use .dib was made early on and we realized there was a file extension conflict only later. We haven't wanted to break backwards compatibility.

ambrose-leung commented 1 year ago

Related, but closed: https://developercommunity.visualstudio.com/t/dotnet-notebook-dib-files-not-shown/10106469?viewtype=all ...

Let's have some discussions to come up with a new extension - maybe .pnb, .pgnb (for PolyGlot NoteBook) which is going to render as text in ADO (and perhaps place a feature request to get them rendered as Notebooks).

johnnyqian commented 7 months ago

As of now, this issue still exists. image