TXT preview in repository browser not working for some txt files

65 views
Skip to first unread message

Lars Bingchong

unread,
Jul 24, 2015, 7:03:19 AM7/24/15
to Bonobo Git Server
Hi Bonobo Git Server forum,

For some text files we get the following disclaimer when trying to preview the file: "Preview of this file is not supported.". For other text files it works.

The non-working text file has the following attributes:
- Over 100KB (also seen others that were above 40KB)
- The code in the text file is an export to a text file from the C/SIDE client used to develop for the Microsoft Dynamics NAV ERP system.
- The file encoding is ANSI

The following steps have been tried in the troubleshooting process:

- RAW view is not working either: "404 - File or directory not found" is thrown. If I change display to false in the query part of the URI, after having clicked RAW, I can download the file and I can see the content.
- Changing core.CRLF to false, as this is a Windows project and IIS is serving it, unfortunately did not fix it
- Checked that IIS is not blocking text files. It does not. It also works for other text files. Just to make sure.

I have attached an example text file, exported from NAV

I hope I made myself clear in the above and I'm looking forward to hear from you.

Regards Lars Bingchong
BonoboGitte.txt

Jakub Chodounský

unread,
Jul 26, 2015, 6:02:41 AM7/26/15
to Bonobo Git Server, bingch...@gmail.com
This might be related to https://github.com/jakubgarfield/Bonobo-Git-Server/issues/254 and possibly fixed in 4.0.0.

Jakub Chodounský

unread,
Jul 26, 2015, 6:04:55 AM7/26/15
to Bonobo Git Server, bingch...@gmail.com
It is fixed in 4.0.0 as the file is displayed correctly on the demo server http://demo.bonobogitserver.com/Repository/test/master/Blob/BonoboGitte.txt

Lars Bingchong

unread,
Jul 26, 2015, 10:30:45 AM7/26/15
to Bonobo Git Server, bingch...@gmail.com
Hi Jakub,

Thank you for getting back to me :-)

I found the caveat. It's the file encoding. As soon as I converted the text file to UTF8 it worked. For the BonoboGitte.txt file example as well as bigger files (40KB and bigger). I have also tried saving the BonoboGitte text file in ANSI and then it stops working.

As text files is always saved in ANSI pr. default on Windows, could this be made to work somehow? Maybe in a future release? As I would like that the people using the Bonobo Git server, have as easy an workflow when working with Bonobo Git.

Looking forward to your answer and thank you very much.
Kind regards

Lars Bingchong

unread,
Jul 26, 2015, 10:34:03 AM7/26/15
to Bonobo Git Server, bingch...@gmail.com
Forgot to mention that I sure am running v4 of the Bonobo Git Server. Even tried to re-install it now :-)

Jakub Chodounský

unread,
Jul 26, 2015, 11:17:33 AM7/26/15
to Bonobo Git Server, bingch...@gmail.com
Could you provide an example of the file that's broken? The BonoboGitte.txt worked well.

Lars Bingchong

unread,
Jul 26, 2015, 12:31:35 PM7/26/15
to Bonobo Git Server, bingch...@gmail.com
Hi Jakub,

You should be able reproduce the issue if you simply save/convert the BonoboGitte.txt file to use ANSI encoding. I was able to reproduce it for that file by doing exactly that. Let me know how that goes :-D

Lars Bingchong

unread,
Jul 30, 2015, 3:20:37 PM7/30/15
to Bonobo Git Server, bingch...@gmail.com
Have you been able to reproduce it?

Jakub Chodounský

unread,
Aug 4, 2015, 10:01:07 AM8/4/15
to Bonobo Git Server, bingch...@gmail.com
Yes, please raise an issue on github and try to get in touch with lkho, stanshillis and ColinNiu
Reply all
Reply to author
Forward
0 new messages