Compare commits

3 Commits
0.4.0 ... 0.4.1

Author SHA1 Message Date
Simon Diesenreiter
887a8a7b6a release: version 0.4.1 🚀
Some checks failed
Build Docker image / Create Release (push) Successful in 20s
CI / linter (9.0.X, ubuntu-latest) (push) Successful in 1m14s
CI / tests_linux (9.0.X, ubuntu-latest) (push) Failing after 1m30s
SonarQube Scan / SonarQube Trigger (push) Failing after 5m8s
Build Docker image / deploy (push) Failing after 4m56s
2025-06-25 09:48:32 +02:00
Simon Diesenreiter
4b18003aa8 fix: fix formatting, refs NOISSUE 2025-06-25 09:48:27 +02:00
c0bee8fd3c fix: URL type, refs NOISSUE
Some checks failed
CI / linter (9.0.X, ubuntu-latest) (push) Failing after 1m20s
CI / tests_linux (9.0.X, ubuntu-latest) (push) Has been skipped
SonarQube Scan / SonarQube Trigger (push) Failing after 4m48s
2025-06-25 00:42:34 -07:00
12 changed files with 35 additions and 21 deletions

View File

@@ -5,6 +5,15 @@ Changelog
(unreleased) (unreleased)
------------ ------------
Fix
~~~
- Fix formatting, refs NOISSUE. [Simon Diesenreiter]
- URL type, refs NOISSUE. [simon]
0.4.0 (2025-06-04)
------------------
Fix Fix
~~~ ~~~
- Some cleanup and fixing runtime bugs, refs NOISSUE. [Simon - Some cleanup and fixing runtime bugs, refs NOISSUE. [Simon
@@ -274,6 +283,10 @@ Other
0.1.9 (2025-04-15) 0.1.9 (2025-04-15)
------------------ ------------------
0.1.8 (2025-04-15)
------------------
Fix Fix
~~~ ~~~
- Additional debug outputs refs NOISSUE. [Simon Diesenreiter] - Additional debug outputs refs NOISSUE. [Simon Diesenreiter]

View File

@@ -3,10 +3,10 @@ using song_of_the_day;
public class LinkPreviewAttachment public class LinkPreviewAttachment
{ {
public string Url { get; set; } public required string Url { get; set; }
public string Title { get; set; } public required string Title { get; set; }
public string Description { get; set; } public required string Description { get; set; }
public string Base64Image { get; set; } public required string Base64Image { get; set; }
} }
public class SignalIntegration public class SignalIntegration

View File

@@ -17,13 +17,14 @@ public class IndexModel : PageModel
[BindProperty] [BindProperty]
public List<SongSuggestion> SongSuggestions { get; set; } = new List<SongSuggestion>(); public List<SongSuggestion> SongSuggestions { get; set; } = new List<SongSuggestion>();
public async Task OnGet() public Task OnGet()
{ {
using var dci = DataContext.Instance; using var dci = DataContext.Instance;
this.SongSuggestions = dci.SongSuggestions.OrderByDescending(s => s.Date) SongSuggestions = dci.SongSuggestions.OrderByDescending(s => s.Date)
.Take(50) .Take(50)
.Include(s => s.Song) .Include(s => s.Song)
.Include(s => s.User) .Include(s => s.User)
.ToList(); .ToList();
return Task.CompletedTask;
} }
} }

View File

@@ -1,6 +1,6 @@
public class SongPartialModel public class SongPartialModel
{ {
public Song InnerSong { get; set; } public required Song InnerSong { get; set; }
public string? Artist => InnerSong.Artist; public string? Artist => InnerSong.Artist;

View File

@@ -40,7 +40,7 @@ public class SongSubmissionModel : PageModel
public bool IsPageReadonly { get; set; } = false; public bool IsPageReadonly { get; set; } = false;
[BindProperty] [BindProperty]
public SuggestionHelper SuggestionHelper { get; set; } = null; public SuggestionHelper? SuggestionHelper { get; set; } = null;
[BindProperty] [BindProperty]
public List<SongSuggestion> UserSongSubmissions { get; set; } = []; public List<SongSuggestion> UserSongSubmissions { get; set; } = [];

View File

@@ -152,7 +152,7 @@ pickOfTheDayTimer.OnOccurence += async (s, ea) =>
await signalIntegration.SendMessageToGroupAsync($"Today's chosen person to share a song is: **{userName}**"); await signalIntegration.SendMessageToGroupAsync($"Today's chosen person to share a song is: **{userName}**");
await signalIntegration.SendMessageToUserAsync($"Congratulations, you have been chosen to share a song today!", signalId); await signalIntegration.SendMessageToUserAsync($"Congratulations, you have been chosen to share a song today!", signalId);
await signalIntegration.SendMessageToUserAsync($"Today's (optional) suggestion helper to help you pick a song is:\n\n**{suggestion.Title}**\n\n*{suggestion.Description}*", signalId); await signalIntegration.SendMessageToUserAsync($"Today's (optional) suggestion helper to help you pick a song is:\n\n**{suggestion.Title}**\n\n*{suggestion.Description}*", signalId);
await signalIntegration.SendMessageToUserAsync($"Please navigate to https://sord.disi.dev/SongSubmission/{newSongSuggestion.Id} to submit your choice!", luckyUser.SignalMemberId); await signalIntegration.SendMessageToUserAsync($"Please navigate to https://sotd.disi.dev/SongSubmission/{newSongSuggestion.Id} to submit your choice!", luckyUser.SignalMemberId);
} }
await dci.DisposeAsync(); await dci.DisposeAsync();
}; };

View File

@@ -1,6 +1,6 @@
public class Base64UrlImageBuilder public class Base64UrlImageBuilder
{ {
public string ContentType { set; get; } public required string ContentType { set; get; }
public string Url public string Url
{ {
@@ -13,7 +13,7 @@ public class Base64UrlImageBuilder
} }
} }
private string FileContents { get; set; } private required string FileContents { get; set; }
public override string ToString() public override string ToString()
{ {

View File

@@ -14,9 +14,9 @@ public class YoutubeValidator : UriBasedSongValidatorBase
public override string UriValidatorRegex => @"^(https?://)?(www\.)?(youtube\.com/watch\?v=|youtu\.be/)([a-zA-Z0-9_-]{11})"; public override string UriValidatorRegex => @"^(https?://)?(www\.)?(youtube\.com/watch\?v=|youtu\.be/)([a-zA-Z0-9_-]{11})";
public override async Task<bool> CanExtractSongMetadataAsync(Uri songUri) public override Task<bool> CanExtractSongMetadataAsync(Uri songUri)
{ {
return this.CanValidateUri(songUri); return Task.FromResult(this.CanValidateUri(songUri));
} }
public override SongProvider GetSongProvider() public override SongProvider GetSongProvider()

View File

@@ -1 +1 @@
0.4.0 0.4.1