[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [computer-go] Need for more robust SGF Readers
Marco Scheurer wrote:
> > Could you all please test this file with your parsers and tell my what
> > I did
> > wrong (if any), and try to get your parsers not to choke on it? It
> > would be
> > nice if they all would support the official SGF standard..
>
> Indeed...
>
> The file seems to begin with 3 illegal bytes, which does not look good
> for a text file.
Well, you should just skip such junk. For instance, game servers send
SGF game records in e-mail messages (at least NNGS) and it is convenient
not to bother with headers etc. and just store complete message and then
load it into a program without any editing.
Frank de Groot wrote:
> > My program Quarry (http://home.gna.org/quarry/) seems to read it, though
> > I cannot say for sure, since it doesn't support any codepages yet, not
> > even UTF-8.
>
> It should show 5 moves, and a few text fields..
The moves and a comment survive just fine (i.e when read and written into
another file). The RT[] properties are OK too (as seen by manual check of
output). Can say nothing about other properties, Quarry doesn't display
much yet (but they must be preserved). At least better then most others ;p
> > However, when I read and then saved your file, all the
> > properties seemed to have survived. Can you provide a similar test
> > with only ASCII characters?
>
> I am not sure what you mean..
> The object of this test was to test compressed stuff, so they will be beyond
> ASCII, as they will have their msb set. It is not really a violation of the
> SGF standard, because text & simpletext can be in the charset the CA
> property specifies.
As I mentioned, Quarry doesn't support CA[] yet, so I'd like to test with
a file that doesn't try to stress missing code. But that doesn't really
matter a lot, I have more important things to work on.
Paul
_______________________________________________
computer-go mailing list
computer-go@xxxxxxxxxxxxxxxxx
http://www.computer-go.org/mailman/listinfo/computer-go/