Xcode 11.2 beta tvOS adhoc export failing

the latest xcode 11.2 beta fail to export tvOS adhoc distribution in xcode UI or xcodebuild, appstore works.



xcodebuild[18094:11579909] [MT] IDEDistribution: -[IDEDistributionLogging _createLoggingBundleAtPath:]: Created bundle at path '/var/folders/w8/19cq3b653sb3ybqk0tsc38hh0000gn/T/***_2019-10-08_14-49-17.541.xcdistributionlogs'.

error: exportArchive: ipatool failed with an exception: #<RuntimeError: Unknown UIDeviceFamily: '5' from '["3", "5"]'>

/Applications/Xcode-beta.app/Contents/Developer/usr/bin/ipatool:3223:in `block in assetutil_idioms_for_UIDeviceFamily'

/Applications/Xcode-beta.app/Contents/Developer/usr/bin/ipatool:3212:in `map'

/Applications/Xcode-beta.app/Contents/Developer/usr/bin/ipatool:3212:in `assetutil_idioms_for_UIDeviceFamily'

/Applications/Xcode-beta.app/Contents/Developer/usr/bin/ipatool:1520:in `block in supportedIdioms'

/Applications/Xcode-beta.app/Contents/Developer/usr/bin/ipatool:1521:in `supportedIdioms'

/Applications/Xcode-beta.app/Contents/Developer/usr/bin/ipatool:2229:in `ValidatePayloadBundle'

/Applications/Xcode-beta.app/Contents/Developer/usr/bin/ipatool:2265:in `block in ValidatePayloadBundle'

/Applications/Xcode-beta.app/Contents/Developer/usr/bin/ipatool:2264:in `each'

/Applications/Xcode-beta.app/Contents/Developer/usr/bin/ipatool:2264:in `ValidatePayloadBundle'

/Applications/Xcode-beta.app/Contents/Developer/usr/bin/ipatool:2202:in `ValidateIPA'

/Applications/Xcode-beta.app/Contents/Developer/usr/bin/ipatool:2871:in `block in ProcessIPA'

/Applications/Xcode-beta.app/Contents/Developer/usr/bin/ipatool:2864:in `each'

/Applications/Xcode-beta.app/Contents/Developer/usr/bin/ipatool:2864:in `ProcessIPA'

/Applications/Xcode-beta.app/Contents/Developer/usr/bin/ipatool:3811:in `<main>'

We've got the same issue with XCode Version 11.2.1 (11B500)!


ipatool failed with an exception: #
    /Applications/Xcode.app/Contents/Developer/usr/bin/ipatool:3223:in `block in assetutil_idioms_for_UIDeviceFamily'
    /Applications/Xcode.app/Contents/Developer/usr/bin/ipatool:3212:in `map'
    /Applications/Xcode.app/Contents/Developer/usr/bin/ipatool:3212:in `assetutil_idioms_for_UIDeviceFamily'
    /Applications/Xcode.app/Contents/Developer/usr/bin/ipatool:1520:in `block in supportedIdioms'
    /Applications/Xcode.app/Contents/Developer/usr/bin/ipatool:1521:in `supportedIdioms'
    /Applications/Xcode.app/Contents/Developer/usr/bin/ipatool:2229:in `ValidatePayloadBundle'
    /Applications/Xcode.app/Contents/Developer/usr/bin/ipatool:2265:in `block in ValidatePayloadBundle'
    /Applications/Xcode.app/Contents/Developer/usr/bin/ipatool:2264:in `each'
    /Applications/Xcode.app/Contents/Developer/usr/bin/ipatool:2264:in `ValidatePayloadBundle'
    /Applications/Xcode.app/Contents/Developer/usr/bin/ipatool:2202:in `ValidateIPA'
    /Applications/Xcode.app/Contents/Developer/usr/bin/ipatool:2871:in `block in ProcessIPA'
    /Applications/Xcode.app/Contents/Developer/usr/bin/ipatool:2864:in `each'

Did anybody figure this out?

I'm getting this with Xcode 11.3 now, did you find the issue?

I've fixed it by adding:

//:configuration = Debug
TARGETED_DEVICE_FAMILY = 3


//:configuration = Release
TARGETED_DEVICE_FAMILY = 3


//:completeSettings = some
TARGETED_DEVICE_FAMILY


to the Build Settings tab of my tvOS dynamic framework.


Try looking what is the value for TARGETED_DEVICE_FAMILY in your build settings.

One of your dependency has UIDeviceFamily ['3', '5'] in it's Info.plist, remove '5' from the Info.plist can solve this issue.

More debug info:

modify /Applications/Xcode.app/Contents/Developer/usr/bin/ipatool

add below line (line 1599) can help print out which dependency libraries has incorrect ['3', '5'] in it's Info.plist

Code Block ruby
1595 def supportedIdioms
1596 if not defined? @supportedIdioms
1597 @supportedIdioms = lambda {
1598 family = infoDict["UIDeviceFamily"]
1599 $stderr.puts "debug family '#{family}' '#{infoDict}'"


Xcode 11.2 beta tvOS adhoc export failing
 
 
Q