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

Write editor-state.json atomically #11

Open
phillco opened this issue Oct 13, 2022 · 2 comments
Open

Write editor-state.json atomically #11

phillco opened this issue Oct 13, 2022 · 2 comments

Comments

@phillco
Copy link
Member

phillco commented Oct 13, 2022

All editor state files should be written atomically, so that the sidecar doesn't load a partially written file.

@pokey
Copy link

pokey commented Oct 14, 2022

For the command server, we write the json as a single line and terminate it with a newline, and the reader knows to wait for a newline

@phillco
Copy link
Member Author

phillco commented Oct 14, 2022

Nice, that's a good idea. cc @dyamito

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

No branches or pull requests

2 participants