Skip to content

[react-native-git-upgrade][0.41.2] Upgrading to 0.41.2 changes the name of my app to "Hello App Display Name" #12420

@ncuillery

Description

@ncuillery

Description

After upgrading my app to 0.41.2, the name of my app became "Hello App Display Name" on my device.

Reproduction

  • Init a project using version 0.41.1 👉 react-native init MyApp --version=0.41.1
  • Run the app on an Android device 👉 react-native run-android
  • The name of the app on the home screen is "MyApp"
  • Upgrade the project to 0.41.2 👉 react-native-git-upgrade 0.41.2
  • Run the app on an Android device 👉 react-native run-android
  • The name of the app on the home screen is "Hello App Display Name" 😱

Solution

The upgrading tool runs the generator copyProjectTemplateAndReplace twice: one with the current version of RN, one with the new version.

The second time the generator is required, it is served from the require cache, so the template of 0.41.2 is processed by the generator of 0.41.1. That leads to a bad diff patch because of a change in the generator in 0.41.2.

I saw it coming (see the require cache busting) but it is ineffective. PR is coming.

Additional Information

  • React Native version: 0.41.2
  • react-native-git-upgrade version: 0.2.6
  • Platform: Tested on Android, probably iOS is concerned as well
  • Operating System: MacOS X El Capitan

Metadata

Metadata

Assignees

No one assigned

    Labels

    Issue: Author Provided ReproThis issue can be reproduced in Snack or an attached project.Resolution: LockedThis issue was locked by the bot.

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions