When scanning apple/swift, linting multiple files fails with a bus error
Open
Nobody has claimed this yet.
discussion
- Dominant language
- Swift
- Stars
- 19.7k
- Forks
- 2.3k
- Avg merge
- 1d 1h
- Merged PRs (30d)
- 11
Description
New Issue Checklist
- Updated SwiftLint to the latest version
- I searched for existing GitHub issues
Describe the bug
brew install swiftlint
git clone https://github.com/apple/swift
cd swift
swiftlint validation-test/compiler_crashers_fixed/28616-swift-parser-parseexprsequence-swift-diag-bool-bool.swift
Linting Swift files at paths validation-test/compiler_crashers_fixed/28616-swift-parser-parseexprsequence-swift-diag-bool-bool.swift
Linting '28616-swift-parser-parseexprsequence-swift-diag-bool-bool.swift' (1/1)
zsh: bus error swiftlint
The following files are affected:
validation-test/compiler_crashers_fixed/28678-result-case-not-implemented.swift
validation-test/compiler_crashers_fixed/28616-swift-parser-parseexprsequence-swift-diag-bool-bool.swift
validation-test/compiler_crashers_2_fixed/parser-cutoff.swift
test/Parse/structure_no_overflow.swift
test/Parse/structure_overflow.swift
test/SourceKit/Misc/parser-cutoff.swift
This may be a problem with SourceKit/SourceKitten:
Complete output when running SwiftLint, including the stack trace and command used
See above
Environment
- SwiftLint version (run
swiftlint versionto be sure)?0.50.3 - Installation method used (Homebrew, CocoaPods, building from source, etc)? homebrew
- Paste your configuration file:
none
- Are you using nested configurations? no
- Which Xcode version are you using (check
xcodebuild -version)?
Xcode 14.2
Build version 14C18
- Do you have a sample that shows the issue?
See above for sample files that cause the issue
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Reproduce the bus error with SwiftLint 0.50.3 using the command in the report and the listed Swift files, starting with validation-test/compiler_crashers_fixed/28616-swift-parser-parseexprsequence-swift-diag-bool-bool.swift. Investigate the possible SourceKit/SourceKitten involvement and compare behavior across the affected parser and SourceKit test files. Done means linting the affected files no longer exits with a bus error.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- swift
- Domain
- tooling
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100