Skip to content

Conversation

cachemeifyoucan
Copy link
Contributor

@cachemeifyoucan cachemeifyoucan commented Aug 22, 2025

Currently, swift-frontend will always try to infer a default CASPath if no -cas-path is passed. The function getDefaultOnDiskCASPath called to infer the default path can fatal error in some environment where no caching directory and home directory, no matter if caching is used or not.

Remove the inferred path during parsing since that is not strictly necessary. If caching is enabled and no CASPath is passed, there will be error during CAS construction time.

rdar://158899187

@cachemeifyoucan
Copy link
Contributor Author

@swift-ci please smoke test

@cachemeifyoucan
Copy link
Contributor Author

@swift-ci please smoke test

Currently, swift-frontend will always try to infer a default CASPath if
no `-cas-path` is passed. The function `getDefaultOnDiskCASPath` called
to infer the default path can fatal error in some environment where no
caching directory and home directory, no matter if caching is used or
not.

Remove the inferred path during parsing since that is not strictly
necessary. If caching is enabled and no CASPath is passed, error can be
issued during CAS construction time.

rdar://158899187
@cachemeifyoucan
Copy link
Contributor Author

@swift-ci please smoke test

@cachemeifyoucan
Copy link
Contributor Author

@swift-ci please smoke test windows platform

@cachemeifyoucan cachemeifyoucan merged commit 94f7c54 into swiftlang:main Aug 26, 2025
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants