simonnilsson / ios-uploader

Easy to use, cross-platform tool to upload iOS apps to App Store Connect.
MIT License
169 stars 27 forks source link

feat: improve error logging #3

Closed Badisi closed 4 years ago

Badisi commented 4 years ago

Improvement

While using your package I encountered an error with the metadata validation:

Metadata validation failed!

As it was not enough relevant for me, I had to log res.data.result.ErrorMessage for a better understanding.

I think it could help others not to throw your own error message but instead throw or include the real error returned from a request 😉


As a side note, the error I had was :

ERROR ITMS-3000: "Line 7 column 51: character content of element "file_name" invalid; must be a string matching the regular expression "[^/: ]+" at XPath /package/software_assets/asset/data_file/file_name"

And in fact my binary path contains spaces : "/platforms/ios/build/device/app - DEV.ipa".

Do you have any idea why it's happening whereas it's working fine with altool ?

Thanks!

simonnilsson commented 4 years ago

I totally agree, better error reporting is something I also had planned to implement.


As for the error, it might be that altool does some automatic sanitation on the input file path. Should be possible to implement something similar.

simonnilsson commented 4 years ago

Both of these issues should now be solved. Will go live with the next update. 😄

Badisi commented 4 years ago

Well done 🎉 Thanks !