question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Fail to run pod with 2.3.0-beta.3 in monorepo

See original GitHub issue

Description

The last change in the podspec file fails in a monorepo.

Expected behavior

It “should work”, 2.3.0-beta.2 works fine

Actual behavior & steps to reproduce

I have a monorepo with yarn workspaces, and it seems the search for reactVersion fails to find the file.

Snack or minimal code example

Just udpdated from 2.3.0-beta.2 to 2.3.0-beta.3

This is the error log (you can see the full path of the module and app)

[!] Invalid `Podfile` file: 
[!] Invalid `RNReanimated.podspec` file: No such file or directory @ rb_sysopen - /Users/dan/Work/clients/current/emjoy/monorepo/packages/mobileapp/node_modules/react-native-reanimated/node_modules/react-native/package.json.

 #  from /Users/dan/Work/clients/current/emjoy/monorepo/packages/mobileapp/node_modules/react-native-reanimated/RNReanimated.podspec:11
 #  -------------------------------------------
 #    # Example app
 >    reactVersion = JSON.parse(File.read(File.join(__dir__, "node_modules", "react-native", "package.json")))["version"]
 #  end
 #  -------------------------------------------

Package versions

  • React Native: 0.66.0
  • React Native Reanimated: 2.3.0-beta.3
  • NodeJS: v16.11.1
  • Xcode: 13.0
  • Java & Gradle:

Affected platforms

  • Android
  • iOS
  • Web

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:9 (2 by maintainers)

github_iconTop GitHub Comments

6reactions
HuuNguyen312commented, Jun 6, 2022

I can’t run Android with Monorepo (reanimated: ^3.0.0-rc.0)

This is error log

FAILURE: Build failed with an exception.

* Where:
Build file '/xxx/Workspace/MyProject/node_modules/react-native-reanimated/android/build.gradle' line: 105

* What went wrong:
A problem occurred evaluating project ':react-native-reanimated'.
> /xxx/Workspace/MyProject/node_modules/react-native/package.json (No such file or directory)
1reaction
rborncommented, Nov 9, 2021

@piaskowyk OMG 😻

Read more comments on GitHub >

github_iconTop Results From Across the Web

Error running pod install: How to solve this problem?
On M1 macs, this is a known issue. Here's what you should do. Run this command (need to be run only first time)....
Read more >
What is monorepo? (and should you use it?) - Semaphore CI
A monorepo is a version-controlled code repository that holds many projects. While these projects may be related, they are often logically ...
Read more >
Fail to run pod with 2.3.0-beta.3 in monorepo - Codesti
I have a monorepo with yarn workspaces, and it seems the search for reactVersion fails to find the file. Snack or minimal code...
Read more >
How to manage your Flutter monorepos - Codemagic Blog
Run the melos run test command; Upload the results of failed Golden tests. Configure CI/CD for a monorepo. Set up Codemagic. First, you...
Read more >
Step by Step Guide on Creating a Monorepo for React Native ...
Go to the iOS folder at apps/daily-horoscope-app/ios and run Pod install . After running the command, you should see there are some changes ......
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found