Using Xcode 12 beta 6, compiling for an iOS Simulator running iOS 14, the app cannot compile when the Parse pod is installed.
pod init then modify the Podfile to containsource 'https://github.com/CocoaPods/Specs.git'
# Uncomment the next line to define a global platform for your project
platform :ios, '11.0'
target 'parse-ios14-example' do
# Comment the next line if you don't want to use dynamic frameworks
use_frameworks!
# Pods for parse-ios14-example
pod 'Parse', '1.18.0', :modular_headers => true
end
pod install to install the pods, then open the newly created workspace instead of the projectThe simulator launches an empty app
The compiler terminates with an error in ParseClientConfiguration.m:129: Incompatible block pointer types sending 'void (^)(ParseClientConfiguration *__strong)' to parameter of type 'void (^ _Nonnull)(id<ParseMutableClientConfiguration> _Nonnull __strong)'
Full log:
/Users/julianvogels/Developer/parse-ios14-example/Pods/Parse/Parse/Parse/ParseClientConfiguration.m:129:61: error: incompatible block pointer types sending 'void (^)(ParseClientConfiguration *__strong)' to parameter of type 'void (^ _Nonnull)(id<ParseMutableClientConfiguration> _Nonnull __strong)'
return [ParseClientConfiguration configurationWithBlock:^(ParseClientConfiguration *configuration) {
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from /Users/julianvogels/Developer/parse-ios14-example/Pods/Parse/Parse/Parse/ParseClientConfiguration.m:10:
/Users/julianvogels/Developer/parse-ios14-example/Pods/Parse/Parse/Parse/ParseClientConfiguration.h:208:101: note: passing argument to parameter 'configurationBlock' here
+ (instancetype)configurationWithBlock:(void (^)(id<ParseMutableClientConfiguration> configuration))configurationBlock;
^
1 error generated.
Example project: parse-ios14-example.zip
Thanks for the detailed issue but this is a duplicate of #1526, the issue was fixed by #1527 which has been merged into the master branch. Whilst you wait for the next release you could switch your podfile to the master branch.
Thanks for having a look @TomWFox! I tried switching my Podfile to the master branch. It worked, but I am also using ParseLiveQuery 2.7.1, which depends on Parse iOS SDK version 1.18.0, so the pod install fails. Guess I'll have to wait for the release.
Hmm I feel like there should be a way round that but I'm not enough of a cocoapods expert to know! The team are trying to get a release out ASAP so hopefully it will be available on cocoapods in a few days.
@julianvogels You can pod install the current version of Parse. When it fails to compile, go to ParseClientConfiguration.m and in the last function "copyWithZone", replace everything inside the function with this, at least until it gets updated.
ParseClientConfiguration *const configuration = [[ParseClientConfiguration alloc] initEmpty];
if (!configuration) return nil;
// Use direct assignment to skip over all of the assertions that may fail if we're not fully initialized yet.
configuration->_applicationId = [self->_applicationId copy];
configuration->_clientKey = [self->_clientKey copy];
configuration->_server = [self.server copy];
configuration->_fileUploadController = self->_fileUploadController;
configuration->_localDatastoreEnabled = self->_localDatastoreEnabled;
configuration->_applicationGroupIdentifier = [self->_applicationGroupIdentifier copy];
configuration->_containingApplicationBundleIdentifier = [self->_containingApplicationBundleIdentifier copy];
configuration->_networkRetryAttempts = self->_networkRetryAttempts;
configuration->_URLSessionConfiguration = self->_URLSessionConfiguration;
return configuration;
@thefishstick thank you! you just saved me hours for the very old project I'm working on now
@julianvogels I have the same problem? Did you find a solution?
@JulienLevallois since ParseLiveQuery 2.7.2 was released to CocoaPods, the issue vanished. Try pod outdated to see if there are more up-to-date versions of the Parse and ParseLiveQuery pods available and use those.
Most helpful comment
@julianvogels You can pod install the current version of Parse. When it fails to compile, go to ParseClientConfiguration.m and in the last function "copyWithZone", replace everything inside the function with this, at least until it gets updated.
ParseClientConfiguration *const configuration = [[ParseClientConfiguration alloc] initEmpty];
if (!configuration) return nil;
// Use direct assignment to skip over all of the assertions that may fail if we're not fully initialized yet.
configuration->_applicationId = [self->_applicationId copy];
configuration->_clientKey = [self->_clientKey copy];
configuration->_server = [self.server copy];
configuration->_fileUploadController = self->_fileUploadController;
configuration->_localDatastoreEnabled = self->_localDatastoreEnabled;
configuration->_applicationGroupIdentifier = [self->_applicationGroupIdentifier copy];
configuration->_containingApplicationBundleIdentifier = [self->_containingApplicationBundleIdentifier copy];
configuration->_networkRetryAttempts = self->_networkRetryAttempts;
configuration->_URLSessionConfiguration = self->_URLSessionConfiguration;
return configuration;