Stack Exchange
spark sbt Error fetching artifacts https://repo1.maven.org/maven2/org/apache/hadoop/hadoop-hdfs/2.6.5/hadoop-hdfs-2.6.5.jar wrong checksum
my sbt settings were working properly when I created my first spark scala based project in intellij.
sbt is as below
name := "sample1"
version := "0.1"
//running in cluster
//scalaVersion := "2.11.0"
//val sparkVersion = "2.1.1"

//running in local
scalaVersion := "2.11.12"
val sparkVersion = "2.3.2"

//sbt when running in cluster using spark-submit

/*
libraryDependencies ++= Seq(
  "org.apache.spark" %% "spark-core" % sparkVersion % "provided",
  "org.apache.spark" %% "spark-sql" % sparkVersion % "provided",
  "org.apache.spark" %% "spark-mllib" % sparkVersion % "provided",
  "org.apache.spark" %% "spark-streaming" % sparkVersion % "provided"
)
*/

//sbt when running locally

libraryDependencies ++= Seq(
  "org.apache.spark" %% "spark-core" % sparkVersion,
  "org.apache.spark" %% "spark-sql" % sparkVersion,
  "org.apache.spark" %% "spark-mllib" % sparkVersion,
  "org.apache.spark" %% "spark-streaming" % sparkVersion
)

But when I created a new project with new sbt setting I am getting error.Tried to change version but no help.
new sbt for new project is 
name := "ranger_policy"

version := "0.1"

scalaVersion := "2.11.11"


libraryDependencies ++= Seq(
  "org.apache.spark" % "spark-core_2.11" % "2.2.0",
  "org.apache.spark" % "spark-sql_2.11" % "2.2.0",
  "org.apache.spark" % "spark-mllib_2.10" % "1.1.0"
)

my error is 
[error] stack trace is suppressed; run 'last update' for the full output
[error] stack trace is suppressed; run 'last ssExtractDependencies' for the full output
[error] (update) lmcoursier.internal.shaded.coursier.error.FetchError$DownloadingArtifacts: Error fetching artifacts:
[error] https://repo1.maven.org/maven2/org/apache/hadoop/hadoop-hdfs/2.6.5/hadoop-hdfs-2.6.5.jar: wrong checksum: C:\Users\vidushi.jaiswal\AppData\Local\Coursier\cache\v1\https\repo1.maven.org\maven2\org\apache\hadoop\hadoop-hdfs\2.6.5\hadoop-hdfs-2.6.5.jar (expected SHA-1 8bd0f95e29b9ba7960b4239a7f3706b37b183652 in C:\Users\vidushi.jaiswal\AppData\Local\Coursier\cache\v1\https\repo1.maven.org\maven2\org\apache\hadoop\hadoop-hdfs\2.6.5\.hadoop-hdfs-2.6.5.jar__sha1, got 495045c7fe5110559fa09d7f2381cd3483189a7)
[error] (ssExtractDependencies) lmcoursier.internal.shaded.coursier.error.FetchError$DownloadingArtifacts: Error fetching artifacts:
[error] https://repo1.maven.org/maven2/org/apache/hadoop/hadoop-hdfs/2.6.5/hadoop-hdfs-2.6.5.jar: wrong checksum: C:\Users\vidushi.jaiswal\AppData\Local\Coursier\cache\v1\https\repo1.maven.org\maven2\org\apache\hadoop\hadoop-hdfs\2.6.5\hadoop-hdfs-2.6.5.jar (expected SHA-1 8bd0f95e29b9ba7960b4239a7f3706b37b183652 in C:\Users\vidushi.jaiswal\AppData\Local\Coursier\cache\v1\https\repo1.maven.org\maven2\org\apache\hadoop\hadoop-hdfs\2.6.5\.hadoop-hdfs-2.6.5.jar__sha1, got 495045c7fe5110559fa09d7f2381cd3483189a7)
[error] Total time: 247 s (04:07), completed Jun 7, 2020 5:35:48 PM
[info] shutting down sbt server


why would you use different versions of the Spark dependencies in your second SBT file? And different Scala versions for your Spark depedencies? You should read one more time what those dependencies mean. Maybe also start reading about SBT and %% operator for deps. Also, why would anybody use an older Spark version instead of latest?

I was also facing the same issue while importing Spark SQL package through sbt. In had multiple folders for spark-sql namely spark-sql 2.12 & spark-sql 2.11. When I removed them & refreshed the build.sbt, the issue got resolved. 
In this path C:\Users\vidushi.jaiswal\AppData\Local\Coursier\cache\v1\https\repo1.maven.org\maven2\org\apache\hadoop\hadoop-hdfs\
you might have multiple folders with different versions for the same package. Delete all of them & refresh the build.sbt. All the dependencies will be downloaded freshly.
