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

chore: upgrade to React Native 0.70.0 react-navigation, and all other deps #2880

Merged
merged 41 commits into from
Sep 19, 2022

Conversation

mikaelbr
Copy link
Collaborator

@mikaelbr mikaelbr commented Aug 24, 2022

Updates all outdated dependencies and does code migration.

Closes https://github.com/AtB-AS/kundevendt/issues/2228
Closes https://github.com/AtB-AS/kundevendt/issues/1560

Changes

  • Structured all react-navigation types inside types.ts in respective screen modules. This is used to stack properly type hierarchy. All naming convention hopefully should (big hopefully, as there are a lot and having to do some changes over time her) be named the same. Added helpers to make subscreens work easier, without a lot of manual typing for each screen type.
  • Updated all dependencies, and updated breaking changes where found.
  • Added possibility of running new architecture for React Native by manually adding all files. But this is not verified or tested (!!!)
  • Temporary removed eslint rule 'react-native/no-raw-text': [2, {skip: ['ThemeText']}] due to bugs (see issue)
  • Dismissable Screen is removed

Testing changes

  • Navigations are changed, so verifying things like onboarding, ticketing (with and without vipps) and feature toggles is important.
  • Checking on device and different Android/iOS versions
  • Full regression testing

Todo

  • Dismissable Stack View now gets shown as a iOS modal view instead of normal card view. Must be fixed.
  • Performance changes? Check out

Required setup

Setup JDK 11:

Select JDK for Gradle using Android Studio (select JDK from previous step).

Upgrade Cocoapods

@mikaelbr mikaelbr temporarily deployed to atb August 24, 2022 11:35 Inactive
@mikaelbr mikaelbr temporarily deployed to nfk August 24, 2022 11:35 Inactive
@mikaelbr mikaelbr temporarily deployed to atb August 24, 2022 11:35 Inactive
@mikaelbr mikaelbr temporarily deployed to nfk August 24, 2022 11:35 Inactive
@mikaelbr mikaelbr changed the title chore: upgrade to React Native 0.69.4 chore: upgrade to React Native 0.69.5, react-navigation, and all other deps Aug 29, 2022
@mikaelbr mikaelbr temporarily deployed to atb September 13, 2022 10:48 Inactive
@mikaelbr mikaelbr temporarily deployed to nfk September 13, 2022 10:48 Inactive
@mikaelbr mikaelbr temporarily deployed to nfk September 13, 2022 10:48 Inactive
@mikaelbr mikaelbr temporarily deployed to atb September 14, 2022 12:35 Inactive
@mikaelbr mikaelbr temporarily deployed to atb September 14, 2022 12:35 Inactive
@mikaelbr mikaelbr temporarily deployed to nfk September 14, 2022 12:35 Inactive
@mikaelbr mikaelbr temporarily deployed to nfk September 14, 2022 12:35 Inactive
@rosvik
Copy link
Member

rosvik commented Sep 15, 2022

I'm getting an error when I try to build the ios app locally now (tried both xcode and yarn ios): Cycle in dependencies between targets 'AbtTokenCoreSDK' and 'SwiftProtobuf'; building could produce unreliable results.

Could it be something with my local setup, or is there something wrong here?

Full error message
Cycle path: AbtTokenCoreSDK → SwiftProtobuf → AbtTokenCoreSDK
Cycle details:
→ Target 'AbtTokenCoreSDK': Libtool /Users/rosvik/Library/Developer/Xcode/DerivedData/atb-apjswojyrfohxzfjxdarknbegett/Build/Products/Debug-iphonesimulator/AbtTokenCoreSDK/libAbtTokenCoreSDK.a normal
○ Target 'AbtTokenCoreSDK' has target dependency on Target 'SwiftProtobuf'
○ That command depends on command in Target 'SwiftProtobuf': script phase “Copy generated compatibility header”
→ Target 'SwiftProtobuf' has copy command from '/Users/rosvik/Library/Developer/Xcode/DerivedData/atb-apjswojyrfohxzfjxdarknbegett/Build/Intermediates.noindex/Pods.build/Debug-iphonesimulator/SwiftProtobuf.build/Objects-normal/x86_64/SwiftProtobuf-Swift.h' to '/Users/rosvik/Library/Developer/Xcode/DerivedData/atb-apjswojyrfohxzfjxdarknbegett/Build/Intermediates.noindex/Pods.build/Debug-iphonesimulator/SwiftProtobuf.build/DerivedSources/SwiftProtobuf-Swift.h'
○ Target 'SwiftProtobuf' has compile command for Swift source files


