Upload with server error 500

第26屆本因坊決賽 林海峰(黑)石田芳夫(白).sgf (1.3 KB)

2 Likes

I wouldn’t have thought it should be an issue, but it may be the Chinese characters.
Please try translating all the fields into English translations (sorry)

Below I put in dummy text in all the fields and it was able to upload.

2 Likes

@anoek pretty big bug here, upload to games library doesn’t have full support for UTF-8 characters

I submited an issue over at GitHub for this.

1 Like

I am not sure the Chinese characters are encoded in UTF-8 (Unicode), maybe GB for simplified Chinese. Now I have 48 Rin Kai Ho’s famous games to upload, it’s time consuming to remove all the Chinese characters.

Note that all of BW-GO, Grid Master, Hectar Go (SGF editors) can open them successfully, but only Hectar Go shows those characters correctly with no garbling.

Sorry about the necromancy, but while I got the error when uploading the file as was, converting it to UTF-8 did the trick. Unless the SGF Library is supposed to handle different encodings, I think we can scratch this one as a bug?

It was Big5. If that’s the case with the other files, converting everything at once should be straightforward. On Linux, it would only take a few lines of code.

Maybe something like this.
mkdir Converted &&
for file in *.sgf;
  do iconv -f big5 -t utf8 "$file" > Converted/"$file";
     sed -i 's/big5/UTF-8/gI' Converted/"$file";
  done

That only takes care of the encoding, though. You may need to invest some extra lines to get everything 100%.

For instance...
  • I had to remove an extra bracket in the game name token (GN[第26屆日本本吒]坊決賽]) before I could open your SGF on CGoban3;

  • After uploading it to OGS, it displayed a win by timeout because the game result info (RE[黑中盤勝]) didn’t follow the SGF standard (e.g. RE[B+R]).

But that, too, can be straightforward if you know what you’re looking for and the way it should be.