Perhaps
```scala
val partitionFiles = dirContents.map(_.getPath.toString).filter { name =>
  name.contains("part-") && !(name.contains("-attempt-") && name.contains(".part-"))
}.sorted
```

so it fits in 100 chars and be slightly more readable