Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[core] fix build.gradle backward compatibility for previous expo modules #28359

Merged
merged 2 commits into from
Apr 22, 2024

Conversation

Kudo
Copy link
Contributor

@Kudo Kudo commented Apr 22, 2024

Why

fix backward compatibility for previous expo modules.

How

supposedly for #28083, previous expo modules are backward compatible and not necessary for any changes. but there is an error actually.

previous applyKotlinExpoModulesCorePlugin() is inside buildscript { and executed before any apply plugins: from build.gradle. the project.plugins.hasPlugin will always return false and will have error if apply plugin: 'kotlin-android' twice.

this pr uses try-catch to deal with the problem for that.

Test Plan

$ yarn create expo-module
$ cd my-module/example
$ yarn add expo@next
$ npx expo prebuild -p android --clean
$ cd android
$ ./gradlew :app:assembleDebug

Checklist

@expo-bot expo-bot added the bot: suggestions ExpoBot has some suggestions label Apr 22, 2024
@expo-bot expo-bot added bot: passed checks ExpoBot has nothing to complain about and removed bot: suggestions ExpoBot has some suggestions labels Apr 22, 2024
@expo-bot
Copy link
Collaborator

The Pull Request introduced fingerprint changes against the base commit: 78c1de6

Fingerprint diff
[
  {
    "type": "dir",
    "filePath": "../../packages/expo-modules-core/android",
    "reasons": [
      "expoAutolinkingAndroid"
    ],
    "hash": "9bfaac5907b91af1da5716081219a61e90e31033"
  }
]

Generated by PR labeler 🤖

@Kudo Kudo marked this pull request as ready for review April 22, 2024 15:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bot: fingerprint changed bot: passed checks ExpoBot has nothing to complain about
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants