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

Make DynamicLayout Conform to Sendable #49

Merged
merged 1 commit into from
Dec 15, 2024

Conversation

paulhdk
Copy link
Contributor

@paulhdk paulhdk commented Dec 14, 2024

Make DynamicLayout Conform to Sendable

♻️ Current situation & Problem

I was receiving the following error when building SpeziAccount

SpeziAccount/Sources/SpeziAccount/Views/DataEntry/DateOfBirthPicker.swift:102:17
    main actor-isolated property 'layout' can not be mutated from a Sendable closure
                    layout = value
                    ^

The reason for this appears to be that DynamicLayout does not explicitly conform to the Sendable protocol.
This PR adds explicit conformance.

Related: StanfordSpezi/SpeziAccount#82
Related but not necessarily relevant: swiftlang/swift#76648

⚙️ Release Notes

  • Fix a build error in SpeziAccount

📚 Documentation

  • Fix the three build errors/warnings I was receiving.

✅ Testing

With StanfordSpezi/SpeziAccount#82 and the changes in this PR, the build error(s) in SpeziAccount disappear.

📝 Code of Conduct & Contributing Guidelines

By submitting creating this pull request, you agree to follow our Code of Conduct and Contributing Guidelines:

What do you think?

Copy link

codecov bot commented Dec 14, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 74.91%. Comparing base (2997114) to head (5227970).
Report is 1 commits behind head on main.

Additional details and impacted files

Impacted file tree graph

@@           Coverage Diff           @@
##             main      #49   +/-   ##
=======================================
  Coverage   74.91%   74.91%           
=======================================
  Files          52       52           
  Lines        1586     1586           
=======================================
  Hits         1188     1188           
  Misses        398      398           
Files with missing lines Coverage Δ
...ources/SpeziViews/Views/Layout/DynamicHStack.swift 0.00% <ø> (ø)

Continue to review full report in Codecov by Sentry.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 2997114...5227970. Read the comment docs.

@Supereg Supereg merged commit 292a5ac into main Dec 15, 2024
13 checks passed
@Supereg Supereg deleted the add-sendable-conformance-to-DynamicLayout branch December 15, 2024 21:45
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

Successfully merging this pull request may close these issues.

2 participants