-
Notifications
You must be signed in to change notification settings - Fork 1.4k
[alternative 2] reload workspace state before reloading package graph #5510
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
Conversation
motivation: long running host processes (ie IDEs) need this in case other SwiftPM processes (ie CLI) made changes to the state changes: * call reload state before reloading the graph * add test
|
Just tried it and it also resolves the issue 👍 I’m fine with either this alternative or the other. |
|
@swift-ci smoke test |
abertelrud
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me, not only given how IDEs currently interact with libSwiftPM (watching file system themselves and reloading the package graph) but also to make sure state is loaded on first load.
motivation: long running host processes (ie IDEs) need this in case other SwiftPM processes (ie CLI) made changes to the state changes: * call reload state before reloading the graph * add test
| return self.storage.fileExists() | ||
| } | ||
|
|
||
| /// Returns true if the state file exists on the filesystem. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks like you missed updating the doc comment.
motivation: long running host processes (ie IDEs) need this in case other SwiftPM processes (ie CLI) made changes to the state
changes: