react-native-batch-push icon indicating copy to clipboard operation
react-native-batch-push copied to clipboard

build fails on Azure

Open psyzz opened this issue 5 years ago • 7 comments

Hello,

first thank you for the lib,

we use your library and when building on Azure, the build fails with the following error:

Failed find: ENOENT: no such file or directory, stat '/Users/runner/work/1/s/ios/Pods/Batch/Batch.xcframework/ios-arm64_x86_64-maccatalyst/Batch.framework/PrivateHeaders'

When i check the batch SDK folder we can see that the PrivateHeaders is here for the 1.17.3 (and its an alias) but not in the 1.18

Screenshot 2021-11-30 at 17 10 50

We both tried building with Batch 1.18 & 1.17.3.

Locally i can build an archive without any error. Any idea ?

Thank you

xcode 13.1 react-native 0.64.0 "@bam.tech/react-native-batch": "^6.1.0-rc.0"

psyzz avatar Nov 30 '21 16:11 psyzz

Hi,

Did this ever work on the CI with 1.17.3?

From what I see, both 1.17.3 and 1.18.0 have the same architecture: PrivateHeaders is there but is a broken link (there is no PrivateHeaders folder in Versions/A)

I downloaded both the SDK from download.batch.com and cocoapods to confirm this:

Screenshot 2021-11-30 at 18 58 21

I checked our build scripts, and we do not do anything to this folder, so this is Apple's toolchain building the framework that way.

If you don't use Catalyst, I recommend that you try disabling it (set the SUPPORTS_MACCATALYST=NO argument to xcodebuild, or set it as an env var)

If you do, it would be interesting to try either deleting that link or creating its target folder (Versions/A/PrivateHeaders)

Have a nice day,

abarisain avatar Nov 30 '21 18:11 abarisain

Thank you,

using SUPPORTS_MACCATALYST=NO doesn't work for us,

but creating this file works with a : touch ios/Pods/Batch/Batch.xcframework/ios-arm64_x86_64-maccatalyst/Batch.framework/Versions/A/PrivateHeaders

psyzz avatar Dec 03 '21 12:12 psyzz

will you notify the Batch SDK team or i do it by posting an issue on their github ? Thanks

psyzz avatar Dec 03 '21 12:12 psyzz

Thanks for the feedback

I am part of the team, so this has been acknowledged!

That said, I'm not sure what our next steps are, as this is the first report of this since we started shipping a XCFramework. I also checked our build scripts and we're not using nonstandard options: Apple scripts are the one building the framework that way. We also can't reproduce this on our CI-built apps (native, RN, flutter) but we're not using Azure Pipelines.

Still, we've tracked this internally. We'll add additional issue reports when they come.

abarisain avatar Dec 03 '21 12:12 abarisain

Starting with 1.18.1, we will ship the xcframework with an empty "PrivateHeaders" folder.

This should fix the Azure Pipelines issue, even though I was unable to reproduce this on my end (nor did we get other bug reports).

abarisain avatar Dec 17 '21 12:12 abarisain

Batch SDK iOS 1.18.1 is out and should fix this. I believe that this issue can be closed

abarisain avatar Dec 20 '21 16:12 abarisain

Thanks @psyzz and @abarisain for your contribution. I'm closing this issue as Batch released a new version and this repository is being archived.

This should be addressed in https://github.com/BatchLabs/Batch-React-Native-Plugin

marekkalnik avatar Jul 28 '22 09:07 marekkalnik