Skip to content

fix: Update version to 1.5.9, correct update - #54

Merged
Sythsaz merged 4 commits into
mainfrom
chore(release)--v1.5.9
Feb 8, 2026
Merged

fix: Update version to 1.5.9, correct update#54
Sythsaz merged 4 commits into
mainfrom
chore(release)--v1.5.9

Conversation

@Sythsaz

@Sythsaz Sythsaz commented Feb 8, 2026

Copy link
Copy Markdown
Owner

service notification to use toast, and resolve localization parameter ordering.


name: Pull Request
about: Propose changes to the bot
title: "[TYPE] Short description of change"
labels: ""
assignees: ""

Description

Type of change

  • 🐛 Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • 📚 Documentation (updates to documentation or comments)
  • 🔧 Refactor (code restructuring without changing external behavior)
  • ⚠️ Breaking change (fix or feature that would cause existing functionality to not work as expected)

Compatibility Check

  • I have verified this code compiles with C# 7.3 constraints (no new(), no record, no using var, etc.)
  • I have respected the suppressions in .editorconfig

How Has This Been Tested?

  • Automated Tests: Ran _tests/TestRunner.cs
  • Manual Verification: Imported into Streamer.bot and ran !giveaway system test
  • Feature specific testing: [Describe]

Checklist

  • My code follows the style guidelines of this project
  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • I have updated the CHANGELOG.md (under Unreleased)
  • My changes generate no new warnings (except those suppressed by design)

Summary by Sourcery

Bump the bot version to 1.5.9 and correct update and localization behavior for toast notifications.

Bug Fixes:

  • Ensure the update command path consistently uses toast notifications instead of chat broadcasts when checking for updates.
  • Fix localization argument ordering so toast messages correctly substitute values instead of showing raw placeholders in update-related toasts.

Documentation:

  • Update CHANGELOG and release notes for version 1.5.9.

service notification to use toast, and resolve localization parameter ordering.
@Sythsaz Sythsaz self-assigned this Feb 8, 2026
@sourcery-ai

sourcery-ai Bot commented Feb 8, 2026

Copy link
Copy Markdown
Contributor
Reviewer's guide (collapsed on small PRs)

Reviewer's Guide

Updates the bot to version 1.5.9 and fixes the update notification flow by switching a remaining chat-based update message to a localized toast notification and correcting localization argument ordering for toast messages, alongside updating changelog and release metadata.

Sequence diagram for updated bot update notification flow using toast and corrected localization

sequenceDiagram
    actor Broadcaster
    participant GiveawayManager
    participant CPHAdapter as CPHAdapter
    participant UpdateService as UpdateService
    participant Loc as Loc

    Broadcaster->>GiveawayManager: ProcessTrigger(adapter)
    GiveawayManager->>CPHAdapter: ShowToastNotification(Loc.Get(ToastTitle), Loc.Get(Update_Checking))
    GiveawayManager->>UpdateService: CheckForUpdatesAsync(adapter, Version, true)

    rect rgb(235, 245, 255)
        UpdateService->>CPHAdapter: LogInfo or LogDebug
        alt update available and saved
            UpdateService->>Loc: Get(Update_Downloaded, null, remoteTag, fileName)
            Loc-->>UpdateService: localizedMessage
            UpdateService->>CPHAdapter: ShowToastNotification(Loc.Get(ToastTitle), localizedMessage)
        else up to date and notifyIfUpToDate
            UpdateService->>Loc: Get(Update_UpToDate, null, currentVersion)
            Loc-->>UpdateService: localizedMessage
            UpdateService->>CPHAdapter: ShowToastNotification(Loc.Get(ToastTitle), localizedMessage)
        end
    end
Loading

Updated class diagram for update notification and localization flow

classDiagram
    class GiveawayManager {
        <<static>> string Version
        +bool ProcessTrigger(CPHAdapter adapter)
    }

    class UpdateService {
        +static Task CheckForUpdatesAsync(CPHAdapter adapter, string currentVersion, bool notifyIfUpToDate)
    }

    class Loc {
        +static string Get(string key, string profileName, params object[] args)
    }

    class CPHAdapter {
        +void ShowToastNotification(string title, string message)
        +void LogInfo(string message)
        +void LogDebug(string message)
    }

    class Messenger {
        +void SendBroadcast(CPHAdapter adapter, string message, string platform)
    }

    GiveawayManager --> UpdateService : uses
    GiveawayManager --> CPHAdapter : uses
    GiveawayManager --> Messenger : previously used for update notice
    GiveawayManager --> Loc : uses for localized toast text
    UpdateService --> CPHAdapter : uses for toast and logging
    UpdateService --> Loc : uses for localized toast text

    note for GiveawayManager "Version updated to 1_5_9 and update check now uses toast notifications instead of chat broadcast"
    note for UpdateService "Localization arguments to Loc.Get now include explicit null profileName and correct ordering for toast messages"
