<#21532 Possible cache race on jvm dependency arti...
# github-notifications
c
#21532 Possible cache race on jvm dependency artifacts via bsp Issue created by jgranstrom Describe the bug Projects with multiple bsp groups seem to hit a cache race when materializing jars across the groups. I have a repro here and opening it in intellij will if not immediately after a few re-requests from bsp start failing due to read-only files hit in the target directory for bsp jars. Seen in BSP logs from intellij:
Copy code
Engine traceback:
  in root
    ..
  in pants.backend.scala.bsp.rules.bsp_scalac_options_request
    ..

...

native_engine.IntrinsicError: Error copying bytes from /Users/johngranstrom/.cache/pants/lmdb_store/immutable/files/e8/e805c5ccc0241ceab8d55795633f909eafe1826bdf32214fc2869ffaee61f086 
to /Users/johngranstrom/code/repros/bsprepro3/.pants.d/bsp/jvm/resolves/jvm-default/lib/dev.zio_izumi-reflect_2.13_2.3.9.jar: 
Permission denied (os error 13) (-32602)
Flags on the target bsp jars are all over:
Copy code
❯ ls -la .pants.d/bsp/jvm/resolves/jvm-default/lib/                                                                                                                                      content-staging-apps_us
total 21816
drwxr-xr-x  8 johngranstrom  staff      256 Oct 16 17:35 .
drwxr-xr-x  4 johngranstrom  staff      128 Oct 16 17:35 ..
-rw-r--r--  1 johngranstrom  staff    94887 Oct 16 17:35 dev.zio_izumi-reflect-thirdparty-boopickle-shaded_2.13_2.3.9.jar
-r-xr-xr-x  1 johngranstrom  staff   592307 Oct 16 17:32 dev.zio_izumi-reflect_2.13_2.3.9.jar
-rw-r--r--  1 johngranstrom  staff    55959 Oct 16 17:35 dev.zio_zio-internal-macros_2.13_2.1.11.jar
-rw-r--r--  1 johngranstrom  staff    26874 Oct 16 17:35 dev.zio_zio-stacktracer_2.13_2.1.11.jar
-r-xr-xr-x  1 johngranstrom  staff  4462042 Oct 16 17:32 dev.zio_zio_2.13_2.1.11.jar
-r-xr-xr-x  1 johngranstrom  staff  5924141 Oct 16 17:33 org.scala-lang_scala-library_2.13.14.jar
Pants version 2.22 OS MacOS pantsbuild/pants