krz/moonrise

Night-sky companion for iPhone, Apple Watch and Vision Pro: what's up tonight, the Moon, planets, launches and missions, and a Library of the solar system. SwiftUI app with a Cloudflare Workers backend. astronomy cloudflare-workers ios night-sky space swiftui visionos watchos

Commit 3c2e5fd174

3c2e5fd174a5df0f252de17b525799f1988ca830

parent: 2d97f6396e

Unsigned

cmc <hello@cleberg.net> · 2026-11-03 00:29 UTC

Fix two Swift concurrency warnings (!153)

- RemoteImage: `decodes` is a Sendable OperationQueue; nonisolated(unsafe) removed.
- SkyScreen: `faintField` marked nonisolated; FaintKey (nonisolated) read the main-actor static.

iOS simulator build succeeds with no warnings.

Layout: unified · split

App/Sources/RemoteImage.swift +1 −1
@@ -14,7 +14,7 @@ enum ImageLoader {
14 }() 14 }()
15 15
16 // Two decodes at a time; a list otherwise starts one per row at once. 16 // Two decodes at a time; a list otherwise starts one per row at once.
17 nonisolated(unsafe) private static let decodes: OperationQueue = { 17 private static let decodes: OperationQueue = {
18 let q = OperationQueue() 18 let q = OperationQueue()
19 q.maxConcurrentOperationCount = 2 19 q.maxConcurrentOperationCount = 2
20 q.qualityOfService = .userInitiated 20 q.qualityOfService = .userInitiated
App/Sources/SkyScreen.swift +1 −1
@@ -217,7 +217,7 @@ struct SkyScreen: View {
217 217
218 static let minimumField = 3.0 218 static let minimumField = 3.0
219 /// Narrower than this, Tycho-2 stars to V 9 are added around the view. 219 /// Narrower than this, Tycho-2 stars to V 9 are added around the view.
220 static let faintField = 40.0 220 nonisolated static let faintField = 40.0
221 221
222 /// Which faint stars are loaded: the scene's time and place, and the view centre to 2° and field to 5°. 222 /// Which faint stars are loaded: the scene's time and place, and the view centre to 2° and field to 5°.
223 struct FaintKey: Hashable { 223 struct FaintKey: Hashable {