Skip to content
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

Build caching: support package hash for swig #14153

Merged
merged 3 commits into from Dec 14, 2019

Conversation

scheibelp
Copy link
Member

Closes #13620
Closes #13265
Fixes #13237

Spack computes a "full hash" of packages as part of identifying them when retrieving binary packages for installation. The full hash includes a content hash that attempts to traverse the AST of a package.py file and include only the components that are used for the spec (e.g. if a patch is not applied for a particular spec version, then it is excluded from the content hash).

This AST examination fails in some cases where the "when" condition for a patch/phase is not a string literal. At this time swig is such an example. This PR updates the package hash calculation logic to fall back to including content when it cannot evaluate a when condition (even though it may not strictly be required by the spec).

@tgamblin tgamblin added this to Todo in Spack v0.14.0 release via automation Dec 14, 2019
Spack v0.14.0 release automation moved this from Todo to In review Dec 14, 2019
@tgamblin tgamblin merged commit 60580f5 into spack:develop Dec 14, 2019
Spack v0.14.0 release automation moved this from In review to Done Dec 14, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
No open projects
Development

Successfully merging this pull request may close these issues.

buildcache create ends without finishing, gives Warning: 'Name' object has no attribute 's'
2 participants