-
Notifications
You must be signed in to change notification settings - Fork 21
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
AttributeGraph: cycle detected through attribute xx #10
Comments
Hey @Kyle-Ye, I help out EmergeTools as the maintainer of Pow these days helping out and saw your bug report on Twitter. I haven't seen this issue come up but I don't have much experience with understanding the AttributeGraph either, most of what I'm finding when I start looking for help is related to Xcode beta issues that seem to be resolved or is ChatGPT-generated SEO garbage. I was wondering if you had any leads, or any tools I could use to inspect this, would love to help figure this out so others can use the library without issue! |
You can check my old blog post and use AGDebugKit to debug it. Here below is my finding:
And the cycled graph is the following ⬇️ (AG_PRINT_CYCLES=4)
|
Hey @Kyle-Ye, assuming you mean this blog post I will admit that I'm not as fluent in Chinese as I am in English or Russian. 😅 |
Oh, yeah. I forgot to post an English version for this post. You can read it via Google Translate. If you have anything unclear you can contact me via email in English for the detail. My Preferred languages are: [Chinese > English > Japanese] |
A mini reproductive demo here.
import SwiftUI
import Pow
@main
struct DemoApp: App {
@State private var sheet = false
var body: some Scene {
WindowGroup {
Button("Open Sheet") {
sheet.toggle()
}
.sheet(isPresented: $sheet) {
Text("Demo")
.conditionalEffect(.smoke, condition: true)
}
}
}
} This looks to be an upstream issue and have nothing to do with the repo. Let's track the issue on upstream. EmergeTools/Pow#63 |
Reproduce Steps
Click "Tap to Fix Everything"
Toggle and checkbox and click "Continue"
Line 4 is fine. But before line 6, you will get a warning about "=== AttributeGraph: cycle detected through attribute XXX ==="
This is actually a very dangerous warning and it means your app may crash at any point in a random later time.
Will check and fix it later. Please assign this issue to me
Env:
See related issue here: Kyle-Ye/Forumate#28
The text was updated successfully, but these errors were encountered: