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

using npm build error #391

Closed
Skorpeo opened this issue Sep 19, 2019 · 9 comments
Closed

using npm build error #391

Skorpeo opened this issue Sep 19, 2019 · 9 comments
Assignees
Milestone

Comments

@Skorpeo
Copy link

Skorpeo commented Sep 19, 2019

image

@hthetiot
Copy link
Contributor

Hum That weird I build with success, can you provide your iOS target and Xcode version please. Will look into that. Cc @CSantosM

@hthetiot hthetiot added this to the 5.0.3 milestone Sep 20, 2019
@hthetiot hthetiot self-assigned this Sep 20, 2019
@hthetiot
Copy link
Contributor

hthetiot commented Sep 20, 2019

@Skorpeo I do not reproduce this error on build using target 10.2 and up 12.4.
Are you using Xcode 11 or Targeting iOS 13 ?

Please provide more information so we know what version of iOS or Cordova require this changes.

See my build results without the change:

Screen Shot 2019-09-20 at 9 30 48 AM

Still, here is the fixed initAudioDevices function: 3686e5b
Will be released as part of 5.0.3

fileprivate func initAudioDevices() -> Void {
	let audioSession: AVAudioSession = AVAudioSession.sharedInstance()
	
	do {
		try audioSession.setCategory(AVAudioSession.Category.playAndRecord, mode: AVAudioSession.Mode.default, options: .allowBluetooth)
		try audioSession.setActive(true)
	} catch  {
		print("Error messing with audio session: \(error)")
	}
}

Apple Doc

func setCategory(_ category: AVAudioSession.Category,
options: AVAudioSession.CategoryOptions = []) throws

https://developer.apple.com/documentation/avfoundation/avaudiosession/1616442-setcategory

func setCategory(_ category: AVAudioSession.Category,
mode: AVAudioSession.Mode,
options: AVAudioSession.CategoryOptions = []) throws

https://developer.apple.com/documentation/avfoundation/avaudiosession/1771734-setcategory

@CSantosM
Copy link
Contributor

I'm not 100% sure but i think my set up is Xcode 10.2.1 and iOS target upper than 10. I can check the next monday and confirm it.

@hthetiot
Copy link
Contributor

Do not reproduce using Xcode 10.3 and Target 12.4.

Screen Shot 2019-09-20 at 9 31 06 AM

Screen Shot 2019-09-20 at 9 57 19 AM

I merged on the ios 13 branch to see if that related #376

@Skorpeo
Copy link
Author

Skorpeo commented Sep 20, 2019

XCode 10.1 tried with target 10 and 12. I can try to update xcode...

@hthetiot
Copy link
Contributor

Thank you @Skorpeo keep us posted.
Still should be fixed with 3686e5b and 5.0.3 will be released in next 48 hours.

To use Master version you can do that:

cordova plugin remove cordova-plugin-iosrtc --verbose
cordova plugin add https://github.com/cordova-rtc/cordova-plugin-iosrtc#master --verbose
cordova platform remove ios --no-save
cordova platform add ios --no-save

@hthetiot
Copy link
Contributor

Closing the issue cause change made, but @Skorpeo let us know if was related to you environment that can help us to understand.

@hthetiot
Copy link
Contributor

see Requirements for Xcode and cordova version:

@Skorpeo
Copy link
Author

Skorpeo commented Sep 20, 2019

ok i need xcode to stay open right now but will check it out when possible

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants