react-native-google-signin / google-signin

Google Sign-in for your React Native applications
https://react-native-google-signin.github.io/
MIT License
3.12k stars 877 forks source link

AppAuth 1.7.0 will give 'No visible @interface for 'OIDAuthorizationResponse' declares the selector 'tokenExchangeRequestWithAdditionalParameters:' #1255

Closed kasper-madsen closed 3 months ago

kasper-madsen commented 3 months ago

I am starting a fairly new RN project for iOS atm. version 0.73.4

i installed the newest @react-native-google-signin/google-signin = 11.0

Pod install used AppAuth 1.7.0 which will cause this error when building

'No visible @interface for 'OIDAuthorizationResponse' declares the selector 'tokenExchangeRequestWithAdditionalParameters:'

iOS version 17.0.1

Solution: looking at examples it uses AppAuth 1.6.2 for iOS. setting this version lets me build

pkgundam commented 3 months ago

it used to work and Pod install started using AppAuth 1.7.0 and app is not building now

algera commented 3 months ago

Similar issue seen here:

GTMAppAuth/GTMAppAuth/Sources/GTMOAuth2KeychainCompatibility.m:137:32 No visible @interface for 'OIDTokenRequest' declares the selector 'initWithConfiguration:grantType:authorizationCode:redirectURL:clientID:clientSecret:scope:refreshToken:codeVerifier:additionalParameters:'
BernalCarlos commented 3 months ago

@kasper-madsen How do you set AppAuth to version 1.6.2? I'm trying to figure out a workaround to this issue

l-bruyant commented 3 months ago

Exact same issue here

BernalCarlos commented 3 months ago

For an Expo managed app the AppAuth version can be set using the expo-build-properties plugin:

plugins: [
      ...
      [
        "expo-build-properties",
        {
          ios: {
            ...
            extraPods: [
              { name: "AppAuth", version: "=1.6.2" },
            ],
          },
       ...
        },
      ],
      ...
]

I can confirm that downgrading AppAuth to 1.6.2 is a valid workaround.

pkgundam commented 3 months ago

For an Expo managed app the AppAuth version can be set using the expo-build-properties plugin:

plugins: [
      ...
      [
        "expo-build-properties",
        {
          ios: {
            ...
            extraPods: [
              { name: "AppAuth", version: "=1.6.2" },
            ],
          },
       ...
        },
      ],
      ...
]

I can confirm that downgrading AppAuth to 1.6.2 is a valid workaround.

I love you!!!! thank you very much

vonovak commented 3 months ago

Hello, AppAuth 1.7.1 was released with a fix

https://github.com/openid/AppAuth-iOS/releases/tag/1.7.1

Please use that or the workaround above.

Thank you!🙂

hachther commented 3 months ago

@kasper-madsen How do you set AppAuth to version 1.6.2? I'm trying to figure out a workaround to this issue

You can add the below line in your Podfile to used version 1.7.1, it work find.

pod 'AppAuth', '1.7.1'

The type pod install --repo-update to update