Raw dependency cycle trace:

target:  ->

node: <all> ->

command: <all> ->

node: /Users/rosvik/Library/Developer/Xcode/DerivedData/atb-apjswojyrfohxzfjxdarknbegett/Build/Products/Debug-iphonesimulator/AbtTokenCoreSDK/libAbtTokenCoreSDK.a ->

command: target-AbtTokenCoreSDK-8699adb1dd336b26511df848a716bd426980b72bfb99cbc4bf9ec35203ba657b-:Debug:Libtool /Users/rosvik/Library/Developer/Xcode/DerivedData/atb-apjswojyrfohxzfjxdarknbegett/Build/Products/Debug-iphonesimulator/AbtTokenCoreSDK/libAbtTokenCoreSDK.a normal ->

node: /Users/rosvik/Library/Developer/Xcode/DerivedData/atb-apjswojyrfohxzfjxdarknbegett/Build/Intermediates.noindex/Pods.build/Debug-iphonesimulator/AbtTokenCoreSDK.build/Objects-normal/x86_64/AbstractDeviceAttestator.o ->

command: target-AbtTokenCoreSDK-8699adb1dd336b26511df848a716bd426980b72bfb99cbc4bf9ec35203ba657b-:Debug:CompileSwiftSources normal x86_64 com.apple.xcode.tools.swift.compiler ->

node: <target-AbtTokenCoreSDK-8699adb1dd336b26511df848a716bd426980b72bfb99cbc4bf9ec35203ba657b--begin-compiling> ->

command: Gate target-AbtTokenCoreSDK-8699adb1dd336b26511df848a716bd426980b72bfb99cbc4bf9ec35203ba657b--begin-compiling ->

node: <target-SwiftProtobuf-8699adb1dd336b26511df848a716bd4240fa72b1389229bc82a786c7bb54bc7b--modules-ready> ->

command: Gate target-SwiftProtobuf-8699adb1dd336b26511df848a716bd4240fa72b1389229bc82a786c7bb54bc7b--modules-ready ->

CYCLE POINT ->

node: /Users/rosvik/Library/Developer/Xcode/DerivedData/atb-apjswojyrfohxzfjxdarknbegett/Build/Products/Debug-iphonesimulator/SwiftProtobuf/SwiftProtobuf.modulemap ->

command: target-SwiftProtobuf-8699adb1dd336b26511df848a716bd4240fa72b1389229bc82a786c7bb54bc7b-:Debug:PhaseScriptExecution Copy generated compatibility header /Users/rosvik/Library/Developer/Xcode/DerivedData/atb-apjswojyrfohxzfjxdarknbegett/Build/Intermediates.noindex/Pods.build/Debug-iphonesimulator/SwiftProtobuf.build/Script-46EB2E00039C40.sh ->

node: /Users/rosvik/Library/Developer/Xcode/DerivedData/atb-apjswojyrfohxzfjxdarknbegett/Build/Intermediates.noindex/Pods.build/Debug-iphonesimulator/SwiftProtobuf.build/DerivedSources/SwiftProtobuf-Swift.h/ ->

directoryTreeSignature: � ->

directoryContents: /Users/rosvik/Library/Developer/Xcode/DerivedData/atb-apjswojyrfohxzfjxdarknbegett/Build/Intermediates.noindex/Pods.build/Debug-iphonesimulator/SwiftProtobuf.build/DerivedSources/SwiftProtobuf-Swift.h ->

