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

Unable to publish/use a nexus module using @jitsi/react-native-sdk #226

Open
seetharampullela opened this issue Mar 21, 2024 · 10 comments
Open

Comments

@seetharampullela
Copy link

Hi,
I am using nexus to place all my common modules that I use in all of my projects. When I started implementing common-communication module using @jitsti/react-native-sdk, I couldn't even able to install all dependencies with my nexus .npmrc. So, I tried doing it without npmrc configuration. Even after that when I try to install my common-communication nexus module, unable to run the JitsiMeeting saying it couldn't be found. I followed the documentation while installing @jitsti/react-native-sdk from official website.

@saghul
Copy link
Member

saghul commented Mar 21, 2024

What is nexus?

@seetharampullela
Copy link
Author

seetharampullela commented Mar 21, 2024

Hi @saghul

Nexus is a private repository maintaining service similar to npm.
I created a react-native module to maintain as a common module for all my projects.
I installed jitsi/react-native-sdk in common-communication and pushed it to nexus(private npm repo).

When I install it and try to run this in one of my other projects getting errors

Screenshot 2024-03-21 at 1 37 54 PM

@saghul
Copy link
Member

saghul commented Mar 21, 2024

Ah that nexus.

Our SDK depends on many modules. The error you see there is because react-native-webrtc was not found. You basically need to push all our dependencies to your nexis too.

As an aside, we don't yet support Hermes, which I see you're using.

@seetharampullela
Copy link
Author

seetharampullela commented Mar 21, 2024

@saghul

I tried disabling Hermes engine too. Still couldn't solve the issue. When I use @jitsi/react-native-sdk directly in a project it worked.

How can I push all dependencies in nexus.

I also tried in iOS too. but getting below error

simulator_screenshot_22D7B9E4-0480-4AF0-8760-192E69E8C6F1
Here is my package.json for nexus package

{
"type": "module",
"name": "common-communication",
"version": "1.0.0",
"main": "src/index.tsx",
"react-native": "src/index.tsx",
"source": "src/index.tsx",
"scripts": {
"lint": "eslint .",
"test": "jest",
"format": "prettier --write src/**/*.{ts,tsx,css,scss,md,json} --config ./.prettierrc"
},
"author": "Pavan",
"license": "ISC",
"dependencies": {
"@stomp/stompjs": "^7.0.0",
"@amplitude/react-native": "2.7.0",
"@braintree/sanitize-url": "7.0.0",
"@giphy/react-native-sdk": "2.3.0",
"@jitsi/react-native-sdk": "2.0.2",
"@react-native-async-storage/async-storage": "1.19.4",
"@react-native-community/clipboard": "1.5.1",
"@react-native-community/netinfo": "11.1.0",
"@react-native-community/slider": "4.4.3",
"@react-native-google-signin/google-signin": "10.1.0",
"@react-native/metro-config": "0.72.9",
"react": "18.2.0",
"react-native": "0.72.3",
"react-native-background-timer": "2.4.1",
"react-native-calendar-events": "2.2.0",
"react-native-default-preference": "1.4.4",
"react-native-device-info": "10.9.0",
"react-native-gesture-handler": "2.9.0",
"react-native-get-random-values": "1.9.0",
"react-native-immersive-mode": "2.0.1",
"react-native-keep-awake": "4.0.0",
"react-native-orientation-locker": "1.6.0",
"react-native-pager-view": "6.2.0",
"react-native-paper": "5.10.3",
"react-native-performance": "5.0.0",
"react-native-safe-area-context": "4.7.1",
"react-native-screens": "3.24.0",
"react-native-sound": "0.11.2",
"react-native-splash-screen": "3.3.0",
"react-native-svg": "13.13.0",
"react-native-video": "6.0.0-alpha.11",
"react-native-watch-connectivity": "1.1.0",
"react-native-webrtc": "118.0.2",
"react-native-webview": "13.5.1",
"text-encoding": "0.7.0"
},
"devDependencies": {
"@babel/core": "^7.20.0",
"@babel/preset-env": "^7.20.0",
"@babel/runtime": "^7.20.0",
"@react-native/eslint-config": "0.73.2",
"@react-native/metro-config": "0.72.9",
"@react-native/typescript-config": "0.73.1",
"@types/react": "^18.2.6",
"@types/react-test-renderer": "^18.0.0",
"@types/text-encoding": "^0.0.39",
"babel-jest": "^29.6.3",
"eslint": "^8.19.0",
"jest": "^29.6.3",
"prettier": "2.8.8",
"react-test-renderer": "18.2.0",
"typescript": "5.0.4",
"@babel/plugin-proposal-export-default-from": "7.22.5",
"metro-react-native-babel-preset": "0.76.8"
},
"engines": {
"node": ">=16"
},
"overrides": {
"@xmldom/xmldom": "0.8.7"
}
}

@seetharampullela
Copy link
Author

@saghul
Also, in the examples of react-native provided in the official website hermesEngine is already enabled.
Repo Link:
https://github.com/jitsi/jitsi-meet-sdk-samples/tree/master/react-native

@saghul
Copy link
Member

saghul commented Mar 21, 2024

I tried disabling Hermes engine too. Still couldn't solve the issue. When I use @jitsi/react-native-sdk directly in a project it worked.

I didn't say it would, it was an aside comment.

How can I push all dependencies in nexus.

I don't know since I don't use nexus. It does sound somewhat complex since our dependencies might have more dependencies, and so on.

Also, in the examples of react-native provided in the official website hermesEngine is already enabled.
Repo Link:
https://github.com/jitsi/jitsi-meet-sdk-samples/tree/master/react-native

Ops, that was an oversight. Thanks for the heads up, I just disabled it.

@seetharampullela
Copy link
Author

seetharampullela commented Mar 21, 2024

@saghul
I am confused about what these scripts do in @jitsi/react-native-sdk package.

Also, I think i need to maintain these in my nexus module

Screenshot 2024-03-21 at 3 11 28 PM

@saghul
Copy link
Member

saghul commented Mar 21, 2024

Those scripts just help sync the dependencies. They are part of the package, you don't need to worry about them.

@seetharampullela
Copy link
Author

@saghul
Thank you for your response.

As I said earlier about the nexus registry, I logged in to npm with my nexus credentials and if I try to install @jitsi/react-native-sdk, getting a 401 error saying couldn't install yaml (and many other dependencies).

@saghul
Copy link
Member

saghul commented Mar 22, 2024

Because they are not in your nexus.

You'll need to push all of them, but there are tons! Look inside package-lock.

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

No branches or pull requests

2 participants