Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

iOS 15 support #401

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

Open
chamira-at wants to merge 6 commits into Polidea:master
base: master
Choose a base branch
Loading
from chamira-at:ios-15-support
Open

Conversation

@chamira-at
Copy link

@chamira-at chamira-at commented Sep 2, 2021

There are some changes to the Core Bluetooth API.

CBService
unowned(unsafe) var peripheral: CBPeripheral { get }
CBCharacteristic
unowned(unsafe) var service: CBService { get }
CBDescriptor
unowned(unsafe) var characteristic: CBCharacteristic { get }
iOS 15.X
CBService
weak var peripheral: CBPeripheral? { get }
CBCharacteristic
weak var service: CBService? { get }
CBDescriptor
weak var characteristic: CBCharacteristic? { get }

The changes are detailed describe here in this issue

Solution:

Made below classes' convenience init(...) methods optional convenience init?(...) and only initialize if pass in params required properties(service, characteristic, descriptors) are not deallocated.

RxBluetoothKit
- Characteristic.swift
- Descriptor.swift

Example

 convenience init?(descriptor: CBDescriptor, peripheral: Peripheral) {
 guard let _characteristic = descriptor.characteristic, let _service = _characteristic.service else {
 return nil
 }
 let service = Service(peripheral: peripheral, service: _service)
 let characteristic = Characteristic(characteristic: _characteristic, service: service)
 self.init(descriptor: descriptor, characteristic: characteristic)
 }

Caller sites have been always guard strogeRefeance therefore, added an extra guard for those that are optionally initializable.

Test

Test cases are update and force unwrapped for those optional initializable objects.

Other improvement

Fixed deprecated method signature warnings.

CSolanaM, levi-terry, stefanomondino, wtpalexander, and HAKASHUN reacted with thumbs up emoji RomanPodymov reacted with hooray emoji
Copy link

CLAassistant commented Sep 2, 2021
edited
Loading

CLA assistant check
All committers have signed the CLA.

@chamira-at chamira-at marked this pull request as ready for review September 3, 2021 07:34
Copy link

CSolanaM commented Sep 23, 2021
edited
Loading

Thank you very much @chamira-at for this PR. A dependency of my project depends on this to unblock me of using the latest Swift version. Looking forward for @robnadin 's review.

chamira-at, gudlaugurellert, and hlazarpesic reacted with thumbs up emoji txusballesteros, chamira-at, and hlazarpesic reacted with heart emoji

Copy link

Likewise @CSolanaM ! Friendly nudge @robnadin ;)

Copy link
Contributor

Likewise @CSolanaM ! Friendly nudge @robnadin ;)

Unfortunately I don't have write access so I'm not able to perform a full review, just thought I'd add my 0ドル.02 to the changes 🙃

CSolanaM, gudlaugurellert, stefanomondino, wtpalexander, and hlazarpesic reacted with thumbs up emoji

Copy link

@minixT friendly nudge! Is there any chance you could have a look at this PR?

CSolanaM, ngarone, socar-ken, GodStas, cherifgh, kkarthikdr, dahlmo, and hlazarpesic reacted with thumbs up emoji

Copy link

can you please have a look on this PR ?

Copy link
Author

@monikamsc Can you please help us reviewing this PR?

cherifgh and hlazarpesic reacted with thumbs up emoji

Copy link
Author

Hi 👋🏽,

Can someone with write access have a look at on this PR and approves it :).

It has been sometime and this PR is really critical for many projects.

Really appreciate your guys hard work and Thank you 🙏🏼

Copy link

Hello,
Will this be released at some point?

Copy link

fraune commented Dec 8, 2022

Is there anything I can do to help get this merged in?

Copy link

RomanPodymov commented Jun 16, 2024
edited
Loading

Hello @mpiechocki @minixT
Can you merge this, please? The master branch is not compiling in Xcode 15.4.

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

Reviewers

6 more reviewers

@robnadin robnadin robnadin left review comments

@cherifgh cherifgh cherifgh approved these changes

@wojo1206 wojo1206 wojo1206 approved these changes

@AllanSobera AllanSobera AllanSobera approved these changes

@lshkolnyk-brightgrove lshkolnyk-brightgrove lshkolnyk-brightgrove approved these changes

Reviewers whose approvals may not affect merge requirements

At least 1 approving review is required to merge this pull request.

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

AltStyle によって変換されたページ (->オリジナル) /