Improved progress display
Previously, the progress bar updated only after completing an entire table. For large tables such as LIBARC, this could make the application appear to have stopped responding. Phase 10 updates the interface while rows are being exported.
This commit is contained in:
@@ -5635,7 +5635,7 @@ private struct WorkbenchTableSearchSheet: View {
|
||||
password: PasswordStore.read(profile.id), sql: sql)
|
||||
columns = result.rows.compactMap { $0.first }
|
||||
column = columns.first ?? ""
|
||||
} catch { error = error.localizedDescription }
|
||||
} catch let caughtError { error = caughtError.localizedDescription }
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -5740,7 +5740,7 @@ private struct WorkbenchCSVImportSheet: View {
|
||||
progress = 0
|
||||
completed = false
|
||||
prepareMapping()
|
||||
} catch { error = error.localizedDescription }
|
||||
} catch let caughtError { error = caughtError.localizedDescription }
|
||||
}
|
||||
|
||||
private func prepareMapping() {
|
||||
@@ -5764,7 +5764,7 @@ private struct WorkbenchCSVImportSheet: View {
|
||||
password: PasswordStore.read(profile.id), sql: sql)
|
||||
availableColumns = result.rows.compactMap(\.first)
|
||||
prepareMapping()
|
||||
} catch { error = error.localizedDescription }
|
||||
} catch let caughtError { error = caughtError.localizedDescription }
|
||||
}
|
||||
|
||||
private func importRows() async {
|
||||
@@ -5801,8 +5801,8 @@ private struct WorkbenchCSVImportSheet: View {
|
||||
}
|
||||
completed = true
|
||||
model.loadTables(database: target.database)
|
||||
} catch {
|
||||
error = "Stopped after \(progress) rows: \(error.localizedDescription). Previously inserted rows may remain."
|
||||
} catch let caughtError {
|
||||
error = "Stopped after \(progress) rows: \(caughtError.localizedDescription). Previously inserted rows may remain."
|
||||
}
|
||||
busy = false
|
||||
}
|
||||
|
||||
@@ -0,0 +1,5 @@
|
||||
# Phase 59.1 — Compiler diagnostic fix
|
||||
|
||||
Fixed four error-handler expressions in the Phase 59 table search and CSV import views. Each view had a `@State` property named `error`, and the catch blocks also referenced Swift's implicit caught `error`, resulting in an ambiguous/shadowed reference while type-checking `WorkbenchTableSearchSheet.body` (reported at MainView.swift:5638). The caught exception is now explicitly bound as `caughtError`, and the UI's `error` state retains the human-readable message.
|
||||
|
||||
This is a targeted compiler fix; no dashboard or editor UI redesign. Swift syntax parsing is verified on Linux; native macOS/Xcode compilation must be verified on a Mac.
|
||||
Reference in New Issue
Block a user