react-native-visionos icon indicating copy to clipboard operation
react-native-visionos copied to clipboard

Asset validation failed - A key for 'MinimumOSVersion' is required

Open billyjacoby opened this issue 1 year ago • 3 comments

Description

Trying to validate a package gives the error:

Missing Info.plist value. A value for the key 'MinimumOSVersion' in bundle rnVision.app/ Frameworks/hermes.framework is required. (ID: 9433b1a0-5eff-4dd6-987b-06de7f96acca))

Steps to reproduce

  1. Install a new applicaiton
  2. Create an archive
  3. Validate that archive

React Native Version

0.73.3

Affected Platforms

Other (please specify)

Output of npx react-native info

System:
  OS: macOS 14.4
  CPU: (10) arm64 Apple M1 Max
  Memory: 6.48 GB / 32.00 GB
  Shell:
    version: "5.9"
    path: /bin/zsh
Binaries:
  Node:
    version: 18.18.2
    path: ~/.nvm/versions/node/v18.18.2/bin/node
  Yarn:
    version: 4.1.0
    path: ~/.nvm/versions/node/v18.18.2/bin/yarn
  npm:
    version: 9.8.1
    path: ~/.nvm/versions/node/v18.18.2/bin/npm
  Watchman:
    version: 2024.01.22.00
    path: /opt/homebrew/bin/watchman
Managers:
  CocoaPods:
    version: 1.15.2
    path: /opt/homebrew/bin/pod
SDKs:
  iOS SDK:
    Platforms:
      - DriverKit 23.2
      - iOS 17.2
      - macOS 14.2
      - tvOS 17.2
      - visionOS 1.0
      - watchOS 10.2
  Android SDK: Not Found
IDEs:
  Android Studio: 2022.2 AI-222.4459.24.2221.9971841
  Xcode:
    version: 15.2/15C500b
    path: /usr/bin/xcodebuild
Languages:
  Java:
    version: 11.0.19
    path: /usr/bin/javac
  Ruby:
    version: 2.6.10
    path: /usr/bin/ruby
npmPackages:
  "@react-native-community/cli": Not Found
  react:
    installed: 18.2.0
    wanted: 18.2.0
  react-native:
    installed: 0.73.3
    wanted: 0.73.3
  react-native-macos: Not Found
npmGlobalPackages:
  "*react-native*": Not Found
Android:
  hermesEnabled: true
  newArchEnabled: false
iOS:
  hermesEnabled: true
  newArchEnabled: false

Stacktrace or Logs

Missing Info.plist value. A value for the key 'MinimumOSVersion' in bundle rnVision.app/ Frameworks/hermes.framework is required. (ID: 9433b1a0-5eff-4dd6-987b-06de7f96acca))

Reproducer

https://github.com/billyjacoby/vision-template

Screenshots and Videos

I know this project is marked as experimental and not ready for production, but wanted to post these findings here anyway.

I tried adding the MinimumOSValue in the visionos/Pods/hermes-engine/destroot/Library/Frameworks/xros/hermes.framework/Info.plist file, but that didn't seem to help.

billyjacoby avatar Feb 07 '24 12:02 billyjacoby

Hey, thanks for opening the issue. I'm aware of this bug and I have it on my todo list 😄

A workaround that you can do:

  1. Archive
  2. Click Open Archive in Finder
  3. Click "Show Package contents" on .xcarchive in Finder
  4. Go to Products/Applications/NameOfTheApp.app
  5. Click on the .app and "Show Package contents"
  6. Go to Frameworks/hermes.framework
  7. Modify the contents of Info.plist to include:
<key>MinimumOSVersion</key>
<string>1.0</string>

I think it may also work if you modify the destroot/Library/Frameworks one but with MinimumOSVersion

okwasniewski avatar Feb 07 '24 12:02 okwasniewski

That workaround fixes it, thanks!

billyjacoby avatar Feb 07 '24 13:02 billyjacoby

This issue should be closed once this PR gets merged to Hermes: https://github.com/facebook/hermes/pull/1358

okwasniewski avatar Apr 30 '24 13:04 okwasniewski

Hey,

This issue should now be resolved in React Native 0.74.3. Backport to 0.73.x will be available once this PR get's merged: https://github.com/facebook/hermes/pull/1432

okwasniewski avatar Jun 10 '24 12:06 okwasniewski

Hey, thanks for opening the issue. I'm aware of this bug and I have it on my todo list 😄

A workaround that you can do:

  1. Archive
  2. Click Open Archive in Finder
  3. Click "Show Package contents" on .xcarchive in Finder
  4. Go to Products/Applications/NameOfTheApp.app
  5. Click on the .app and "Show Package contents"
  6. Go to Frameworks/hermes.framework
  7. Modify the contents of Info.plist to include:
<key>MinimumOSVersion</key>
<string>1.0</string>

I think it may also work if you modify the destroot/Library/Frameworks one but with MinimumOSVersion

It works. In my case I had to add:

<key>MinimumOSVersion</key>
<string>13.4</string>

pepperav avatar Aug 02 '24 09:08 pepperav