Simbul / baker

The HTML5 ebook framework to publish interactive books & magazines on iPad & iPhone using simply open web standards
http://bakerframework.com
1.53k stars 378 forks source link

'Could not open issue' error #1034

Open callaght opened 11 years ago

callaght commented 11 years ago

When I execute Baker from xCode, my iPad is constantly connected via USB. This the means Baker is always open and the iPad does not go into sleep mode.

If I download my approx 150mb hpub, Baker will always be open and visible on my iPad, even when I leave it to download for about 10 mins. My Magazine will always open successfully and everything works fine: -

img_0063

However, when I: -

  1. Delete Baker off my iPad
  2. Rebuild and Execute Baker on my iPad
  3. Do not purchasing or downloading anything
  4. Stop xCode/Baker
  5. Disconnect iPad USB cable

Now, when I try to download my Magazine hpub purchase the download begin as normal. But after a few mins, my iPad will switch off into sleep mode

When I switch my iPad back on, from sleep mode, the download is sometimes complete by that point, or I have wait a little longer for the hpib download to complete

Now, if I tap the READ button I always get this error: -

img_0062

Is this down to my book.json or shelf.json file not being configured correctly?

The only pattern I can recognise is: its ok, unless the iPad goes into sleep mode during the download.

folletto commented 11 years ago

It should have been fixed with #876... did you try the latest master?

callaght commented 11 years ago

I have downloaded what I think is the master - this link?: -

http://bakerframework.com/down/baker-framework-4.1.zip

Repeated all of the above steps but still get 'Could not open issue error' dialog.

fturner19 commented 11 years ago

@callaght - I had this same issue with one of my magazine. My problem was with my "shelf.json" file, so I would start checking there to make sure there's no errors with coding the shelf.json!

callaght commented 11 years ago

Good point fturner19 - I've now run it through JSONLint.com and it says 'Valid JSON'

Can anyone see anything that could be wrong with my shelf.json? : -

[
  {
    "name": "slapshot-issue-1",
    "title": "Slapshot Issue 1",
    "info": "Slapshot is a magazine about all things Ice Hockey for Apple Newsstand.",
    "date": "2013-06-06 10:10:10",
    "cover": "https://s3-us-east-2.amazonaws.com/and/so.on.png",
    "url": "https://s3-us-east-2.amazonaws.com/on/so/on.hpub",
    "product_id": "com.suncat.icehockeymag.august.2013"
  } 
]
callaght commented 11 years ago

This is where I got todays copy of Baker SDK from, http://bakerframework.com: -

screen shot 2013-07-19 at 19 34 52

Is that the correct place to go to get a latest, master Baker SDK?

tekdope commented 11 years ago

Since you're using S3, did you make the Hpub public?

Le 19 juil. 2013 à 11:29, callaght notifications@github.com a écrit :

Good point fturner19 - I've now run it through JSONLint.com and it says 'Valid JSON'

Can anyone see anything that could be wrong with my shelf.json? : -

[ { "name": "slapshot-issue-1", "title": "Slapshot Issue 1", "info": "Slapshot is a magazine about all things Ice Hockey for Apple Newsstand.", "date": "2013-06-06 10:10:10", "cover": "https://s3-us-east-2.amazonaws.com/and/so.on.png", "url": "https://s3-us-east-2.amazonaws.com/on/so/on.hpub", "product_id": "com.suncat.icehockeymag.august.2013" } ]

— Reply to this email directly or view it on GitHub.

tekdope commented 11 years ago

How do you zip your files?

If you zip the folder you will have this error. Select all the files of your issue and zip them with click right.

nin9creative commented 11 years ago

Is the file public?  I can't open it in my browser.

https://s3-us-east-2.amazonaws.com/on/so/on.hpub

Andrew

callaght commented 11 years ago

Hi tekdope,

Yep, made the Hpub public on S3 and this is how I zip the files: -

screen shot 2013-07-19 at 22 34 23

Once it creates Archive.zip I rename it to mag.hpub

When I execute Baker from xCode and my iPad is constantly connected via USB and does not go into sleep mode, the Hpub downloads and opens.

It seems to be when not connected to a power source and the iPad goes into sleep mode during the download that I get the 'Could not open issue' error.

callaght commented 11 years ago

Hi nin9creative,

I obfuscated: -

 "cover": "https://s3-us-east-2.amazonaws.com/and/so.on.png",
 "url": "https://s3-us-east-2.amazonaws.com/on/so/on.hpub",
 "product_id": "com.suncat.icehockeymag.august.2013"

