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

Is there a plan to add GRDB 7.0.0 support? #72

Open
foxware00 opened this issue Jan 31, 2025 · 3 comments
Open

Is there a plan to add GRDB 7.0.0 support? #72

foxware00 opened this issue Jan 31, 2025 · 3 comments

Comments

@foxware00
Copy link

Will those using RxGRDB gain a new version given the breaking changes?

Many thanks in advance

@groue
Copy link
Collaborator

groue commented Jan 31, 2025

Hello @foxware00,

I forgot about it! It should be straightforward. Would you mind trying to bump the dependency in Package.swift and run tests? Probably a pull request can be accepted promptly.

@groue
Copy link
Collaborator

groue commented Jan 31, 2025

No, it is not straightforward. RxSwift is not ready for Swift 6, and I can't avoid warnings in this piece of RxGRDB code (DatabaseRegionObservation+Rx.swift):

extension GRDBReactive where Base == DatabaseRegionObservation {
    public func changes(in writer: DatabaseWriter) -> Observable<Database> {
        Observable.create { observer in
            let cancellable = self.base.start(
                in: writer,
                // ⚠️ Converting non-sendable function value to '@Sendable (any Error) -> Void' may introduce data races
                onError: observer.onError,
                // ⚠️ Converting non-sendable function value to '@Sendable (any Error) -> Void' may introduce data races
                onChange: observer.onNext)
            return Disposables.create(with: cancellable.cancel)
        }
    }
}

The warnings are visible in the dev/GRDB7 branch, and this commit in particular: 04ea590

I believe there is some work to be done in RxSwift: See ReactiveX/RxSwift#2639

If you think RxGRDB can avoid this warning, I'm interested. If you think this is not possible, I suggest raising your concern in the RxSwift repository. Please double check: it would not be correct to annoy the RxSwift team if we can avoid it.

groue added a commit that referenced this issue Jan 31, 2025
There remains a warning in DatabaseRegionObservation+Rx.swift.

See #72
@groue
Copy link
Collaborator

groue commented Jan 31, 2025

Rant because Swift 5 ought to be a resting place for libraries like RxGRDB and RxSwift, but the language is too dumb to understand this: https://hachyderm.io/@groue/113924602704476111

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