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

FBReactNativeSpec Cocoapods lockfile has a different hash across machines #31698

Closed
JonnyBurger opened this issue Jun 10, 2021 · 2 comments
Closed
Labels
Needs: Triage 🔍 Resolution: Locked This issue was locked by the bot.

Comments

@JonnyBurger
Copy link
Contributor

Please provide all the information requested. Issues that do not follow this format are likely to stall.

Description

On iOS, after running pod install, Cocoapods creates a Podfile.lock. The lockfile should be checked into Version control to lock down the Cocoapods dependencies.

When committing the lockfile and running pod install on a different machine, the hash of FBReactNativeSpec changes.

- FBReactNativeSpec: 2323960c2c1cb6cf3e4072c3bc18376710f25425
+ FBReactNativeSpec: d27c8ab318553f4c49f992b63504f1e06b44235b

I am raising this issue because for teams, this is a small annoyance, since you always have to either commit the hash change to an unrelated pull request or manually discard the change.
Therefore I wanted to ask if it's possible to investigate it and find a fix that causes the lockfile hashes to be reproducible across machines.

React Native version:

System:
    OS: macOS 11.1
    CPU: (16) x64 Intel(R) Core(TM) i9-9900K CPU @ 3.60GHz
    Memory: 70.93 GB / 128.00 GB
    Shell: 5.8 - /bin/zsh
  Binaries:
    Node: 14.17.0 - /usr/local/bin/node
    Yarn: 1.22.5 - /usr/local/bin/yarn
    npm: 6.14.13 - /usr/local/bin/npm
    Watchman: 4.9.0 - /usr/local/bin/watchman
  Managers:
    CocoaPods: 1.10.1 - /usr/local/bin/pod
  SDKs:
    iOS SDK:
      Platforms: iOS 14.5, DriverKit 20.4, macOS 11.3, tvOS 14.5, watchOS 7.4
    Android SDK: Not Found
  IDEs:
    Android Studio: 4.2 AI-202.7660.26.42.7351085
    Xcode: 12.5/12E262 - /usr/bin/xcodebuild
  Languages:
    Java: 15.0.2 - /usr/local/opt/openjdk/bin/javac
  npmPackages:
    @react-native-community/cli: Not Found
    react: 17.0.1 => 17.0.1
    react-native: 0.64.1 => 0.64.1
    react-native-macos: Not Found
  npmGlobalPackages:
    *react-native*: Not Found

Steps To Reproduce

Provide a detailed list of steps that reproduce the issue.

  1. Run pod install on one machine and commit the Podfile.lock
  2. Run pod install on another machine and observe that the lockfile has changed.

Expected Results

The lockfile should stay the same to the Git status stays clean

Snack, code example, screenshot, or link to a repository:

As far as I know, this is reproducible on any React Native project.

@rchristian
Copy link

A fix is discussed here and has been suggested as a cherry-pick for version 0.64.3. Hopefully, it will be included.

@JonnyBurger
Copy link
Contributor Author

Oh very cool! Thanks!

In that case, duplicate of #31193 🙂

@facebook facebook locked as resolved and limited conversation to collaborators Jun 10, 2022
@react-native-bot react-native-bot added the Resolution: Locked This issue was locked by the bot. label Jun 10, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Needs: Triage 🔍 Resolution: Locked This issue was locked by the bot.
Projects
None yet
Development

No branches or pull requests

3 participants