User reported.
UResavePackagesCommandlet::CheckoutFile(const FString& Filename, bool bAddFile = false, bool bIgnoreAlreadyCheckedOut = false)
has a parameter to ignore files that are already checked out. When this is true, there is still an error message logged when checkout fails, while a reason checkout can fail is because it was already checked out:
if (CheckoutFile(PackageFilename, true, bIgnoreAlreadyCheckedOut)) { SublevelFilenames.Add(PackageFilename); if (!SavePackageHelper(Package, PackageFilename)) { UE_LOG(LogContentCommandlet, Error, TEXT("Failed to save existing package %s"), *PackageFilename); } } else { UE_LOG(LogContentCommandlet, Error, TEXT("Failed to check out existing package %s"), *PackageFilename); }
However, checkout can fail due to a multitude of reasons.
Suggestion: change the return type of Checkout() to also provide a reason. Skip the error log if but only if the reason was that it was already checked out.
There's no existing public thread on this issue, so head over to Questions & Answers just mention UE-175738 in the post.
2 |
Component | UE - Foundation - Cpp Tools - Automation Tool |
---|---|
Affects Versions | 5.1 |
Target Fix | 5.6 |
Created | Feb 1, 2023 |
---|---|
Updated | Oct 25, 2024 |