I made up those values, to post on here.

I thought its best practice to not reveal that info - I have no idea why I think that! :-)

If it makes no difference, then I'm more than happy to post the correct cover, url and product_id values (it seems it could help troubleshoot issue maybe?)

folletto commented 11 years ago

Is that the correct place to go to get a latest, master Baker SDK?

I'm sorry, I didn't explain the terminology. By "Master" we define the latest, untested version here on GitHub (click on top and download the zip or git from here). This version will be released once the feature we want are going to be in and we do enough testing. For comparison, the version on the website is referred with its version. So, "master" is from here, while "4.1" is from the website. :)

In master we should already have fixed the issue. Try it out. :)

callaght commented 11 years ago

Is this Master here: -

screen shot 2013-07-19 at 22 51 23

If so, do I click on the bottom right hand button 'Download ZIP' to get it?

fturner19 commented 11 years ago

@callaght - Yep just click the download ZIP button and you'll have the lasted version of the Baker/Master

callaght commented 11 years ago

Brilliant, thanks. Ok, downloaded Master, but have now hit a new problem once I execute Baker it crashes and I get this at the console: -

2013-07-19 23:21:13.623 Baker[19203:707] ====== Baker Newsstand Mode enabled ====== 2013-07-19 23:21:14.444 Baker[19203:707] [AppDelegate] My token (as NSData) is: <341301bc 6a128b82 ba98e3fe 7c9b1177 2f7f5c69 f8c0cd87 82dff426 fd6837a2> 2013-07-19 23:21:14.450 Baker[19203:707] [AppDelegate] My token (as NSString) is: 341301bc6a128b82ba98e3fe7c9b11772f7f5c69f8c0cd8782dff426fd6837a2 2013-07-19 23:21:15.282 Baker[19203:707] [BakerShelf] Newsstand - Added Slapshot-Mag-August 2013-05-24 16:41:18 +0000 2013-07-19 23:21:15.289 Baker[19203:707] +[NSIndexPath indexPathForItem:inSection:]: unrecognized selector sent to class 0x3f638cb4 2013-07-19 23:21:15.302 Baker[19203:707] * Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '+[NSIndexPath indexPathForItem:inSection:]: unrecognized selector sent to class 0x3f638cb4' * First throw call stack: (0x35cc288f 0x338e6259 0x35cc592f 0x35cc4915 0x35c1f650 0xa2b57 0x35cb6631 0x35c1bed5 0xa2655 0xa2271 0xaed27 0xaf343 0xbcdd9 0x3405bb2b 0x3405ae91 0x35c952ad 0x35c184a5 0x35c1836d 0x339b3439 0x333f0cd5 0x82e93 0x82e20) terminate called throwing an exception

Has anyone seen this with the new Master?

tekdope commented 11 years ago

https://s3-us-east-2.amazonaws.com/and/so.on.png https://s3-us-east-2.amazonaws.com/on/so/on.hpub

i know you made up these URLs but did you make a test with the real ones in safari to see if you can reach the .hpub through the browser ?

Regarding the master, i didn't encounter any problems. Did you change other things than link to shelf ?

callaght commented 11 years ago

Hi tekdope, I've now tested with the real url's in Safari and everything seems fine. The Hpub side of things seems ok.

Having real problems with the Master though. If I execute the Master on the Simulator it runs fine. If I then execute it on the iPad I get this error: -

2013-07-21 19:10:07.397 Baker[19809:707] ====== Baker Newsstand Mode enabled ====== 2013-07-21 19:10:08.083 Baker[19809:707] [AppDelegate] My token (as NSData) is: <341301bc 6a128b82 ba98e3fe 7c9b1177 2f7f5c69 f8c0cd87 82dff426 fd6837a2> 2013-07-21 19:10:08.088 Baker[19809:707] [AppDelegate] My token (as NSString) is: 341bc6a128b82ba98e3fe7c9b11772f7f5c69f8c0cd8782dff426fd6837a2 2013-07-21 19:10:09.047 Baker[19809:707] +[NSIndexPath indexPathForItem:inSection:]: unrecognized selector sent to class 0x3f638cb4 2013-07-21 19:10:09.050 Baker[19809:707] * Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '+[NSIndexPath indexPathForItem:inSection:]: unrecognized selector sent to class 0x3f638cb4' * First throw call stack: (0x35cc288f 0x338e6259 0x35cc592f 0x35cc4915 0x35c1f650 0x52d27 0x35cb6631 0x35c1bed5 0x52825 0x52441 0x5eec3 0x5f4df 0x6cf05 0x3405bb2b 0x3405ae91 0x35c952ad 0x35c184a5 0x35c1836d 0x339b3439 0x333f0cd5 0x3308b 0x33018) terminate called throwing an exception(lldb)

The only change I made was to use my Bundle Identifier in the plist and change all the Code Signing Identities to mine.

Has anyone come across a similar issue?

callaght commented 11 years ago

I thought I'd screenshot every change I made to fully document how I'm getting the error with Master.

  1. Download the Master from here: -

screen shot 2013-07-21 at 20 28 15

  1. Change the Bundle indentifier in the plist: -

screen shot 2013-07-21 at 20 30 00

  1. Change the deployment target to 5.1 (My iPad 1 will only upgrade to iOS 5.1.1): -

screen shot 2013-07-21 at 20 30 32

  1. Change all the Code Signing Identities: -

screen shot 2013-07-21 at 20 30 59 screen shot 2013-07-21 at 20 31 22

  1. Execute in simulator and it runs fine, console output below for fullness: -

screen shot 2013-07-21 at 20 32 17

2013-07-21 20:32:06.938 Baker[33459:c07] ====== Baker Newsstand Mode enabled ====== 2013-07-21 20:32:06.994 Baker[33459:c07] [AppDelegate] Push Notification - Device Token, review: Error Domain=NSCocoaErrorDomain Code=3010 "remote notifications are not supported in the simulator" UserInfo=0xa560830 {NSLocalizedDescription=remote notifications are not supported in the simulator}

  1. Execute on iPad - app crashes: -

screen shot 2013-07-21 at 20 33 11

2013-07-21 20:28:42.157 Baker[19948:707] ====== Baker Newsstand Mode enabled ====== 2013-07-21 20:28:43.015 Baker[19948:707] [AppDelegate] My token (as NSData) is: <341301bc 6a128b82 ba98e3fe 7c9b1177 2f7f5c69 f8c0cd87 82dff426 fd6837a2> 2013-07-21 20:28:43.018 Baker[19948:707] [AppDelegate] My token (as NSString) is: 341301bc6a128b82ba98e3fe7c9b11772f7f5c69f8c0cd8782dff426fd6837a2 2013-07-21 20:28:49.917 Baker[19948:707] [BakerShelf] Newsstand - Added a-study-in-scarlet 1887-11-24 09:00:00 +0000 2013-07-21 20:28:49.929 Baker[19948:707] [BakerShelf] Newsstand - Added baker-framework-tutorial 2013-01-25 13:01:25 +0000 2013-07-21 20:28:49.940 Baker[19948:707] +[NSIndexPath indexPathForItem:inSection:]: unrecognized selector sent to class 0x3f638cb4 2013-07-21 20:28:49.944 Baker[19948:707] * Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '+[NSIndexPath indexPathForItem:inSection:]: unrecognized selector sent to class 0x3f638cb4' * First throw call stack: (0x35cc288f 0x338e6259 0x35cc592f 0x35cc4915 0x35c1f650 0x11fd1f 0x35cb6631 0x35c1bed5 0x11f81d 0x11f439 0x12bebb 0x12c4d7 0x139efd 0x3405bb2b 0x3405ae91 0x35c952ad 0x35c184a5 0x35c1836d 0x339b3439 0x333f0cd5 0x100083 0x100010) terminate called throwing an exception(lldb)

Did I take any incorrect steps for this to happen?

folletto commented 11 years ago

Here's your problem:

"Change the deployment target to 5.1 (My iPad 1 will only upgrade to iOS 5.1.1):"

Baker is designed to work with the deployment target set. It's not just a flag, it defines pretty much the foundation upon which the code is developed. Downgrading the deployment target has the same impact of removing a library: it won't work.

In short: the next version of Baker will support just iOS 6.0 and above. You can't change the deployment target.

callaght commented 11 years ago

ah ok, cool. That makes sense.

So this means that Baker does not work on iPad 1?

Time for a shopping trip to the Apple store! :-)

folletto commented 11 years ago

Exactly. The usage of iOS 5.x has fallen to a minimal percentage and it was slowing down a lot development, so from the next version we will support just 6.0+ (that includes clearly 7.0). :)

callaght commented 11 years ago

Thanks for your help folletto

folletto commented 11 years ago

You're welcome. Let us know if it solves the issue if you're able to test. :)