node: /Users/rosvik/Library/Developer/Xcode/DerivedData/atb-apjswojyrfohxzfjxdarknbegett/Build/Intermediates.noindex/Pods.build/Debug-iphonesimulator/SwiftProtobuf.build/DerivedSources/SwiftProtobuf-Swift.h ->

command: target-SwiftProtobuf-8699adb1dd336b26511df848a716bd4240fa72b1389229bc82a786c7bb54bc7b-:Debug:PBXCp /Users/rosvik/Library/Developer/Xcode/DerivedData/atb-apjswojyrfohxzfjxdarknbegett/Build/Intermediates.noindex/Pods.build/Debug-iphonesimulator/SwiftProtobuf.build/Objects-normal/x86_64/SwiftProtobuf-Swift.h /Users/rosvik/Library/Developer/Xcode/DerivedData/atb-apjswojyrfohxzfjxdarknbegett/Build/Intermediates.noindex/Pods.build/Debug-iphonesimulator/SwiftProtobuf.build/DerivedSources/SwiftProtobuf-Swift.h ->

node: /Users/rosvik/Library/Developer/Xcode/DerivedData/atb-apjswojyrfohxzfjxdarknbegett/Build/Intermediates.noindex/Pods.build/Debug-iphonesimulator/SwiftProtobuf.build/Objects-normal/x86_64/SwiftProtobuf-Swift.h/ ->

directoryTreeSignature: � ->

directoryContents: /Users/rosvik/Library/Developer/Xcode/DerivedData/atb-apjswojyrfohxzfjxdarknbegett/Build/Intermediates.noindex/Pods.build/Debug-iphonesimulator/SwiftProtobuf.build/Objects-normal/x86_64/SwiftProtobuf-Swift.h ->

node: /Users/rosvik/Library/Developer/Xcode/DerivedData/atb-apjswojyrfohxzfjxdarknbegett/Build/Intermediates.noindex/Pods.build/Debug-iphonesimulator/SwiftProtobuf.build/Objects-normal/x86_64/SwiftProtobuf-Swift.h ->

command: target-SwiftProtobuf-8699adb1dd336b26511df848a716bd4240fa72b1389229bc82a786c7bb54bc7b-:Debug:CompileSwiftSources normal x86_64 com.apple.xcode.tools.swift.compiler ->

node: /Users/rosvik/Library/Developer/Xcode/DerivedData/atb-apjswojyrfohxzfjxdarknbegett/Build/Products/Debug-iphonesimulator/SwiftProtobuf/SwiftProtobuf.modulemap

@mikaelbr mikaelbr temporarily deployed to atb September 16, 2022 11:24 Inactive
@mikaelbr mikaelbr temporarily deployed to nfk September 16, 2022 11:24 Inactive
@mikaelbr mikaelbr temporarily deployed to atb September 16, 2022 11:24 Inactive
@mikaelbr mikaelbr temporarily deployed to nfk September 16, 2022 11:24 Inactive
@mikaelbr mikaelbr temporarily deployed to atb September 19, 2022 06:39 Inactive
@mikaelbr mikaelbr temporarily deployed to nfk September 19, 2022 06:39 Inactive
@mikaelbr mikaelbr temporarily deployed to atb September 19, 2022 06:39 Inactive
@mikaelbr mikaelbr temporarily deployed to nfk September 19, 2022 06:39 Inactive
Copy link
Member

@Nisha1306 Nisha1306 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🚢

@mikaelbr mikaelbr merged commit d2de31f into master Sep 19, 2022
@mikaelbr mikaelbr deleted the mikael/upgrade-react-native branch September 19, 2022 07:12
@mikaelbr
Copy link
Collaborator Author

Related fix: #2950

mikaelbr added a commit that referenced this pull request Sep 21, 2022
* fix: removed deprecated removeEventListener for Dimesions

* fix: updates react-native-svgs to fix issue with svgs not updating

* fix: use original sourcemap name

* fix: set merge for zone select

* fix: setting arrival/departure time for travel search
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants