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.

Dev-Client Crashes When Building JS Bundle After Adding Native Package + Config Plugins

See original GitHub issue

Summary

I am trying to use Bluetooth Classic on iOS with react-native-bluetooth-classic along with a basic config plugin I wrote. Since running ‘expo add react-native-bluetooth-classic’, when I create a dev-client and scan the QR code, the bundle crashes immediately without errors.

GitHub: https://github.com/amitferman/bluetooth-classic-demo

Managed or bare workflow? If you have made manual changes inside of the ios/ or android/ directories in your project, the answer is bare!

bare

What platform(s) does this occur on?

iOS

Package versions

expo-dev-client: 0.4.7 expo: 42.0.3 eas-cli: 0.23.0

Environment

Expo CLI 4.10.0 environment info: System: OS: Windows 10 10.0.19042 Binaries: Node: 14.17.0 - C:\Program Files\nodejs\node.EXE npm: 6.14.13 - C:\Program Files\nodejs\npm.CMD IDEs: Android Studio: Version 4.2.0.0 AI-202.7660.26.42.7486908 npmPackages: expo: ~42.0.1 => 42.0.3 react: 16.13.1 => 16.13.1 react-dom: 16.13.1 => 16.13.1 react-native: ~0.63.4 => 0.63.4 react-native-web: ~0.13.12 => 0.13.18 Expo Workflow: bare

Reproducible demo or steps to reproduce from a blank project

expo init bluetooth-classic-demo cd bluetooth-classic-demo expo add expo-dev-client expo add react-native-bluetooth-classic …At this point the dev client can’t open the bundle Then I added in bluetooth-classic-plugin.js to configure info.plist …Same behavior

Stacktrace (if a crash is involved)

xcode-build-dff54d2e-3ab9-4b63-8dfb-5dc758d178bf (1).log

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:8

github_iconTop GitHub Comments

1reaction
vivek-paicommented, Aug 20, 2021

Sweet. Works for me, too! Good job.

From: amitferman @.> Sent: Wednesday, August 18, 2021 5:44 PM To: expo/expo @.> Cc: Vivek Pai @.>; Comment @.> Subject: Re: [expo/expo] Dev-Client Crashes When Building JS Bundle After Adding Native Package + Config Plugins (#14021)

Aha! This works. What was I thinking 7 days ago 😆. The complete plugin is: const withBLC = (config) => { // Ensure the objects exist if (!config.ios) { config.ios = {}; } if (!config.ios.infoPlist) { config.ios.infoPlist = {}; } config.ios.infoPlist.UISupportedExternalAccessoryProtocols = [‘com.apple.m1’]; config.ios.infoPlist.NSBluetoothPeripheralUsageDescription = “Some Description (PeripheralUsage)”; config.ios.infoPlist.NSBluetoothAlwaysUsageDescription = “Some Description (AlwaysUsage)”; return config; };

module.exports = withBLC;

— You are receiving this because you commented. Reply to this email directly, view it on GitHubhttps://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fexpo%2Fexpo%2Fissues%2F14021%23issuecomment-901523023&data=04|01||5ba0f3d87e394d1c815508d962aa6a1a|84df9e7fe9f640afb435aaaaaaaaaaaa|1|0|637649306322680251|Unknown|TWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D|1000&sdata=C0wHoRcwUrkSbD%2FE4oYj6oVgUFkeBi58EogSS57Pet0%3D&reserved=0, or unsubscribehttps://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fnotifications%2Funsubscribe-auth%2FAACFT242PP2EVDSKNNYERGLT5RHUNANCNFSM5B72ZTGQ&data=04|01||5ba0f3d87e394d1c815508d962aa6a1a|84df9e7fe9f640afb435aaaaaaaaaaaa|1|0|637649306322690245|Unknown|TWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D|1000&sdata=p7TIf3SGp%2FTq9MyVbT8fvo84b%2BgTIcO%2BkI%2FaM0rHjaU%3D&reserved=0. Triage notifications on the go with GitHub Mobile for iOShttps://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fapps.apple.com%2Fapp%2Fapple-store%2Fid1477376905%3Fct%3Dnotification-email%26mt%3D8%26pt%3D524675&data=04|01||5ba0f3d87e394d1c815508d962aa6a1a|84df9e7fe9f640afb435aaaaaaaaaaaa|1|0|637649306322690245|Unknown|TWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D|1000&sdata=kSg4heZDuxkboICdrJm%2Byq5xlBcsSOQf2rzHmeRgBdU%3D&reserved=0 or Androidhttps://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fplay.google.com%2Fstore%2Fapps%2Fdetails%3Fid%3Dcom.github.android%26utm_campaign%3Dnotification-email&data=04|01||5ba0f3d87e394d1c815508d962aa6a1a|84df9e7fe9f640afb435aaaaaaaaaaaa|1|0|637649306322700239|Unknown|TWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D|1000&sdata=3xPzD7rteVg5lVaFB7%2BzDVcUuCAdTxyDmso%2BDS1ty7s%3D&reserved=0.

0reactions
amitfermancommented, Aug 22, 2021

@vivek-pai You can also use with-rn-bluetooth-classic and it might be more convenient.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Build fails for projects with expo-dev-client when ... - GitHub
js , the expo-dev-client throws an error during build and the build fails. Configuring use_frameworks seems to be a documented expo-supported ...
Read more >
Troubleshooting build errors and crashes - Expo Documentation
If you are working on a managed app and the build error is a native error rather than a JavaScript error, this is...
Read more >
EAS android build crashing after splash screen - Stack Overflow
I am using managed workflow. After finding the compatible versions of all the libraries i was able to get the app in running...
Read more >
Expo app crashes when attempting to write a new record with ...
I created an Expo React Native app using the “Quick start with Expo” documentation. I modified the schema and variable names to match...
Read more >
Developing React Native with Expo and Flipper
Since we've added a new native module, we'll need to create a new development build that has our native iOS and Android code...
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