achorein / expo-share-intent

🚀 Simple share intent in an Expo Native Module
MIT License
177 stars 15 forks source link

expo prebuild fails (only for iOS) #101

Closed Nantris closed 1 month ago

Nantris commented 1 month ago

Describe the bug First, thank you for the amazing project!

EAS builds are failing with:

yarn run v1.22.21
$ /Users/expo/workingdir/build/node_modules/.bin/expo prebuild --no-install --platform ios
- Creating native directory (./ios)
✔ Created native directory
- Updating package.json
✔ Updated package.json | no changes
- Running prebuild
[expo-share-intent] add ios share extension (scheme:myappscheme appIdentifier:com.example.myapp)
✖ Prebuild failed
TypeError: [ios.xcodeproj]: withIosXcodeprojBaseMod: Cannot read properties of null (reading 'path')
TypeError: [ios.xcodeproj]: withIosXcodeprojBaseMod: Cannot read properties of null (reading 'path')
    at correctForPath (/Users/expo/workingdir/build/node_modules/xcode/lib/pbxProject.js:1682:38)
    at correctForResourcesPath (/Users/expo/workingdir/build/node_modules/xcode/lib/pbxProject.js:1672:12)
    at pbxProject.addResourceFile (/Users/expo/workingdir/build/node_modules/xcode/lib/pbxProject.js:258:9)
    at /Users/expo/workingdir/build/node_modules/expo-share-intent/plugin/build/ios/withIosShareExtensionXcodeTarget.js:42:20
    at async action (/Users/expo/workingdir/build/node_modules/@expo/config-plugins/build/plugins/withMod.js:199:23)
    at async interceptingMod (/Users/expo/workingdir/build/node_modules/@expo/config-plugins/build/plugins/withMod.js:104:21)
    at async interceptingMod (/Users/expo/workingdir/build/node_modules/@expo/config-plugins/build/plugins/withMod.js:104:21)
    at async interceptingMod (/Users/expo/workingdir/build/node_modules/@expo/config-plugins/build/plugins/withMod.js:104:21)
    at async interceptingMod (/Users/expo/workingdir/build/node_modules/@expo/config-plugins/build/plugins/withMod.js:104:21)
    at async interceptingMod (/Users/expo/workingdir/build/node_modules/@expo/config-plugins/build/plugins/withMod.js:104:21)
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
yarn expo prebuild --no-install --platform ios exited with non-zero code: 1

To Reproduce Unknown. I think I followed the README properly. It builds on Android and functions properly.

Environment

TBD -- Need to go back to my macOS machine to properly document (but fails on EAS cloud also)

Additional context Add any other context about the problem here.

Nantris commented 1 month ago

I assume this is because I overlooked the patch-package requirement in the readme.