I have pretty basic function for testing purposes to save a text file to File.app, but the created text file does not ever appear in the File.app.
func saveDocToFiles() {
let file = "DummyFile.txt"
let contents = "some text"
let resourceDocPath = FileManager.default.urls(for: .documentDirectory, in: .userDomainMask).first! //replace with if let
let fileURL = resourceDocPath.appendingPathComponent(file)
do {
try contents.write(to: fileURL, atomically: true, encoding: .utf8)
print("successfully saved - document library \(self.getDocumentsDirectory())")
} catch {
print("oh no could not be saved")
}
}
I've added both keys below:
Application supports iTunes file sharing
Supports opening documents in place
While using a simulator if I browse to the document library the file is created. I've tested this on an actual device and the behavior is the same.
Am I missing a configuration for the file to appear in File.app?
Selecting any option will automatically load the page
Post
Replies
Boosts
Views
Activity
I have a view that I am trying to get to animate on state change either using a transition or animate and so far nothing I've done has worked.
I've tried using withAnimation and .transition in various manners and no luck. Below is a repro and you'll see that the transition is very jagged.
Looking for suggestions on the best approach.
struct StackView: View {
@State var showStack = true
let columns = [
GridItem(.flexible()),
GridItem(.flexible()),
]
var body: some View {
VStack {
if showStack {
ZStack {
ForEach(0 ..< 15) { item in
TileView()
.rotationEffect(.degrees(Double.random(in: 1..<45)))
.transition(.asymmetric(insertion: .move(edge: .leading), removal: .move(edge: .bottom)))
}
}
} else {
LazyVGrid(columns: columns, spacing: 20) {
ForEach(0 ..< 15) { item in
TileView()
.transition(.asymmetric(insertion: .move(edge: .leading), removal: .move(edge: .bottom)))
}
}
}
}
.onAppear {
DispatchQueue.main.asyncAfter(deadline: .now() + 1.9) {
withAnimation(Animation.easeInOut(duration: 1).delay(0.5)) {
showStack = false
}
}
}
}
}
struct TileView: View {
var body: some View {
RoundedRectangle(cornerRadius: 13)
.frame(width: 175, height: 175, alignment: .center)
.foregroundColor(.red)
.shadow(radius: 13)
.overlay(
Text("1")
.font(.largeTitle)
)
.transition(.asymmetric(insertion: .move(edge: .leading), removal: .move(edge: .bottom)))
}
}
I’m migrating some XCTest cases to Swift Testing and hit a runtime error when using tuple arguments within the CI. I don't have an issue when running locally.
[2025-08-21 14:22:13.493] [unit_tests] [WARNING] Could not find test status list for -[FooManagerTests testEndpoint(region:enforce:expectedEndpoint:)]
[2025-08-21 14:22:18.054] [unit_tests] [ERROR] not enough values to unpack (expected 2, got 1)
##[error]Failed to complete Unit Tests -> not enough values to unpack (expected
@Test("Telemetry endpoint routing", arguments: [
(TelemetryRegion.value1, false, Foo.someValue1),
(TelemetryRegion.value2, false, Foo.someValue2),
(TelemetryRegion.value3, true, Foo.someValue3),
(TelemetryRegion.value4, false, Foo.someValue4),
])
func testEndpoint(region: enforce: expectedEndpoint: ) { ... }