Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,11 @@ and this project adheres to [Semantic Versioning 2.0](https://semver.org/spec/v2
- Fixed incorrect ROCmLibs being installed for RX 6800/6800XT users of Comfy-Zluda or AMDGPU-Forge
- Fixed missing text when missing localized versions for Italian and Chinese languages
- Fixed Python Packages dialog errors and potentially other issues due to concurrent OnLoaded events
### Supporters
#### 🌟 Visionaries
Big cheers to our incredible Visionary-tier Patrons: **bluepopsicle**, **Bob S**, **Ibixat**, **Waterclouds**, and **Corey T**! 🚀 Your amazing support lets us dream bigger and reach further every single month. Thanks for being the driving force behind Stability Matrix - we genuinely couldn't do it without you!
#### 🚀 Pioneers
Huge thanks to our fantastic Pioneer-tier Patrons: **tankfox**, **Mr. Unknown**, **Szir777**, **Tigon**, and **Noah M**! Special shoutout and welcome back to **TheTekknician**, and a warm welcome aboard to our newest Pioneers: **USATechDude**, **SeraphOfSalem**, and **Thom**! ✨ Your continued support keeps our community vibrant and pushes us to keep creating. You all rock!

## v2.14.0
### Added
Expand Down
9 changes: 7 additions & 2 deletions StabilityMatrix.Avalonia/Models/UpdateChannelCard.cs
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,7 @@ public partial class UpdateChannelCard : ObservableObject
[NotifyPropertyChangedFor(nameof(IsLatestVersionUpdateable))]
private SemVersion? latestVersion;

public string? LatestVersionString =>
LatestVersion is null ? null : $"Latest: v{LatestVersion}";
public string? LatestVersionString => LatestVersion is null ? null : $"Latest: v{LatestVersion}";

[ObservableProperty]
private bool isSelectable = true;
Expand Down Expand Up @@ -49,6 +48,12 @@ public bool IsLatestVersionUpdateable
var updateHash = LatestVersion.Metadata;
var appHash = Compat.AppVersion.Metadata;

// Always assume update if (We don't have hash && Update has hash)
if (string.IsNullOrEmpty(appHash) && !string.IsNullOrEmpty(updateHash))
{
return true;
}
Comment on lines +51 to +55
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium

This new condition correctly handles the scenario where the currently installed application version might lack commit hash metadata (e.g., a local or older build), while the available update does include a hash.

By returning true in this case (string.IsNullOrEmpty(appHash) && !string.IsNullOrEmpty(updateHash)), we ensure that users are prompted to update, which is a safer and more robust approach. This aligns well with the changelog entry: "Fixed updates to versions with commit hash version parts not being recognized when the current version has no commit hash part."

Well done for catching this edge case!


// Trim both to the lower length, to a minimum of 7 characters
var minLength = Math.Min(7, Math.Min(updateHash.Length, appHash.Length));
updateHash = updateHash[..minLength];
Expand Down
2 changes: 1 addition & 1 deletion StabilityMatrix.Core/Updater/UpdateHelper.cs
Original file line number Diff line number Diff line change
Expand Up @@ -277,7 +277,7 @@ private bool ValidateUpdate(UpdateInfo? update)
var appHash = Compat.AppVersion.Metadata;

// Always assume update if (We don't have hash && Update has hash)
if (string.IsNullOrEmpty(updateHash) && !string.IsNullOrEmpty(appHash))
if (string.IsNullOrEmpty(appHash) && !string.IsNullOrEmpty(updateHash))
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

high

The change in this conditional statement is a crucial fix. The previous logic string.IsNullOrEmpty(updateHash) && !string.IsNullOrEmpty(appHash) meant an update would be assumed if "Update doesn't have hash AND App has hash".

The new logic string.IsNullOrEmpty(appHash) && !string.IsNullOrEmpty(updateHash) correctly implements the intent described in the comment: "Always assume update if (We don't have hash && Update has hash)".

This correction ensures that if the local application build has no commit hash, but the update manifest specifies a version with a commit hash, the update is correctly identified as available. This is a significant improvement for update reliability.

{
return true;
}
Expand Down
Loading