Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add balanced_blank_lines opt-in rule validating leading and trailing blank lines in bodies #2242

Closed
wants to merge 1 commit into from

Conversation

Johennes
Copy link

Closes #2241

@Johennes
Copy link
Author

The code in here could probably use some simplification but I first wanted to get feedback on whether the approach of combining a regex search with structure analysis would be appropriate here.

@SwiftLintBot
Copy link

2233 Warnings
⚠️ This PR introduced a violation in Aerial: /Users/distiller/project/osscheck/Aerial/Aerial/App/AppDelegate.swift:50:1: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 916, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 920, _cache: Swift.String.Index._Cache.utf16)))) / (count: 0, range: nil)) (balanced_blank_lines)
⚠️ This PR introduced a violation in Aerial: /Users/distiller/project/osscheck/Aerial/Aerial/Source/Controllers/Preferences.swift:145:1: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 780, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 800, _cache: Swift.String.Index._Cache.utf16)))) / (count: 0, range: nil)) (balanced_blank_lines)
⚠️ This PR introduced a violation in Aerial: /Users/distiller/project/osscheck/Aerial/Aerial/Source/Models/Cache/AssetLoaderDelegate.swift:85:64: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 11060, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 11096, _cache: Swift.String.Index._Cache.utf16)))) / (count: 0, range: nil)) (balanced_blank_lines)
⚠️ This PR introduced a violation in Aerial: /Users/distiller/project/osscheck/Aerial/Aerial/Source/Models/Cache/VideoCache.swift:218:84: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 28808, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 28844, _cache: Swift.String.Index._Cache.utf16)))) / (count: 0, range: nil)) (balanced_blank_lines)
⚠️ This PR introduced a violation in Aerial: /Users/distiller/project/osscheck/Aerial/Aerial/Source/Models/Cache/VideoCache.swift:234:92: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 31256, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 31292, _cache: Swift.String.Index._Cache.utf16)))) / (count: 0, range: nil)) (balanced_blank_lines)
⚠️ This PR introduced a violation in Aerial: /Users/distiller/project/osscheck/Aerial/Aerial/Source/Models/Cache/VideoLoader.swift:77:86: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 10932, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 10968, _cache: Swift.String.Index._Cache.utf16)))) / (count: 0, range: nil)) (balanced_blank_lines)
⚠️ This PR introduced a violation in Aerial: /Users/distiller/project/osscheck/Aerial/Aerial/Source/Models/Cache/VideoLoader.swift:112:58: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 16620, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 16688, _cache: Swift.String.Index._Cache.utf16)))) / (count: 0, range: nil)) (balanced_blank_lines)
⚠️ This PR introduced a violation in Aerial: /Users/distiller/project/osscheck/Aerial/Aerial/Source/Models/Cache/VideoLoader.swift:151:13: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 0, range: nil) / (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 24136, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 24204, _cache: Swift.String.Index._Cache.utf16))))) (balanced_blank_lines)
⚠️ This PR introduced a violation in Aerial: /Users/distiller/project/osscheck/Aerial/Aerial/Source/Models/Cache/VideoLoader.swift:93:75: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 12964, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 13000, _cache: Swift.String.Index._Cache.utf16)))) / (count: 0, range: nil)) (balanced_blank_lines)
⚠️ This PR introduced a violation in Aerial: /Users/distiller/project/osscheck/Aerial/Aerial/Source/Models/Cache/VideoLoader.swift:160:68: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 25228, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 25232, _cache: Swift.String.Index._Cache.utf16)))) / (count: 0, range: nil)) (balanced_blank_lines)
⚠️ This PR introduced a violation in Aerial: /Users/distiller/project/osscheck/Aerial/Aerial/Source/Models/Cache/VideoLoader.swift:168:84: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 26196, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 26232, _cache: Swift.String.Index._Cache.utf16)))) / (count: 0, range: nil)) (balanced_blank_lines)
⚠️ This PR introduced a violation in Aerial: /Users/distiller/project/osscheck/Aerial/Aerial/Source/Models/Cache/VideoLoader.swift:202:67: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 31004, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 31040, _cache: Swift.String.Index._Cache.utf16)))) / (count: 0, range: nil)) (balanced_blank_lines)
⚠️ This PR introduced a violation in Aerial: /Users/distiller/project/osscheck/Aerial/Aerial/Source/Models/Cache/VideoLoader.swift:238:1: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 0, range: nil) / (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 36884, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 36888, _cache: Swift.String.Index._Cache.utf16))))) (balanced_blank_lines)
⚠️ This PR introduced a violation in Aerial: /Users/distiller/project/osscheck/Aerial/Aerial/Source/Models/Cache/VideoDownload.swift:88:5: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 0, range: nil) / (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 10928, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 10964, _cache: Swift.String.Index._Cache.utf16))))) (balanced_blank_lines)
⚠️ This PR introduced a violation in Aerial: /Users/distiller/project/osscheck/Aerial/Aerial/Source/Models/Cache/VideoDownload.swift:138:9: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 0, range: nil) / (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 18040, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 18044, _cache: Swift.String.Index._Cache.utf16))))) (balanced_blank_lines)
⚠️ This PR introduced a violation in Aerial: /Users/distiller/project/osscheck/Aerial/Aerial/Source/Models/Cache/VideoDownload.swift:178:5: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 0, range: nil) / (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 23796, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 23832, _cache: Swift.String.Index._Cache.utf16))))) (balanced_blank_lines)
⚠️ This PR introduced a violation in Aerial: /Users/distiller/project/osscheck/Aerial/Aerial/Source/Models/Cache/VideoDownload.swift:180:49: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 24076, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 24112, _cache: Swift.String.Index._Cache.utf16)))) / (count: 0, range: nil)) (balanced_blank_lines)
⚠️ This PR introduced a violation in Aerial: /Users/distiller/project/osscheck/Aerial/Aerial/Source/Controllers/PreferencesWindowController.swift:22:1: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 0, range: nil) / (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 1488, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 1508, _cache: Swift.String.Index._Cache.utf16))))) (balanced_blank_lines)
⚠️ This PR introduced a violation in Aerial: /Users/distiller/project/osscheck/Aerial/Aerial/Source/Controllers/PreferencesWindowController.swift:73:5: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 0, range: nil) / (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 7260, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 7296, _cache: Swift.String.Index._Cache.utf16))))) (balanced_blank_lines)
⚠️ This PR introduced a violation in Aerial: /Users/distiller/project/osscheck/Aerial/Aerial/Source/Controllers/PreferencesWindowController.swift:259:5: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 0, range: nil) / (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 31304, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 31308, _cache: Swift.String.Index._Cache.utf16))))) (balanced_blank_lines)
⚠️ This PR introduced a violation in Aerial: /Users/distiller/project/osscheck/Aerial/Aerial/Source/Controllers/PreferencesWindowController.swift:294:5: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 0, range: nil) / (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 35036, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 35072, _cache: Swift.String.Index._Cache.utf16))))) (balanced_blank_lines)
⚠️ This PR introduced a violation in Aerial: /Users/distiller/project/osscheck/Aerial/Aerial/Source/Controllers/PreferencesWindowController.swift:484:13: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 0, range: nil) / (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 59836, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 59904, _cache: Swift.String.Index._Cache.utf16))))) (balanced_blank_lines)
⚠️ This PR introduced a violation in Aerial: /Users/distiller/project/osscheck/Aerial/Tests/PreferencesTests.swift:29:1: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 884, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 904, _cache: Swift.String.Index._Cache.utf16)))) / (count: 0, range: nil)) (balanced_blank_lines)
⚠️ This PR introduced a violation in Aerial: /Users/distiller/project/osscheck/Aerial/Aerial/Source/Models/ManifestLoader.swift:75:9: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 0, range: nil) / (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 8616, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 8668, _cache: Swift.String.Index._Cache.utf16))))) (balanced_blank_lines)
⚠️ This PR introduced a violation in Alamofire: /Users/distiller/project/osscheck/Alamofire/Example/Source/AppDelegate.swift:64:1: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 5296, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 5300, _cache: Swift.String.Index._Cache.utf16)))) / (count: 0, range: nil)) (balanced_blank_lines)
⚠️ This PR introduced a violation in Alamofire: /Users/distiller/project/osscheck/Alamofire/Example/Source/MasterViewController.swift:96:1: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 5184, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 5188, _cache: Swift.String.Index._Cache.utf16)))) / (count: 0, range: nil)) (balanced_blank_lines)
⚠️ This PR introduced a violation in Alamofire: /Users/distiller/project/osscheck/Alamofire/Source/MultipartFormData.swift:580:1: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 9084, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 9088, _cache: Swift.String.Index._Cache.utf16)))) / (count: 0, range: nil)) (balanced_blank_lines)
⚠️ This PR introduced a violation in Alamofire: /Users/distiller/project/osscheck/Alamofire/Source/ParameterEncoding.swift:315:1: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 13356, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 13360, _cache: Swift.String.Index._Cache.utf16)))) / (count: 0, range: nil)) (balanced_blank_lines)
⚠️ This PR introduced a violation in Alamofire: /Users/distiller/project/osscheck/Alamofire/Source/ParameterEncoding.swift:402:1: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 54132, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 54136, _cache: Swift.String.Index._Cache.utf16)))) / (count: 0, range: nil)) (balanced_blank_lines)
⚠️ This PR introduced a violation in Alamofire: /Users/distiller/project/osscheck/Alamofire/Source/ParameterEncoding.swift:477:1: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 67868, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 67872, _cache: Swift.String.Index._Cache.utf16)))) / (count: 0, range: nil)) (balanced_blank_lines)
⚠️ This PR introduced a violation in Alamofire: /Users/distiller/project/osscheck/Alamofire/Source/Request.swift:237:1: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 13704, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 13708, _cache: Swift.String.Index._Cache.utf16)))) / (count: 0, range: nil)) (balanced_blank_lines)
⚠️ This PR introduced a violation in Alamofire: /Users/distiller/project/osscheck/Alamofire/Source/Request.swift:418:1: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 51648, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 51652, _cache: Swift.String.Index._Cache.utf16)))) / (count: 0, range: nil)) (balanced_blank_lines)
⚠️ This PR introduced a violation in Alamofire: /Users/distiller/project/osscheck/Alamofire/Source/Request.swift:553:1: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 61768, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 61772, _cache: Swift.String.Index._Cache.utf16)))) / (count: 0, range: nil)) (balanced_blank_lines)
⚠️ This PR introduced a violation in Alamofire: /Users/distiller/project/osscheck/Alamofire/Source/Request.swift:626:1: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 83432, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 83436, _cache: Swift.String.Index._Cache.utf16)))) / (count: 0, range: nil)) (balanced_blank_lines)
⚠️ This PR introduced a violation in Alamofire: /Users/distiller/project/osscheck/Alamofire/Source/TaskDelegate.swift:183:1: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 5832, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 5836, _cache: Swift.String.Index._Cache.utf16)))) / (count: 0, range: nil)) (balanced_blank_lines)
⚠️ This PR introduced a violation in Alamofire: /Users/distiller/project/osscheck/Alamofire/Source/TaskDelegate.swift:300:1: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 27424, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 27428, _cache: Swift.String.Index._Cache.utf16)))) / (count: 0, range: nil)) (balanced_blank_lines)
⚠️ This PR introduced a violation in Alamofire: /Users/distiller/project/osscheck/Alamofire/Source/TaskDelegate.swift:417:1: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 42472, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 42476, _cache: Swift.String.Index._Cache.utf16)))) / (count: 0, range: nil)) (balanced_blank_lines)
⚠️ This PR introduced a violation in Alamofire: /Users/distiller/project/osscheck/Alamofire/Source/TaskDelegate.swift:466:1: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 57492, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 57496, _cache: Swift.String.Index._Cache.utf16)))) / (count: 0, range: nil)) (balanced_blank_lines)
⚠️ This PR introduced a violation in Alamofire: /Users/distiller/project/osscheck/Alamofire/Source/Validation.swift:153:1: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 4968, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 4972, _cache: Swift.String.Index._Cache.utf16)))) / (count: 0, range: nil)) (balanced_blank_lines)
⚠️ This PR introduced a violation in Alamofire: /Users/distiller/project/osscheck/Alamofire/Tests/AFError+AlamofireTests.swift:176:1: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 5012, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 5016, _cache: Swift.String.Index._Cache.utf16)))) / (count: 0, range: nil)) (balanced_blank_lines)
⚠️ This PR introduced a violation in Alamofire: /Users/distiller/project/osscheck/Alamofire/Source/SessionDelegate.swift:235:1: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 5384, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 5388, _cache: Swift.String.Index._Cache.utf16)))) / (count: 0, range: nil)) (balanced_blank_lines)
⚠️ This PR introduced a violation in Alamofire: /Users/distiller/project/osscheck/Alamofire/Source/SessionManager.swift:896:1: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 5436, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 5440, _cache: Swift.String.Index._Cache.utf16)))) / (count: 0, range: nil)) (balanced_blank_lines)
⚠️ This PR introduced a violation in Alamofire: /Users/distiller/project/osscheck/Alamofire/Tests/FileManager+AlamofireTests.swift:88:1: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 5048, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 5052, _cache: Swift.String.Index._Cache.utf16)))) / (count: 0, range: nil)) (balanced_blank_lines)
⚠️ This PR introduced a violation in Alamofire: /Users/distiller/project/osscheck/Alamofire/Tests/NetworkReachabilityManagerTests.swift:250:1: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 5472, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 5476, _cache: Swift.String.Index._Cache.utf16)))) / (count: 0, range: nil)) (balanced_blank_lines)
⚠️ This PR introduced a violation in Alamofire: /Users/distiller/project/osscheck/Alamofire/Tests/CacheTests.swift:355:1: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 9660, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 9664, _cache: Swift.String.Index._Cache.utf16)))) / (count: 0, range: nil)) (balanced_blank_lines)
⚠️ This PR introduced a violation in Alamofire: /Users/distiller/project/osscheck/Alamofire/Tests/ParameterEncodingTests.swift:655:1: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 5868, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 5872, _cache: Swift.String.Index._Cache.utf16)))) / (count: 0, range: nil)) (balanced_blank_lines)
⚠️ This PR introduced a violation in Alamofire: /Users/distiller/project/osscheck/Alamofire/Tests/ParameterEncodingTests.swift:891:1: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 103832, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 103836, _cache: Swift.String.Index._Cache.utf16)))) / (count: 0, range: nil)) (balanced_blank_lines)
⚠️ This PR introduced a violation in Alamofire: /Users/distiller/project/osscheck/Alamofire/Tests/ResponseSerializationTests.swift:571:1: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 6452, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 6456, _cache: Swift.String.Index._Cache.utf16)))) / (count: 0, range: nil)) (balanced_blank_lines)
⚠️ This PR introduced a violation in Alamofire: /Users/distiller/project/osscheck/Alamofire/Tests/ResponseSerializationTests.swift:1204:1: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 74720, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 74724, _cache: Swift.String.Index._Cache.utf16)))) / (count: 0, range: nil)) (balanced_blank_lines)
⚠️ This PR introduced a violation in Alamofire: /Users/distiller/project/osscheck/Alamofire/Tests/SessionDelegateTests.swift:533:88: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 78656, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 78660, _cache: Swift.String.Index._Cache.utf16)))) / (count: 0, range: nil)) (balanced_blank_lines)
⚠️ This PR introduced a violation in Alamofire: /Users/distiller/project/osscheck/Alamofire/Tests/SessionDelegateTests.swift:569:88: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 84052, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 84056, _cache: Swift.String.Index._Cache.utf16)))) / (count: 0, range: nil)) (balanced_blank_lines)
⚠️ This PR introduced a violation in Alamofire: /Users/distiller/project/osscheck/Alamofire/Tests/SessionManagerTests.swift:778:1: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 5268, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 5272, _cache: Swift.String.Index._Cache.utf16)))) / (count: 0, range: nil)) (balanced_blank_lines)
⚠️ This PR introduced a violation in Alamofire: /Users/distiller/project/osscheck/Alamofire/Tests/URLProtocolTests.swift:91:1: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 5188, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 5192, _cache: Swift.String.Index._Cache.utf16)))) / (count: 0, range: nil)) (balanced_blank_lines)
⚠️ This PR introduced a violation in Alamofire: /Users/distiller/project/osscheck/Alamofire/Tests/URLProtocolTests.swift:110:1: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 13008, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 13012, _cache: Swift.String.Index._Cache.utf16)))) / (count: 0, range: nil)) (balanced_blank_lines)
⚠️ This PR introduced a violation in Alamofire: /Users/distiller/project/osscheck/Alamofire/Tests/UploadTests.swift:691:1: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 37068, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 37072, _cache: Swift.String.Index._Cache.utf16)))) / (count: 0, range: nil)) (balanced_blank_lines)
⚠️ This PR introduced a violation in Alamofire: /Users/distiller/project/osscheck/Alamofire/Tests/ServerTrustPolicyTests.swift:578:1: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 62256, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 62260, _cache: Swift.String.Index._Cache.utf16)))) / (count: 0, range: nil)) (balanced_blank_lines)
⚠️ This PR introduced a violation in Alamofire: /Users/distiller/project/osscheck/Alamofire/Tests/ServerTrustPolicyTests.swift:778:1: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 88928, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 88932, _cache: Swift.String.Index._Cache.utf16)))) / (count: 0, range: nil)) (balanced_blank_lines)
⚠️ This PR introduced a violation in Alamofire: /Users/distiller/project/osscheck/Alamofire/Tests/ServerTrustPolicyTests.swift:1211:1: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 119436, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 119440, _cache: Swift.String.Index._Cache.utf16)))) / (count: 0, range: nil)) (balanced_blank_lines)
⚠️ This PR introduced a violation in Alamofire: /Users/distiller/project/osscheck/Alamofire/Tests/ServerTrustPolicyTests.swift:1526:1: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 184440, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 184444, _cache: Swift.String.Index._Cache.utf16)))) / (count: 0, range: nil)) (balanced_blank_lines)
⚠️ This PR introduced a violation in Firefox: /Users/distiller/project/osscheck/Firefox/Account/FxAClient10.swift:468:132: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 77748, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 77816, _cache: Swift.String.Index._Cache.utf16)))) / (count: 0, range: nil)) (balanced_blank_lines)
⚠️ This PR introduced a violation in Firefox: /Users/distiller/project/osscheck/Firefox/Account/FxAClient10.swift:566:1: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 86668, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 86672, _cache: Swift.String.Index._Cache.utf16)))) / (count: 0, range: nil)) (balanced_blank_lines)
⚠️ This PR introduced a violation in Firefox: /Users/distiller/project/osscheck/Firefox/Account/TokenServerClient.swift:159:32: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 25804, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 25808, _cache: Swift.String.Index._Cache.utf16)))) / (count: 0, range: nil)) (balanced_blank_lines)
⚠️ This PR introduced a violation in Firefox: /Users/distiller/project/osscheck/Firefox/Client/Application/DebugSettingsBundleOptions.swift:18:1: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 1044, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 1048, _cache: Swift.String.Index._Cache.utf16)))) / (count: 0, range: nil)) (balanced_blank_lines)
⚠️ This PR introduced a violation in Firefox: /Users/distiller/project/osscheck/Firefox/Client/Application/QuickActions.swift:93:154: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 16972, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 16976, _cache: Swift.String.Index._Cache.utf16)))) / (count: 0, range: nil)) (balanced_blank_lines)
⚠️ This PR introduced a violation in Firefox: /Users/distiller/project/osscheck/Firefox/Client/Application/QuickActions.swift:142:1: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 3460, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 3464, _cache: Swift.String.Index._Cache.utf16)))) / (count: 0, range: nil)) (balanced_blank_lines)
⚠️ This PR introduced a violation in Firefox: /Users/distiller/project/osscheck/Firefox/Client/Application/NavigationRouter.swift:149:182: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 24848, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 24852, _cache: Swift.String.Index._Cache.utf16)))) / (count: 0, range: nil)) (balanced_blank_lines)
⚠️ This PR introduced a violation in Firefox: /Users/distiller/project/osscheck/Firefox/Client/Extensions/SnapKitExtensions.swift:16:1: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 1036, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 1040, _cache: Swift.String.Index._Cache.utf16)))) / (count: 0, range: nil)) (balanced_blank_lines)
⚠️ This PR introduced a violation in Firefox: /Users/distiller/project/osscheck/Firefox/Client/Extensions/NSURLExtensionsMailTo.swift:55:1: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 2020, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 2024, _cache: Swift.String.Index._Cache.utf16)))) / (count: 0, range: nil)) (balanced_blank_lines)
⚠️ This PR introduced a violation in Firefox: /Users/distiller/project/osscheck/Firefox/Client/Extensions/UIImageViewExtensions.swift:69:1: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 1192, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 1196, _cache: Swift.String.Index._Cache.utf16)))) / (count: 0, range: nil)) (balanced_blank_lines)
⚠️ This PR introduced a violation in Firefox: /Users/distiller/project/osscheck/Firefox/Client/Application/AppDelegate.swift:222:120: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 37744, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 37748, _cache: Swift.String.Index._Cache.utf16)))) / (count: 0, range: nil)) (balanced_blank_lines)
⚠️ This PR introduced a violation in Firefox: /Users/distiller/project/osscheck/Firefox/Client/Application/AppDelegate.swift:260:67: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 44588, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 44592, _cache: Swift.String.Index._Cache.utf16)))) / (count: 0, range: nil)) (balanced_blank_lines)
⚠️ This PR introduced a violation in Firefox: /Users/distiller/project/osscheck/Firefox/Client/Application/AppDelegate.swift:407:147: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 69884, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 69888, _cache: Swift.String.Index._Cache.utf16)))) / (count: 0, range: nil)) (balanced_blank_lines)
⚠️ This PR introduced a violation in Firefox: /Users/distiller/project/osscheck/Firefox/Client/Frontend/Accessors/HomePageAccessors.swift:25:1: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 1648, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 1652, _cache: Swift.String.Index._Cache.utf16)))) / (count: 0, range: nil)) (balanced_blank_lines)
⚠️ This PR introduced a violation in Firefox: /Users/distiller/project/osscheck/Firefox/Client/Extensions/UIAlertControllerExtensions.swift:25:81: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 4352, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 4356, _cache: Swift.String.Index._Cache.utf16)))) / (count: 0, range: nil)) (balanced_blank_lines)
⚠️ This PR introduced a violation in Firefox: /Users/distiller/project/osscheck/Firefox/Client/Extensions/UIAlertControllerExtensions.swift:157:53: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 26724, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 26728, _cache: Swift.String.Index._Cache.utf16)))) / (count: 0, range: nil)) (balanced_blank_lines)
⚠️ This PR introduced a violation in Firefox: /Users/distiller/project/osscheck/Firefox/Client/Extensions/UIAlertControllerExtensions.swift:190:1: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 1632, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 1636, _cache: Swift.String.Index._Cache.utf16)))) / (count: 0, range: nil)) (balanced_blank_lines)
⚠️ This PR introduced a violation in Firefox: /Users/distiller/project/osscheck/Firefox/Client/Frontend/AuthenticationManager/SensitiveViewController.swift:27:5: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 0, range: nil) / (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 4996, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 5000, _cache: Swift.String.Index._Cache.utf16))))) (balanced_blank_lines)
⚠️ This PR introduced a violation in Firefox: /Users/distiller/project/osscheck/Firefox/Client/Frontend/Browser/BackForwardListAnimator.swift:33:1: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 1204, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 1224, _cache: Swift.String.Index._Cache.utf16)))) / (count: 0, range: nil)) (balanced_blank_lines)
⚠️ This PR introduced a violation in Firefox: /Users/distiller/project/osscheck/Firefox/Client/Frontend/Browser/BackForwardListAnimator.swift:70:9: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 0, range: nil) / (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 13024, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 13076, _cache: Swift.String.Index._Cache.utf16))))) (balanced_blank_lines)
⚠️ This PR introduced a violation in Firefox: /Users/distiller/project/osscheck/Firefox/Client/Frontend/Browser/Authenticator.swift:153:1: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 0, range: nil) / (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 33192, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 33196, _cache: Swift.String.Index._Cache.utf16))))) (balanced_blank_lines)
⚠️ This PR introduced a violation in Firefox: /Users/distiller/project/osscheck/Firefox/Client/Frontend/Browser/BackForwardTableViewCell.swift:97:5: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 0, range: nil) / (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 15180, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 15184, _cache: Swift.String.Index._Cache.utf16))))) (balanced_blank_lines)
⚠️ This PR introduced a violation in Firefox: /Users/distiller/project/osscheck/Firefox/Client/Frontend/Browser/BackForwardTableViewCell.swift:143:1: warning: Balanced Blank Lines Violation: Blank lines at the beginning and end of a body should be balanced (found (count: 1, range: Optional(Range(Swift.String.Index(_compoundOffset: 1140, _cache: Swift.String.Index._Cache.utf16)..<Swift.String.Index(_compoundOffset: 1160, _cache: Swift.String.Index._Cache.utf16)))) / (count: 0, range: nil)) (balanced_blank_lines)
⚠️ Danger found 2233 violations with this PR. Due to GitHub's max issue comment size, the number shown has been truncated to 82.
12 Messages
📖 Linting Aerial with this PR took 0.43s vs 0.37s on master (16% slower)
📖 Linting Alamofire with this PR took 3.49s vs 3.11s on master (12% slower)
📖 Linting Firefox with this PR took 14.46s vs 11.63s on master (24% slower)
📖 Linting Kickstarter with this PR took 21.55s vs 16.74s on master (28% slower)
📖 Linting Moya with this PR took 2.21s vs 1.85s on master (19% slower)
📖 Linting Nimble with this PR took 1.78s vs 1.5s on master (18% slower)
📖 Linting Quick with this PR took 0.53s vs 0.5s on master (6% slower)
📖 Linting Realm with this PR took 3.72s vs 3.15s on master (18% slower)
📖 Linting SourceKitten with this PR took 1.08s vs 1.0s on master (8% slower)
📖 Linting Sourcery with this PR took 5.15s vs 4.41s on master (16% slower)
📖 Linting Swift with this PR took 32.02s vs 27.82s on master (15% slower)
📖 Linting WordPress with this PR took 15.64s vs 14.99s on master (4% slower)

Generated by 🚫 Danger

@Johennes
Copy link
Author

Any chance this could be reviewed?

@stale
Copy link

stale bot commented Nov 8, 2020

This issue has been automatically marked as stale because it has not had any recent activity. Please comment to prevent this issue from being closed. Thank you for your contributions!

@stale stale bot added the wontfix label Nov 8, 2020
@stale stale bot closed this Nov 15, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Rule Request: Balanced leading and trailing blank lines in curly-braced bodies
2 participants