New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
"cannot load garble export file" errors #708
Comments
Started noticing the same thing for certain projects, but only when appending the -literals and -tiny flags.. |
Try out this:
This should fix the issue. |
I had a hunch that this kind of error could happen, I just never saw it in practice. Thanks for reporting; will look into a fix. @scirpter is right that |
neither of these work around work for me any other suggestions |
The test passes, because it expects garble to fail the same way that users are seeing in practice. For burrowers#708.
The test passes, because it expects garble to fail the same way that users are seeing in practice. For #708.
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
We first called the typecheck method, which starts filling cachedOutput with information from the current package, and later we would load the gob files for all dependencies via loadCachedOutputs. This was a bit confusing; instead, load the cached gob files first, and then do all the operations which fill information for curPkg. Similarly, we were waiting until the very end of transformCompile to write curPkg's cachedOutput gob file to the disk cache. We can write the file at an earlier point, before we have obfuscated and re-printed all Go files for the current package. We can also write the file before other work like processImportCfg. None of these changes should affect garble's behavior, but they will make the cache redesign for burrowers#708 easier.
We first called the typecheck method, which starts filling cachedOutput with information from the current package, and later we would load the gob files for all dependencies via loadCachedOutputs. This was a bit confusing; instead, load the cached gob files first, and then do all the operations which fill information for curPkg. Similarly, we were waiting until the very end of transformCompile to write curPkg's cachedOutput gob file to the disk cache. We can write the file at an earlier point, before we have obfuscated and re-printed all Go files for the current package. We can also write the file before other work like processImportCfg. None of these changes should affect garble's behavior, but they will make the cache redesign for #708 easier.
Some users had been running into "cannot load cache entry" errors, which could happen if garble's cache files in GOCACHE were removed when Go's own cache files were not. Now that we've moved to our own separate cache directory, and that we've refactored the codebase to depend less on globals and no longer assume that we're loading info for the current package, we can now compute a pkgCache entry for a dependency if needed. We add a pkgCache.CopyFrom method to be able to append map entries from one pkgCache to another without needing an encoding/gob roundtrip. We also add a parseFiles helper, since we now have three bits of code which need to parse a list of Go files from disk. Fixes burrowers#708.
Some users had been running into "cannot load cache entry" errors, which could happen if garble's cache files in GOCACHE were removed when Go's own cache files were not. Now that we've moved to our own separate cache directory, and that we've refactored the codebase to depend less on globals and no longer assume that we're loading info for the current package, we can now compute a pkgCache entry for a dependency if needed. We add a pkgCache.CopyFrom method to be able to append map entries from one pkgCache to another without needing an encoding/gob roundtrip. We also add a parseFiles helper, since we now have three bits of code which need to parse a list of Go files from disk. Fixes #708.
Excuse me please tell me how to download the latest version? I only have 0.9.3 to download. |
You can use |
What version of Garble and Go are you using?
What environment are you running Garble on?
go env
OutputWhat did you do?
What did you expect to see?
binary
What did you see instead?
It happens in any project
The text was updated successfully, but these errors were encountered: