Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

EOFException when reading DataInputStream #8

Open
cunger opened this issue Jan 4, 2017 · 0 comments
Open

EOFException when reading DataInputStream #8

cunger opened this issue Jan 4, 2017 · 0 comments

Comments

@cunger
Copy link

cunger commented Jan 4, 2017

When trying to read a PGF file using PGFReader.fromFile("path/to/file.pgf"), I get the following exception:

java.io.EOFException
	at java.io.DataInputStream.readFully(DataInputStream.java:197)
	at java.io.DataInputStream.readLong(DataInputStream.java:416)
	at java.io.DataInputStream.readDouble(DataInputStream.java:468)
	at org.grammaticalframework.PGFReader.getDouble(PGFBuilder.java:854)
	at org.grammaticalframework.PGFReader.getListWeightedIdent(PGFBuilder.java:811)
	at org.grammaticalframework.PGFReader.getAbsCat(PGFBuilder.java:233)
	at org.grammaticalframework.PGFReader.getListAbsCat(PGFBuilder.java:258)
	at org.grammaticalframework.PGFReader.getAbstract(PGFBuilder.java:192)
	at org.grammaticalframework.PGFReader.readPGF(PGFBuilder.java:116)
	at org.grammaticalframework.PGFBuilder.fromFile(PGFBuilder.java:33)

Does this have something to do with handling the EOF exception in the input stream reader?

(I actually used the .jar provided in the PhraseDroid project; is this up to date? The PGF file itself is fine, the GF shell can load it without problems.)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant