kebernet / shortyz

Shortyz Crosswords
GNU General Public License v3.0
107 stars 56 forks source link

Unable to play old Newsday puzzles (Android Nexus 5) #71

Open icy- opened 7 years ago

icy- commented 7 years ago

I just started to get into crosswords on a regular basis, and November 2016 seems to be working fine. October 1st-6th seems ok too.

Problem occurred when I tried to download Newsday from Jan 1st 2016. It seemed to "download", but without a witty caption/title. Opening this puzzle causes Shortyz to crash. I tried Feb 1st, March 1st, April 1st... etc. all through September 1st, 2016. All of these Newsday puzzles are missing captions and upon opening cause program to crash.

Hopefully someone with this repo checked out is able to quickly see what it is that's causing corrupt downloads. Not sure if this is affecting crosswords not from Newsday.

gaul commented 7 years ago

I reproduced the symptoms; here is the stack trace:

java.lang.RuntimeException: Unable to start activity ComponentInfo{com.totsp.crossword.shortyz/com.totsp.crossword.PlayActivity}: java.lang.ArrayIndexOutOfBoundsException: length=0; index=0
       at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2416)
       at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2476)
       at android.app.ActivityThread.-wrap11(ActivityThread.java)
       at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1344)
       at android.os.Handler.dispatchMessage(Handler.java:102)
       at android.os.Looper.loop(Looper.java:148)       
       at android.app.ActivityThread.main(ActivityThread.java:5417)
       at java.lang.reflect.Method.invoke(Native Method)
       at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:726)
       at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:616)
Caused by: java.lang.ArrayIndexOutOfBoundsException: length=0; index=0
       at com.totsp.crossword.puz.Playboard.<init>(Playboard.java:30)
       at com.totsp.crossword.puz.Playboard.<init>(Playboard.java:23)
       at com.totsp.crossword.PlayActivity.onCreate(PlayActivity.java:226)
       at android.app.Activity.performCreate(Activity.java:6251)
       at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1107)
       at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2369)
       ... 9 more
gaul commented 7 years ago

It appears that the server is broken:

$ curl --silent 'http://brainsonly.com/servlets-newsday-crossword/newsdaycrossword?date=160101' | grep .
ARCHIVE
0
0
0
0

Shortyz should flag this as invalid due to a bad checksum but does not.