rolinger
rolinger

Reputation: 3058

cordova creating hundreds of Xcode 14 "stale files outside root paths" warnings

After making changes to app code, I compile from CLI using: ionic cordova build ios Then in XCode 14 I deploy my app to a phone or simulator. However, the build from CLI takes 5+ minutes and then in Xcode it takes another 3 minutes to deploy to the device or simulator - this is PPAAIINNFFUULLLLYY slow.

After the CLI build, in XCode I am getting nearly 2500 stale file XXX is outside allowed root paths warnings during the deploy part. I don't know for certain but I feel these stale files are the source of all length build/deploy times. The build is creating 2500 stales files...then the deploy is trying to process them - both creating severe latency just to get my app to run on a device.

I found on other threads that in Xcode a <CMD> + SHIFT + K followed by a <CMD> + SHIFT = R will clean the project and clear out all those stale files. After that, Xcode deploys the app to the device in like 15 seconds - and it works. Great...BBUUTT as soon as I do a build from CLI again, all the stale files return. Not great. :-(

So, the question is, what is causing ionic/cordova build ios to create all these stale files...and more importantly, how can I fix it? I don't know where to begin on this one.

Examples of the stale files:

Stale file '/Users/rpo/dev/myApp/platforms/ios/build/emulator/nanopb.framework' is located outside of the allowed root paths.
Stale file '/Users/rpo/dev/myApp/platforms/ios/build/emulator/nanopb.framework.dSYM/Contents/Resources/DWARF/nanopb' is located outside of the allowed root paths.
Stale file '/Users/rpo/dev/myApp/platforms/ios/build/emulator/nanopb.framework/Headers' is located outside of the allowed root paths.
Stale file '/Users/rpo/dev/myApp/platforms/ios/build/emulator/nanopb.framework/Headers/nanopb-umbrella.h' is located outside of the allowed root paths.
Stale file '/Users/rpo/dev/myApp/platforms/ios/build/emulator/nanopb.framework/Headers/pb.h' is located outside of the allowed root paths.

No kidding....2488 of these warning messages!

Upvotes: 1

Views: 411

Answers (0)

Related Questions