Skip to content

Conversation

jamieQ
Copy link

@jamieQ jamieQ commented Oct 9, 2025

No description provided.

@jamieQ jamieQ force-pushed the unknown-default-rule branch from 5631c15 to d748f0d Compare October 9, 2025 13:42
@SwiftLintBot
Copy link

SwiftLintBot commented Oct 9, 2025

3998 Warnings
⚠️ If this is a user-facing change, please include a CHANGELOG entry to credit yourself!
You can find it at CHANGELOG.md.
⚠️ This PR introduced a violation in Aerial: /Resources/MainUI/First time setup/FirstSetupWindowController.swift:105:9: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Aerial: /Resources/MainUI/PanelWindowController.swift:230:9: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Aerial: /Resources/MainUI/PanelWindowController.swift:257:9: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Aerial: /Resources/MainUI/PanelWindowController.swift:275:9: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Aerial: /Resources/MainUI/First time setup/CacheSetupViewController.swift:38:9: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Aerial: /Resources/MainUI/First time setup/TimeSetupViewController.swift:76:9: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Aerial: /Resources/MainUI/Settings panels/SourcesViewController.swift:326:9: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Aerial: /Resources/MainUI/Settings panels/AdvancedViewController.swift:138:17: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Aerial: /Resources/MainUI/VideosViewController.swift:154:9: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Aerial: /Resources/MainUI/VideosViewController.swift:272:9: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Aerial: /Resources/MainUI/VideosViewController.swift:608:9: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Aerial: /Resources/MainUI/Settings panels/TimeViewController.swift:81:9: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Aerial: /Resources/MainUI/Settings panels/TimeViewController.swift:109:9: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Aerial: /Resources/MainUI/Settings panels/TimeViewController.swift:207:9: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Aerial: /Aerial/Source/Models/AerialVideo.swift:141:9: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Aerial: /Aerial/Source/Models/Cache/PoiStringProvider.swift:302:9: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Aerial: /Aerial/Source/Models/Cache/PoiStringProvider.swift:348:9: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Aerial: /Aerial/Source/Models/Extensions/AVAsset+VideoOrientation.swift:27:13: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Aerial: /Aerial/Source/Models/Time/Solar.swift:268:9: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Aerial: /Aerial/Source/Models/Time/TimeManagement.swift:156:9: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Aerial: /Aerial/Source/Models/Time/TimeManagement.swift:281:13: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Aerial: /Aerial/Source/Models/Aerial.swift:220:9: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Aerial: /Aerial/Source/Models/Sources/SourceList.swift:518:13: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Aerial: /Aerial/Source/Models/Sources/VideoList.swift:208:9: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Aerial: /Aerial/Source/Models/Sources/VideoList.swift:399:9: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Aerial: /Aerial/Source/Models/Sources/VideoList.swift:412:9: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Aerial: /Aerial/Source/Views/PrefPanel/InfoCommonView.swift:125:9: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Aerial: /Aerial/Source/Views/Layers/AnimationTextLayer.swift:132:9: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Aerial: /Aerial/Source/Views/Layers/AnimatableLayer.swift:109:9: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Aerial: /Aerial/Source/Views/AerialView.swift:63:9: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Aerial: /Aerial/Source/Views/AerialView.swift:76:9: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Aerial: /Aerial/Source/Views/AerialView.swift:86:9: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Alamofire: /Example/Source/MasterViewController.swift:74:17: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Alamofire: /Example/Source/DetailViewController.swift:100:17: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Alamofire: /Example/Source/DetailViewController.swift:202:9: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Alamofire: /Source/Core/ParameterEncoding.swift:215:9: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Alamofire: /Source/Core/RequestTaskMap.swift:136:9: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Alamofire: /Source/Core/Session.swift:1072:17: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Alamofire: /Source/Features/RequestInterceptor.swift:82:9: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Alamofire: /Source/Features/RequestInterceptor.swift:89:9: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Alamofire: /Source/Core/SessionDelegate.swift:103:9: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Alamofire: /Source/Features/Validation.swift:61:13: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Alamofire: /Source/Extensions/StringEncoding+Alamofire.swift:51:9: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Alamofire: /Source/Features/URLEncodedFormEncoder.swift:561:9: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Alamofire: /Source/Features/URLEncodedFormEncoder.swift:569:9: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Alamofire: /Source/Features/URLEncodedFormEncoder.swift:609:9: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Alamofire: /Source/Features/URLEncodedFormEncoder.swift:948:9: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Alamofire: /Tests/UploadTests.swift:640:9: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Alamofire: /Tests/RequestInterceptorTests.swift:710:9: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Alamofire: /Tests/DataStreamTests.swift:427:17: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Alamofire: /Tests/DataStreamTests.swift:488:17: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Alamofire: /Tests/ConcurrencyTests.swift:724:17: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Alamofire: /Tests/WebSocketTests.swift:415:25: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Alamofire: /Tests/WebSocketTests.swift:711:9: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Alamofire: /watchOS Example/watchOS Example WatchKit Extension/ExtensionDelegate.swift:51:13: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/App/BraveWidgets/FavoritesWidget.swift:110:5: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/App/iOS/Delegates/AppState.swift:145:9: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/App/iOS/Delegates/SceneDelegate.swift:596:5: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/Tests/ClientTests/Web Filters/GroupedAdBlockEngineTests.swift:150:17: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/Tests/ClientTests/AdBlockGroupsManagerTests.swift:194:9: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/Tests/BraveWalletTests/PortfolioStoreTests.swift:417:7: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/Tests/BraveWalletTests/AccountActivityStoreTests.swift:138:7: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/Tests/PlaylistUITests/PlayerModelTests.swift:596:5: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/Sources/BraveVPN/Models/BraveVPNProductInfo.swift:60:7: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/Sources/BraveVPN/Components/Subscription/BraveVPN+Subscription.swift:29:5: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/Sources/BraveVPN/Components/Subscription/BraveVPN+Subscription.swift:46:5: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/Sources/BraveVPN/Components/Subscription/BraveVPN+Promotion.swift:59:5: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/Sources/BraveVPN/Components/Region/BraveVPN+Region.swift:106:5: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/Sources/BraveVPN/BraveVPN.swift:353:7: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/Sources/BraveVPN/BraveVPN.swift:397:5: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/Sources/BraveNews/Composer/FeedDataSource.swift:40:7: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/Sources/BraveNews/Composer/FeedDataSource.swift:50:7: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/Sources/Playlist/PlaylistDownloadManager.swift:605:9: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/Sources/Playlist/PlaylistDownloadManager.swift:796:9: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/Sources/Playlist/PlaylistDownloadManager.swift:1116:9: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/Sources/Web/Chromium/CWVWebViewExtensions.swift:57:5: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/Sources/Web/Chromium/CWVWebViewExtensions.swift:77:5: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/Sources/Web/Chromium/CWVWebViewExtensions.swift:89:5: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/Sources/Web/WebKit/WebKitTabState.swift:108:9: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/Sources/Web/Chromium/TabCWVNavigationHandler.swift:90:7: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/Sources/Web/Chromium/TabCWVUIHandler.swift:165:5: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/Sources/Web/Chromium/ChromiumTabState.swift:545:5: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/Sources/BraveWallet/Settings/DappsSettings.swift:32:5: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/Sources/BraveWallet/Settings/DappsSettings.swift:45:5: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/Sources/BraveWallet/Settings/DappsSettings.swift:56:5: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/Sources/BraveWallet/Crypto/Transaction Confirmations/TransactionConfirmationView.swift:33:5: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/Sources/BraveWallet/Crypto/Stores/NetworkSelectionStore.swift:48:7: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/Sources/BraveWallet/Crypto/Transaction Confirmations/TransactionStatusView.swift:48:5: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/Sources/BraveWallet/Crypto/Transaction Confirmations/TransactionStatusView.swift:159:5: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/Sources/BraveWallet/Crypto/Transaction Confirmations/TransactionStatusView.swift:202:5: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/Sources/BraveWallet/Crypto/Transaction Confirmations/TransactionStatusView.swift:240:5: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/Sources/BraveWallet/Crypto/Transaction Confirmations/TransactionStatusView.swift:506:5: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/Sources/BraveWallet/Crypto/Transaction Confirmations/TransactionStatusView.swift:551:5: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/Sources/BraveWallet/Crypto/Transaction Confirmations/PendingTransactionView.swift:47:5: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/Sources/BraveWallet/Crypto/Stores/AccountActivityStore.swift:373:9: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/Sources/BraveWallet/Crypto/Stores/NetworkStore.swift:219:7: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/Sources/BraveWallet/Crypto/Stores/KeyringStore.swift:571:5: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/Sources/BraveWallet/Crypto/Stores/KeyringStore.swift:680:5: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/Sources/BraveWallet/Crypto/Stores/PortfolioStore.swift:483:15: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/Sources/BraveWallet/Crypto/Stores/SwapTokenStore.swift:1026:7: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/Sources/BraveWallet/Crypto/Stores/SwapTokenStore.swift:1061:7: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/Sources/BraveWallet/Crypto/Stores/TransactionsActivityStore.swift:223:11: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/Sources/BraveWallet/Crypto/Stores/TransactionDetailsStore.swift:221:7: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/Sources/BraveWallet/Crypto/Stores/SendTokenStore.swift:140:7: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/Sources/BraveWallet/Crypto/Stores/SendTokenStore.swift:719:7: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/Sources/BraveWallet/Crypto/Transactions/TransactionDetailsView.swift:352:5: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/Sources/BraveWallet/Crypto/Transactions/TransactionDetailsView.swift:371:5: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/Sources/BraveWallet/Crypto/Transactions/TransactionDetailsView.swift:382:5: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/Sources/BraveWallet/Crypto/Transactions/TransactionDetailsView.swift:622:5: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/Sources/BraveWallet/Crypto/Transactions/TransactionDetailsView.swift:632:5: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/Sources/BraveWallet/Crypto/Transactions/TransactionDetailsView.swift:642:5: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/Sources/BraveWallet/Crypto/Transactions/TransactionSummaryViews.swift:627:5: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/Sources/BraveWallet/Crypto/Transactions/TransactionSummaryViews.swift:637:5: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/Sources/BraveWallet/Crypto/Transactions/TransactionParser.swift:893:11: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/Sources/BraveWallet/Crypto/Scanner/AddressQRCodeScannerView.swift:263:5: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/Sources/BraveWallet/Crypto/Onboarding/BiometricView.swift:43:7: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/Sources/BraveWallet/Panels/WalletPanelView.swift:406:5: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/Sources/BraveWallet/Panels/Connect/NewSiteConnectionView.swift:109:15: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/Sources/BraveWallet/Extensions/BraveWalletSwiftUIExtensions.swift:146:5: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/Sources/BraveWallet/Extensions/SolanaInstruction+Extensions.swift:211:5: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/Sources/BraveWallet/Blockies/Blockies.swift:127:9: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/Sources/BraveWallet/Extensions/BraveWalletExtensions.swift:15:5: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/Sources/BraveWallet/Extensions/BraveWalletExtensions.swift:816:5: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/Sources/BraveStore/Views/StoreKitReceiptSimpleView.swift:196:5: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/Sources/BraveStore/Subscription/SDK/AppStoreSDK.swift:462:5: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/Sources/BraveStore/Subscription/SDK/AppStoreSDK.swift:552:9: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/Sources/BraveStore/Subscription/SDK/AppStoreSDK.swift:614:9: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/Sources/Shared/AppInfo.swift:17:5: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/Sources/Shared/Extensions/UIDeviceExtensions.swift:54:5: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/Sources/Brave/Frontend/Settings/Tabs/PrivateTabsView.swift:34:7: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/Sources/Brave/Frontend/Settings/Tabs/PrivateTabsView.swift:57:5: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ This PR introduced a violation in Brave: /ios/brave-ios/Sources/Brave/Frontend/Settings/General/SearchEngines/Custom Engines/CustomEngineViewController.swift:251:5: Warning: Default switch cases should use the '@unknown' attribute (prefer_unknown_default)
⚠️ Danger found 3998 violations with this PR. Due to GitHub's max issue comment size, the number shown has been truncated to 133.
18 Messages
📖 Building this branch resulted in a binary size of 26243.04 KiB vs 26195.6 KiB when built on main (0% larger).
📖 Linting Aerial with this PR took 0.76 s vs 0.77 s on main (1% faster).
📖 Linting Alamofire with this PR took 0.97 s vs 0.95 s on main (2% slower).
📖 Linting Brave with this PR took 6.82 s vs 6.75 s on main (1% slower).
📖 Linting DuckDuckGo with this PR took 21.23 s vs 21.23 s on main (0% slower).
📖 Linting Firefox with this PR took 10.75 s vs 10.68 s on main (0% slower).
📖 Linting Kickstarter with this PR took 7.55 s vs 7.49 s on main (0% slower).
📖 Linting Moya with this PR took 0.41 s vs 0.41 s on main (0% slower).
📖 Linting NetNewsWire with this PR took 2.37 s vs 2.34 s on main (1% slower).
📖 Linting Nimble with this PR took 0.62 s vs 0.58 s on main (6% slower).
📖 Linting PocketCasts with this PR took 6.92 s vs 6.59 s on main (5% slower).
📖 Linting Quick with this PR took 0.38 s vs 0.39 s on main (2% faster).
📖 Linting Realm with this PR took 3.29 s vs 3.3 s on main (0% faster).
📖 Linting Sourcery with this PR took 1.81 s vs 1.77 s on main (2% slower).
📖 Linting Swift with this PR took 4.09 s vs 4.04 s on main (1% slower).
📖 Linting VLC with this PR took 1.11 s vs 1.08 s on main (2% slower).
📖 Linting Wire with this PR took 17.13 s vs 16.99 s on main (0% slower).
📖 Linting WordPress with this PR took 11.13 s vs 11.11 s on main (0% slower).

Here's an example of your CHANGELOG entry:

* [WIP]: prefer unknown default rule experiments.  
  [jamieQ](https://github.com/jamieQ)
  [#issue_number](https://github.com/realm/SwiftLint/issues/issue_number)

note: There are two invisible spaces after the entry's text.

Generated by 🚫 Danger

@jamieQ jamieQ force-pushed the unknown-default-rule branch from d748f0d to fda9021 Compare October 9, 2025 13:49
@jamieQ jamieQ force-pushed the unknown-default-rule branch from fda9021 to 17b0f20 Compare October 10, 2025 00:34
@jamieQ
Copy link
Author

jamieQ commented Oct 11, 2025

@SimplyDanny a (low priority) question for you regarding the CI failures and warnings here – this rule was motivated by the discussion here and would provide a mechanism to check that switch statements do not have 'bare' default cases to encourage explicit handling of enumeration cases where possible (or explicit opt-outs via a lint rule suppression).

the integration tests currently appear to be failing due to this issue:

...
/Tests/IntegrationTests/IntegrationTests.swift:58: error: -[IntegrationTests.IntegrationTests testSwiftLintAutoCorrects] : XCTAssertTrue failed - Unexpected corrections have been applied

is there test fixture i need to opt out of using this rule when it runs those tests, or what is the expected interaction there?

additionally there are... a lot of Danger warnings about projects for which this rule would introduce new warnings to if enabled. are these expected? i would expect use of this to be fairly niche, and definitely not something enabled by default – i tried to set that up appropriately in the rule's configuration, so wondering if i've missed something. thanks in advance for your time!

@SimplyDanny
Copy link
Collaborator

SimplyDanny commented Oct 11, 2025

the integration tests currently appear to be failing due to this issue:

...
/Tests/IntegrationTests/IntegrationTests.swift:58: error: -[IntegrationTests.IntegrationTests testSwiftLintAutoCorrects] : XCTAssertTrue failed - Unexpected corrections have been applied

is there test fixture i need to opt out of using this rule when it runs those tests, or what is the expected interaction there?

IntegrationTests's job is to run SwiftLint on its own code base respecting its .swiftlint.yml configuration. You may let it run locally to see why it fails.

I approved and ran all actions, so that you can now also see (in the "Files changed" tab of the PR) where the rule would trigger in SwiftLint itself. The fix is to disable the rule in the configuration for this repository, as all rules are enabled by default.

additionally there are... a lot of Danger warnings about projects for which this rule would introduce new warnings to if enabled. are these expected? i would expect use of this to be fairly niche, and definitely not something enabled by default – i tried to set that up appropriately in the rule's configuration, so wondering if i've missed something. thanks in advance for your time!

The setup is correct. When we scan OSS repositories, the rule is enabled in any case though. The intention is to get an idea of which effect a code change would have on these projects. It's quite helpful to disclose special cases you haven't thought of in your initial implementation. Important is to verify that all these findings are valid, i.e., they would be expected if one were to enable the rule in the repository.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants