iOS Playgrounds App version 3.4 seems to be broken ?

The following "Hello World" app fails to run with Error: GeometryProxy cannot be constructed because it has no accessible initializers.

Likewise about 50 to 60 SwiftUI perfectly good programs worked flawlessly before I updated the app about 20 minutes ago. Now, none of them work.

Where is the proper place to report a major of releasing this version of the app ?

Code Block
import SwiftUI
import PlaygroundSupport
struct ContentView: View {
    var body: some View {
        GeometryProxy { geometry in 
            Text("Hello World")
                .frame(width: geometry.size.width * 0.9 )
        }
    }
}
PlaygroundPage.current.setLiveView( ContentView() )

Answered by pfurbacher in 647805022
I am also encountering numerous problems with the update to 3.4 (1302.27). They range from

Code Block
The operation couldn’t be completed. (PlaygroundBuild.BuildSystem.BuildError error 0.)


to playground pages just aborting with the error flag saying

Code Block
There was a problem encountered while running this playground. Check your [previously fine and executable!] code.


(Note: in case it’s not obvious, I added the comment enclosed by the brackets.)

And in one case, there’s even a thread dump — this is from a playground which was just fine 2 days ago:

Code Block
remoteProcessWasInterrupted
Error: Fatal error: file SwiftUI, line 0 ... [thread dump elided]


It is nice to have a console and somewhat better error reporting, but yikes, this update has delivered disaster after disaster — perfectly working playgrounds in which I have a lot of effort invested are now trash.

I have only an iPad to write playgrounds, and therefore don’t have access to possibly better error analysis in Xcode. Pretty frustrating.

Feedback Assistant is where you can file bug reports. You may have to sign in to a Developer account (you don’t have to be a paying developer; just the “free” level). The problem is that when filing a bug report, you should submit the simplest case which reproduces the error. That’s going to be nigh impossible distilling such a case from fairly large projects containing complex code.
Sorry, I do not have an iPad capable of running Swift Playground ver.3.4, but the shown code is not perfectly good.

It should be something like this in SwiftUI for developing apps:
Code Block
struct ContentView: View {
var body: some View {
GeometryReader { geometry in
Text("Hello World")
.frame(width: geometry.size.width * 0.9 )
}
}
}

I guess that the implementation of SwiftUI in older versions of Swift Playground was broken and is fixed in 3.4.
Accepted Answer
I am also encountering numerous problems with the update to 3.4 (1302.27). They range from

Code Block
The operation couldn’t be completed. (PlaygroundBuild.BuildSystem.BuildError error 0.)


to playground pages just aborting with the error flag saying

Code Block
There was a problem encountered while running this playground. Check your [previously fine and executable!] code.


(Note: in case it’s not obvious, I added the comment enclosed by the brackets.)

And in one case, there’s even a thread dump — this is from a playground which was just fine 2 days ago:

Code Block
remoteProcessWasInterrupted
Error: Fatal error: file SwiftUI, line 0 ... [thread dump elided]


It is nice to have a console and somewhat better error reporting, but yikes, this update has delivered disaster after disaster — perfectly working playgrounds in which I have a lot of effort invested are now trash.

I have only an iPad to write playgrounds, and therefore don’t have access to possibly better error analysis in Xcode. Pretty frustrating.

Feedback Assistant is where you can file bug reports. You may have to sign in to a Developer account (you don’t have to be a paying developer; just the “free” level). The problem is that when filing a bug report, you should submit the simplest case which reproduces the error. That’s going to be nigh impossible distilling such a case from fairly large projects containing complex code.
Not the same issue, but it does appear that 3.4 is having some issues. The ForEach loop isn't working as expected, it will iterate through the data, but it doesn't render correctly whatever is in the brackets.

Code Block Swift
struct ContentView: View {
    var body: some View {
        VStack(alignment: .leading) {
            /*Text("TEST")*/
            ForEach((1...5), id: \.self) { index in
                Text("TEST TEST")
            }
        }
        .foregroundColor(Color.green)
        .background(Color.red)
    }
}
PlaygroundPage.current.setLiveView(ContentView())


When run in the playground, the Text view inside for ForEach loop does not display the text, but the background color does show that the view is there, but the text just doesn't get displayed. When the Text view outside of the ForEach loop is uncommented and ran, an alert appears stating "There was a problem running this playground. Please check your code and try again." I copied over the code to Xcode, and it ran as expected. I'm on the new iPadOS developer beta and playgrounds 3.4.
I am in agreement with OOPer, But I still have a problem after correcting the miss-type. I did miss-typed (by hand) the quick test program into this post - not sure why I posted GeometryProxy as opposed to GeometryReader as it is in my test program in Playgrounds correctly. So this code fails with the error message “Abort() called” on the line for Text(“Hello World)


Code Block
import SwiftUI
import PlaygroundSupport
struct ContentView: View {
    var body: some View {
        GeometryReader { geometry in 
            Text("Hello World")
                .frame(width: geometry.size.width * 0.9 )
        }
    }
}
PlaygroundPage.current.setLiveView( ContentView() )


(This code was copied and pasted, directly from the failing program ... sorry for the original mistype. I can’t seem to find a way to edit the original post. )



Paul Hudson recommended to file a feedback at Feedbackassistant. So I did:
Feedback Assistant - https://feedbackassistant.apple.com/feedback/8923682
iOS Playgrounds App version 3.4 seems to be broken ?
 
 
Q