I’m trying to send my codea game to the app store, through xcode 7.1 (beta) connected to an iOS9.1 (beta as well), and I get this error:
Unexpected asset pack at /AssetPacks/Dropbox.assetpack. Asset packs must be in /OnDemandResources.
This refers to the new app thining thing from Apple…
Has anyone had this problem yet? Is there a way around it?
I cross-posted to Stack Overflow: http://stackoverflow.com/questions/32572065/ios9s-asset-packs-must-be-in-ondemandresources-error I’ll put a bounty tomorrow if none of us knows how to fix this…
I know it’s not a solution but…
Given that iOS9 / XCode 7.1 isn’t the required baseline for now - can’t you submit using an earlier version?
@Rodolphe I received these days this e-mail from Apple:
To prepare, build your apps using Xcode 7 GM seed, and test with the GM seeds of iOS 9, OS X El Capitan, and watchOS 2. Read the App Review Guidelines and use TestFlight to get feedback before submitting to the App Store.
Try using Xcode 7 GM seed
I’ll try! I need to downgrade first, this may take forever… thanks!
Ok… same thing with iOS 9GM and Xcode 7GM
Has anyone tried to send a build to itunes connect yet?
I’m still unable to send my update to itunes connect… Am I the only one here?
Here’s what I get when I try and send my app from Xcode:
Ooooooh, so apparently, when I move my Codea-made “AssetPacks” folder and its content to “Images.xcassets”, and then delete the old “AssetPacks” folder, the error is gone.
Although, now, obviously, none of my images are found in game…
I used to access my image like this (for a file called im4.png in a Dropbox sub-folder of the AssetPacks folder):
image1 = readImage("Dropbox:im4")
Any idea what’s the new address location of the files in “images.xcassets”? Or, rather, how to find this address?
Thanks! (I think I’m getting a little closer)
@Rodolphe you can use
os.getenv("HOME") to find the path of items
outside the standard folders with file extensions not recognised by
readText. You could try
os.getenv("HOME").."/Images.xcassets/" (just a guess). I’ve done this to open text files with
io.open. I’m not sure how you open an image with the
io library though.
This is the path to the Dropbox:
os.getenv("HOME").."/Documents/Dropbox.assetpack/". So perhaps also try
I still can’t access the files for now, but I’m a little more optimistic
Here’s where the image files are:
And here’s how I try accessing them
fond1 = readImage(os.getenv("HOME").."/Documents/Images.xcassets/AssetPacks/Dropbox:bg4")
Which doesn’t work, as
According to the documentation, readImage only works for official asset packs (a bit annoying).
First though, you should check whether you have the path correct. Here’s an example using Dropbox (obviously change the file name to an image in your Dropbox). If the path is correct, it returns the length of the file in bytes (don’t forget to add the file extension to the path string):
img1 = readImage("Dropbox:Open Square Path Grass")
path = os.getenv("HOME").."/Documents/Dropbox.assetpack/Open Square Path Grass.jpg"
local file, err = io.open(path, "rb")
if file then
Then, once you’re certain you have the right path, we need to work out a way to read the image.
Tbh though, I have no idea how to actually convert the data into a usable image. I’ve only used this method for text-based files. I’m not sure whether it’s possible. Hopefully the geniuses of the list might be able to come up with something.
Have you checked whether you have this issue for assets in locations other than Dropbox (Documents: or Project:)? Although moving all your assets would be a massive pain at first, it might be easier in the long run? But maybe just do a small text export first, ie a tiny program that loads an image from each location Dropbox: Documents: & Project: and see whether all of them throw up this issue.
In the path you posted, the colon should be a /
I just noticed that my Xcode had updated to v7.0 (I really should turn off background-updating).
And I can confirm that for the first time, you don’t need a paid dev account to install your apps on your other devices!
I just tried building a Codea project with lots of Dropbox image and text assets, and loading it onto my iPhone 4S (iOS 9), and it worked great. First time I’ve seen my app on a phone (apart from the simulator on the Mac, which doesn’t count). Man, it is such a great feeling seeing your Codea app on an iPhone.
My assets are in
I did get that bitcode error that you discussed here http://codea.io/talk/discussion/6874/solved-problems-with-xcode#latest
@Rodolphe your fix worked, thanks for that.
The target was iOS 7.0 (I didn’t try 9.0).
I’ve not been able to replicate the issue you’ve been having, I’m afraid.
I’m still pretty new to XCode and don’t really know much about it, @Rodolphe is there a particular reason why you need to make the build target 9.0? Do you still have the issue with the target at 7.0?
I’m not sure that
Images.xcassets is really where you should be putting your Codea assets though. It’s for things like the app icon and launch images.
If I were you I’d re-export from Codea and start over.
Wow, thanks for trying all that @yojimbo2000!
Loading to a local machine works great indeed (I had that moment too the first time I tried :D)!
The issue comes up when you archive your project (Product → Archive), then select Validate. Have you tried that?
@Rodolphe and @yojimbo2000 , the
Deployment Target is the the minimum system requirement.
If you put 9.0, just iPhone/iPod touch/iPad with iOS 9.0 or later can install the app on device