HipByte / motion-appstore

A RubyMotion plugin to provide 'validate' and 'upload' commands for iTunes Connect.
MIT License
52 stars 12 forks source link

Errors when trying to upload #10

Closed andrewhavens closed 8 years ago

andrewhavens commented 8 years ago

I am running into errors while trying to run this on a relatively new computer running El Capitan.

First, motion upload email@example.com had this error:

Transporter not found at path: /usr/local/itms/bin/iTMSTransporter.  You should reinstall the application.

I was able to get past this by symlinking to it's current location:

mkdir -p /usr/local/itms/bin
ln -s /Applications/Xcode.app/Contents/Applications/Application\ Loader.app/Contents/itms/bin/iTMSTransporter /usr/local/itms/bin/iTMSTransporter

The next error was not helpful:

An error occurred uploading to the iTunes Store.

I found the error by tailing /var/log/system.log:

altool[97247]: Error:
    Java 1.6 or higher is required. Please install Java.
    unable to find /usr/local/itms/java/bin/java
altool[97247]: *** Error: Errors uploading './build/iPhoneOS-8.0-Release/MyApp.ipa': (
        "Error Domain=WorkerErrorDomain Code=-10000 \"An error occurred uploading to the iTunes Store.\" UserInfo={NSLocalizedDescription=An error occurred uploading to the iTunes Store., NSLocalizedFailureReason=An error occurred uploading to the iTunes Store.}"
    )

I knew I had Java installed, so I fixed that with another symlink:

mkdir -p /usr/local/itms/java/bin/
ln -s $(which java) /usr/local/itms/java/bin/java

The next error has me stuck:

Could not find or load main class com.apple.transporter.Application

And in the log:

altool[97793]:  Error:
    Error: Could not find or load main class com.apple.transporter.Application
altool[97793]:  Out:
altool[97793]: *** Error: Errors uploading './build/iPhoneOS-8.0-Release/MyApp.ipa': (
        "Error Domain=ITunesTransporterErrorDomain Code=-18000 \"Could not find or load main class com.apple.transporter.Application\" UserInfo={NSLocalizedRecoverySuggestion=Could not find or load main class com.apple.transporter.Application, NSLocalizedDescription=Could not find or load main class com.apple.transporter.Application, NSLocalizedFailureReason=Could not find or load main class com.apple.transporter.Application}"
    )

How can I get past this issue?

Watson1978 commented 8 years ago

I think this is problem of Application Loader.app, not this plugin. You should report to Apple.

andrewhavens commented 8 years ago

I don't think so. I was able to upload using Application Loader without any problem.

Watson1978 commented 8 years ago

This plugin just use Application Loader command line tool. So, I think there is problem in it, I don't know that GUI and command line tool has completely same behavior.

Watson1978 commented 8 years ago

If you will set up /usr/local/itms/bin/iTMSTransporter like below, you might be solve your problem.

ln -s /Applications/Xcode.app/Contents/Applications/Application\ Loader.app/Contents/itms /usr/local/itms

Java binary file is contained in /Applications/Xcode.app/Contents/Applications/Application\ Loader.app/Contents/itms

This is same way in http://stackoverflow.com/questions/28461768/xcode-organizer-trying-to-access-transporter-at-wrong-directory-path