-
Notifications
You must be signed in to change notification settings - Fork 29
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
Windows: command output is not valid JSON: unexpected end of JSON input #202
Comments
Is this something you were able to reproduce any time you create a new plan? Or was this a plan that you inherited from an older version of backrest (and recently updated the backrest version)? |
Fixed in the latest release https://github.com/garethgeorge/backrest/releases/tag/v0.17.0 |
@garethgeorge Just for my understanding, the issue is that when all "by time period" inputs are set to 0, restic returns an error instead of a JSON response? In other words, I hit this by skipping through and clicking "Submit" without reading the page. Meaning this is the fix, initializing these values? e96f403#diff-dea1ed7f9a3e7b84580826b2d1670e8fd5d4c89f73fed4d84fd5ea7b0b106221R490-R493 Do you think it's worth adding a validation step in case a user does zero these all out? It seems like a "nice to have" but not critical. |
Hey, yep! What's essentially happening here is we're calling restic forget without providing any flags at all for the policy. Validation sounds like a good idea, this should probably be validation we actually do in the backend to block loading a config that's misconfigured e.g. here https://github.com/garethgeorge/backrest/blob/main/internal/config/validate.go#L102-L104 (and optionally in the UI -- but for I think just doing the backend check is probably safe for this). I'll reopen this to track adding that check. |
Going ahead and marking this as resolved, the latest version should be handling tags and group-by correctly now. |
Describe the bug
To Reproduce
Steps to reproduce the behavior:
Expected behavior
Successful forget run.
Screenshots
Desktop (please complete the following information):
Additional context
This was previously fixed in #160 and I haven't seen this behavior on macOS, so I suspect this is a Windows-specific bug.
Update: I received the error many times, running against the same repo. When I changed the retention policy from the default schedule to a count of 1, it stopped erroring.
The text was updated successfully, but these errors were encountered: