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

Realm 10.50.0 Cocoapods compile warning #8582

Closed
bb-git opened this issue May 8, 2024 · 6 comments
Closed

Realm 10.50.0 Cocoapods compile warning #8582

bb-git opened this issue May 8, 2024 · 6 comments

Comments

@bb-git
Copy link

bb-git commented May 8, 2024

How frequently does the bug occur?

Always

Description

I don't know if this is something crucial, but we see this warning when using cocoapods, but it's not appearing when using SPM. Any idea, why this is happening?

Showing Recent Issues
/Pods/RealmSwift/RealmSwift/Realm.swift:1351:23: Passing argument of non-sendable type 'RLMRealm' outside of actor-isolated context may introduce data races

Stacktrace & log output

No response

Can you reproduce the bug?

Always

Reproduction Steps

No response

Version

10.50.0

What Atlas Services are you using?

Local Database only

Are you using encryption?

Yes

Platform OS and version(s)

iOS 17.4

Build environment

Xcode version: 15.3
Dependency manager and version: Cocoapods 1.15.2

Copy link

sync-by-unito bot commented May 8, 2024

➤ PM Bot commented:

Jira ticket: RCOCOA-2356

@Jaycyn
Copy link

Jaycyn commented May 8, 2024

I built a clean Realm project, following installation guide for Cocoapods exactly and received the exact same message

non-sendable

I also noted a another issue with this clean podfile install. While tracking it down, things suddenly started working and the non-sendable type 'RLMRealm' outside of actor-isolated context may introduce data races error went away. They appeared to be unrelated but adding this just in case

Sandboxing: Sandbox: rsync.samba(code) deny(1) file-read-data... some path

Sandboxing

To fix: in Build Settings, had to set User Script Sandboxing to NO

UserScriptSandboxing

then in Signing and Capabilities, had to check Incoming and Outgoing in the Network settings. I usually just removed that entirely but that didn't work, but this did.

Network

Once I made those changes, all of the errors went away.

Again - a 100% totally clean brand new Realm Test project with no other code, following the installation guide.

Realm 10.50.0
XCode 15.3
Cocoapods 1.15.2
Sonoma 14.2.1
macOS project

and my podfile

project 'Realm Test'
target 'Realm Test' do
  use_frameworks!
  platform :osx, '14.0'
  pod 'RealmSwift', '~>10'
end

I have no idea what the relationship is between the error but at least I am back to coding.

@tgoyne
Copy link
Member

tgoyne commented May 8, 2024

This is an expected warning when building Realm with sendability checking enabled which we should be able to fix in Swift 6 but cannot in Swift 5.

@Jaycyn
Copy link

Jaycyn commented May 8, 2024

@tgoyne Cool. Thanks for the update.

Any idea why the project I just created, which exhibited the same issue, suddenly stopped flagging with the error after I made the changes noted above?

@bb-git
Copy link
Author

bb-git commented May 8, 2024

@tgoyne so just to be clear, it's all fine to use it like this?
or are any changes necessary?
Thanks

@nirinchev
Copy link
Member

it's fine to use it like this.

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

4 participants