Skip to content

Conversation

robmaceachern
Copy link
Member

@robmaceachern robmaceachern commented Aug 22, 2025

  • Bump perception to 2.0
  • tuist install --update --path Samples to update Sample resolved dependencies

This bumps the pointfreeco/swift-perception dependency to 2.0 which includes a memory leak fix and improved perception check performance (that our developers have complained about in the past).

Checklist

  • Unit Tests
  • UI Tests
  • Snapshot Tests (iOS only)
  • I have made corresponding changes to the documentation
  • To make integration smoother, we should add the updated Perception (and it's sub-dependencies) to the SPM registry before we land this (cc @watt)

@robmaceachern robmaceachern changed the title chore: Bump Perception to 2.0.5 chore: Bump Perception to 2.0 Aug 22, 2025
@robmaceachern robmaceachern marked this pull request as ready for review August 22, 2025 22:02
@robmaceachern robmaceachern requested a review from a team as a code owner August 22, 2025 22:02
@robmaceachern robmaceachern requested a review from watt August 22, 2025 22:02
@@ -59,7 +59,7 @@ let package = Package(
.package(url: "https://github.com/pointfreeco/swift-case-paths", from: "1.5.5"),
.package(url: "https://github.com/pointfreeco/swift-identified-collections", from: "1.0.0"),
.package(url: "https://github.com/pointfreeco/swift-macro-testing", from: "0.4.0"),
.package(url: "https://github.com/pointfreeco/swift-perception", from: "1.5.0"),
.package(url: "https://github.com/pointfreeco/swift-perception", from: "2.0.0"),
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

(commenting here for threading support) – just an FYI, but i believe the 'memory leak fix' was reverted from the 6.2 release branch (see here). idk exactly how that corresponds to what's in any given Xcode beta. sadly no justification was given in any of the PRs so not sure what the underlying motivation was.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh interesting. It looks like the pointfree folks haven't removed it from their backport at this point...

Pinged them about it here: pointfreeco/swift-perception#153

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We'll look into getting those changes into Perception soon. I pinged their PR for more context, so hopefully they can provide some.

@robmaceachern robmaceachern requested a review from a team as a code owner August 25, 2025 16:37
Comment on lines +39 to +41
if tracker.isComplete == false {
XCTFail("state.child should not change.")
}
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is the same kind of approach used in Perception now: https://github.com/pointfreeco/swift-perception/blob/main/Tests/PerceptionTests/PerceptionTrackingTests.swift#L32

The issue is that the registrar deinit pathway will now trigger an onChange which we don't really want to "count" in this context.

Related to pointfreeco/swift-perception#153

image

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.

3 participants