Wpilib Update Error

So we had a working code in VS, but then I saw that there was an an update to the wpilib. We ran the update and now our whole code is a mess of errors. It no longer can recognize any of wpilib references. Any idea if we are missing a step? Here is my error code:

error: error reading /Users/johnboynton1/.gradle/caches/modules-2/files-2.1/edu.wpi.first.wpilibj/wpilibj-java/2019.2.1/e9ce5b88553ca2d231c116a2197141cc849d3e41/wpilibj-java-2019.2.1.jar; zip END header not found
error: error reading /Users/johnboynton1/.gradle/caches/modules-2/files-2.1/edu.wpi.first.ntcore/ntcore-java/2019.2.1/b055588873991ae5880cfcdbdc11c091d53b1335/ntcore-java-2019.2.1.jar; zip END header not found
error: error reading /Users/johnboynton1/.gradle/caches/modules-2/files-2.1/edu.wpi.first.wpiutil/wpiutil-java/2019.2.1/12221c0d1fbc0ea412f369c813638ef3d7048a3a/wpiutil-java-2019.2.1.jar; zip END header not found
error: error reading /Users/johnboynton1/.gradle/caches/modules-2/files-2.1/edu.wpi.first.cscore/cscore-java/2019.2.1/7ee0a7133f03ce960f1d4780b09645a92c8513fc/cscore-java-2019.2.1.jar; zip END header not found
error: error reading /Users/johnboynton1/.gradle/caches/modules-2/files-2.1/edu.wpi.first.cameraserver/cameraserver-java/2019.2.1/bb163e52b3ba1292e96f5d002b14f1fff402f9e0/cameraserver-java-2019.2.1.jar; zip END header not found
error: error reading /Users/johnboynton1/.gradle/caches/modules-2/files-2.1/edu.wpi.first.hal/hal-java/2019.2.1/a4dd730300915376b1fba3b73812ff872612c0d3/hal-java-2019.2.1.jar; zip END header not found

Thanks for your help…

1 Like

It looks like something didn’t update correctly, as the cached files are corrupt. Try deleting everything in the /Users/johnboynton1/.gradle directory and rebuilding, and if that fails, reinstall the update, delete that .gradle directory again, and rebuild again.

Thanks for your help! It would appear running the online install was a bad idea. I deleted everything I just went through the offiline screensteps using the new wpilib update and we working again sortof. The project can build but I have errors of it not recognizing the wpilib in the code.

You mean in intellisense? Probably its cache is still out of date. I think there’s an refresh intellisense command, but you can also try closing all the editor windows, restarting vscode, and then reopening the editors you want.

The only way I could get it to update is if I uninstalled Phoenix and then reinstalled it using the manage vendor libraries. Either way, we appear to be working again. Thanks again for your help!!