Cork icon indicating copy to clipboard operation
Cork copied to clipboard

Updating individual packages throws `Could not synchronize packages` error

Open buresdv opened this issue 1 year ago • 1 comments

What were you trying to do?

Trying to update individual packages

What was the problem?

Throws Could not synchronize packages error due to the output of the outdated package retrieval function being empty Snímek obrazovky 2024-08-14 v 16 29 00

Error logs

Outdated package function oputput: TerminalOutput(standardOutput: "", standardError: "")
There was an error decoding the outdated package retrieval output: The data couldn’t be read because it isn’t in the correct format.
Swift.DecodingError.dataCorrupted(Swift.DecodingError.Context(codingPath: [], debugDescription: "The given data was not valid JSON.", underlyingError: Optional(Error Domain=NSCocoaErrorDomain Code=3840 "Unexpected end of file" UserInfo={NSDebugDescription=Unexpected end of file})))
Could not synchronize packages: Cork.OutdatedPackageRetrievalError.couldNotDecodeCommandOutput("The data couldn’t be read because it isn’t in the correct format.")

App Version

1.4.4.2

App Acquisition

Self-Compiled

Final checklist

  • [X] This report is about the interface, and I included screenshots of the problem

buresdv avatar Aug 14 '24 14:08 buresdv

For some reason, the outdated package retrieval function works everywhere else, including when updating all packages. Only the one instance where individual package(s) arebeing updated does it fail.

Also tested with updating up to three packages (error thrown) and updating all packages (error not thrown)

Offending line: https://github.com/buresdv/Cork/blob/4e7e5623fae1c38241fbbc29b4252f6b6f90f644/Cork/Views/Updating/Incremental%20Updating/Update%20Some%20Packages%20View.swift#L93

buresdv avatar Aug 14 '24 14:08 buresdv

Same issue here.

Cork 1.4.6.1 (85) macOS 15.1.1

perelin avatar Jan 10 '25 13:01 perelin

Is this still happening in the latest version?

buresdv avatar Feb 03 '25 19:02 buresdv

Resolved in d36570d2d777196e73f35e1bce7e83609cc9b5af

buresdv avatar Apr 03 '25 13:04 buresdv