themekit checksum error caused by VS Code save file

Viewed 454

I'm trying to find a way to overcome an issue which I get with themekit while editing code in Visual Studio Code. When I save a file and then try to save it again (normally I wouldn't do that but I do it by reflex sometimes or forget that I've already saved it) themekit gives the error below:

17:37:43 [development] processing sections/file.liquid
17:37:43 [development] Skipped sections/file.liquid (Checksum: 4aab75d54ad199fc157384f85dd627dc)

When I try that in Webstorm I don't get such a problem. If I save it before and haven't changed the file, Webstorm doesn't send any save messages to themekit. Seems like VS Code sends a save event wether or not it saves the file. Actually that doesn't cause any problems since themekit just skips the file but anyway, I don't like to see a checksum error each time I do that and wonder if there's a way to change the default behavior of VS Code on saving an unchanged file.

1 Answers

Checksum is a feature of themekit that was introduced in 2020 (See How We Improved Development Tooling with Checksums). It is intended to skip files that haven't changed in order to improve upload times to Shopify's servers. That said this isn't an error. Rather you're seeing this to let you know that the file has not been changed (thus skipped during theme watch the process). In terms of why you may be seeing this in VS vs Webstorm could be how each code editor handles Checksums.

Related