Loading

File-Level Changes

Change Details Files
Bump bot version and release metadata to 1.5.9.
  • Updated the GiveawayManager Version constant from 1.5.8 to 1.5.9.
  • Updated the RELEASE_NOTES heading to reflect v1.5.9.
  • Updated the VERSION file to 1.5.9.
GiveawayBot.cs
RELEASE_NOTES.md
VERSION
Standardize update check user feedback to use toast notifications instead of chat broadcast.
  • Replaced the remaining chat broadcast message for the update check command with a toast notification using localized title and body keys.
  • Ensured the toast uses Loc.Get("ToastTitle") and Loc.Get("Update_Checking") for localization consistency.
GiveawayBot.cs
Fix localization parameter ordering for update-related toast notifications.
  • Adjusted Loc.Get call for the update downloaded toast to include a placeholder for the unused profile parameter before remoteTag and fileName.
  • Adjusted Loc.Get call for the up-to-date toast to include a null placeholder for the profile argument before currentVersion.
  • Ensured that format arguments map correctly to localization placeholders so values like version and filename render instead of literal {0}/{1}.
GiveawayBot.cs
Document the 1.5.9 fixes in the changelog.
  • Added a 1.5.9 section under Unreleased describing the update service handler fix and localization parameter ordering fix.
CHANGELOG.md

Tips and commands

Interacting with Sourcery

  • Trigger a new review: Comment @sourcery-ai review on the pull request.
  • Continue discussions: Reply directly to Sourcery's review comments.
  • Generate a GitHub issue from a review comment: Ask Sourcery to create an
    issue from a review comment by replying to it. You can also reply to a
    review comment with @sourcery-ai issue to create an issue from it.
  • Generate a pull request title: Write @sourcery-ai anywhere in the pull
    request title to generate a title at any time. You can also comment
    @sourcery-ai title on the pull request to (re-)generate the title at any time.
  • Generate a pull request summary: Write @sourcery-ai summary anywhere in
    the pull request body to generate a PR summary at any time exactly where you
    want it. You can also comment @sourcery-ai summary on the pull request to
    (re-)generate the summary at any time.
  • Generate reviewer's guide: Comment @sourcery-ai guide on the pull
    request to (re-)generate the reviewer's guide at any time.
  • Resolve all Sourcery comments: Comment @sourcery-ai resolve on the
    pull request to resolve all Sourcery comments. Useful if you've already
    addressed all the comments and don't want to see them anymore.
  • Dismiss all Sourcery reviews: Comment @sourcery-ai dismiss on the pull
    request to dismiss all existing Sourcery reviews. Especially useful if you
    want to start fresh with a new review - don't forget to comment
    @sourcery-ai review to trigger a new review!

Customizing Your Experience

Access your dashboard to:

  • Enable or disable review features such as the Sourcery-generated pull request
    summary, the reviewer's guide, and others.
  • Change the review language.
  • Add, remove or edit custom review instructions.
  • Adjust other review settings.

Getting Help

@Sythsaz Sythsaz added the bug Something isn't working label Feb 8, 2026
@chatgpt-codex-connector

Copy link
Copy Markdown

You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard.

@sourcery-ai sourcery-ai Bot left a comment

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.

Hey - I've left some high level feedback:

  • The new Loc.Get calls that pass null as the profileName make the call sites a bit harder to read; consider introducing a small helper (e.g., Loc.GetGlobal(key, params object[] args)) or using named arguments to avoid magic null values scattered through the code.
  • The repeated use of the "ToastTitle" localization key would be easier to maintain if it were centralized as a constant or static property rather than hard-coded in multiple call sites.
Prompt for AI Agents
Please address the comments from this code review:

## Overall Comments
- The new `Loc.Get` calls that pass `null` as the `profileName` make the call sites a bit harder to read; consider introducing a small helper (e.g., `Loc.GetGlobal(key, params object[] args)`) or using named arguments to avoid magic `null` values scattered through the code.
- The repeated use of the `"ToastTitle"` localization key would be easier to maintain if it were centralized as a constant or static property rather than hard-coded in multiple call sites.

Sourcery is free for open source - if you like our reviews please consider sharing them ✨
Help me be more useful! Please click 👍 or 👎 on each comment and I'll use the feedback to improve your reviews.

@Sythsaz
Sythsaz merged commit 9a10b8a into main Feb 8, 2026
15 checks passed
@Sythsaz
Sythsaz deleted the chore(release)--v1.5.9 branch February 9, 2026 07:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant