Commit Graph

836 Commits

Author SHA1 Message Date
sentriz
fdbb28209b fix(scanner): fix records with album name same as artist
and never use db.Where() with a struct

gorm was seeing a query like

    db.Where(Album{Left: left, Right: right})

but if the `left` variable was empty, gorm couldn't differentiate it with an empty field in the struct
so it generated SQL that we weren't expected

like

    SELECT * FROM albums WHERE right=?

instead of

    SELECT * FROM albums WHERE left=? AND right=?

fixes #230
2022-09-09 13:09:06 +01:00
Walter Huf
a11d6ab92d fix(docs): add GONIC_HTTP_LOG to setting table 2022-09-09 08:35:02 +00:00
Walter Huf
731a696bd7 feat: add a ping endpoint that doesn't create a session 2022-09-09 08:32:48 +00:00
sentriz
7d0d036f0b feat(lastfm): scrobble with duration 2022-09-06 17:48:56 +01:00
brian-doherty
0f80ae2655 fix(podcast): add user agent to avoid 403s with some remotes
* Found a podcast that returns 403 without a UserAgent string so I added one. URL is https://feeds.buzzsprout.com/132359.rss

* Fixed lint issues including needed error checking.
2022-08-23 21:44:19 +01:00
sentriz
6c94f194df rewrite "" search queries as `` 2022-07-22 14:13:01 +01:00
sentriz
de540966bc add a note about symfonium.app to the readme 2022-07-21 20:18:54 +01:00
sentriz
1a1f39f4e8 fix(subsonic): return song artist ID, album and song genres from search3
related: #229
2022-07-21 19:58:26 +01:00
sentriz
4557a4ec33 rewrite "" search queries as ``
closes #229
2022-07-21 14:57:37 +01:00
sentriz
a9d393350a fix(scanner): better detect years given extraneous year tags 2022-07-21 13:06:32 +01:00
Brian Doherty
5e66261f0c feat(subsonic): add avatar support
closes: #228
2022-07-20 23:18:35 +01:00
brian-doherty
7ab378accb feat(subsonic): add internet radio support
* Initial commit of internet radio support.

* Added first test for internet radio.

* Refactor to prepare for more test cases.

* Added a few more tests. Realized that I was not calling as admin so added ability to mock admin.

* Added more internet radio tests. Added proper JSON unmarshaling for ID.

* More test cases. Fixed some accidental tabs in files.

* Fixed some more tabs.

* lint fixes

* Changed placeholder for homepage URL to fit into box.

* Finished out internet radio test cases. Found a few bad error codes in internet radio AND podcasts (mea culpa).

* Realized that delete via website was not checking properly if id existed. Fixed.

gofmt
2022-06-21 22:33:21 +01:00
sentriz
2afc63f64a add a test for updated album genre tags
related #225
2022-05-19 00:49:20 +01:00
sentriz
d6d1fe26ba refactor(scanner): remove unused genreIDs arg 2022-05-19 00:46:17 +01:00
sentriz
53a4247dfd feat(subsonic): add year and genre fields to track-by-folder response
fixes #223
2022-05-18 22:01:47 +01:00
sentriz
668c334f45 remove redundant lastfm user session check 2022-05-18 22:01:00 +01:00
brian-doherty
50e2818cc7 feat(subsonic): make the v param optional 2022-05-18 14:20:16 +01:00
brian-doherty
64d8e014b3 fixed rendering of podcast section on admin/home for both desktop and mobile 2022-05-15 15:08:17 +01:00
sentriz
4fce8e67ce log bad scrobble responses
related #219
2022-05-15 15:02:15 +01:00
brian-doherty
182c96e966 refactor(podcast)!: make podcasts global not per user, to match spec
Release-As: 0.15.0
2022-05-03 22:42:03 +01:00
sentriz
e883de8c95 fix(listenbrainz): set json header
closes #216

related https://github.com/sentriz/gonic/issues/216
related https://github.com/krateng/maloja/issues/141
2022-05-02 14:52:31 +01:00
brian-doherty
f6687df3f3 feat(subsonic): add getNewestPodcasts 2022-04-21 20:13:47 +01:00
sentriz
dc4d9e4e96 feat(subsonic): add detailed logging about requested audio
closes #212
2022-04-21 01:31:37 +01:00
sentriz
6bebceccd9 delete guess expected size feature
it it doing some really bad guesses for opus files
2022-04-21 00:47:39 +01:00
sentriz
4658d07273 fix(lastfm): make a better guess at callback protocol when incoming connection is TLS
closes: #213

Co-authored-by: Brian Doherty <brian.r.doherty@gmail.com>
2022-04-20 23:11:20 +01:00
sentriz
611bc96e29 fix(podcast): add error case for when DownloadEpisode is called via API and podcast is already downloaded
closes: #213

Co-authored-by: Brian Doherty <brian.r.doherty@gmail.com>
2022-04-20 23:11:13 +01:00
sentriz
8b803ecf20 refactor: move shared packages up a level 2022-04-13 01:10:46 +01:00
sentriz
165904c2bb feat(transcode): add a generic transcoding package for encoding/decoding/caching 2022-04-13 01:10:46 +01:00
sentriz
fd211d706a refactor(countrw): move to iout 2022-04-12 23:38:44 +01:00
sentriz
d7655cb9d1 fix(subsonic): change order of fromYear toYear query
closes #208
2022-04-02 18:04:57 +01:00
sentriz
01747c8940 fix(scanner): make sure we have an album artist before populating track
if we return early before i == 0 we mightn't have one

fixes #209
2022-04-02 18:03:14 +01:00
sentriz
a8e50c4a01 don't log listenbrainz scrobble errors
we're already logging at the subsonic level
2022-03-24 00:11:11 +00:00
sentriz
2440e69689 feat(subsonic): log error responses 2022-03-23 23:41:31 +00:00
sentriz
78853ed62b format dockerfiles 2022-03-23 23:41:08 +00:00
sentriz
f2143e32ef fix(scanner): respect "is full" setting 2022-03-23 20:41:55 +00:00
sentriz
1ab47d6fbe feat(subsonic): update play stats when scrobbling
closes: #207

Co-authored-by: Brian Doherty <brian.r.doherty@gmail.com>
2022-03-22 20:39:57 +00:00
brian-doherty
59c404749f feat(server): support TLS
* Added https support. Will revert to http if either cert or key are empty strings.

* Update server/server.go

Co-authored-by: Senan Kelly <senan@senan.xyz>

* Fixed lint issues.

Co-authored-by: Senan Kelly <senan@senan.xyz>
2022-03-14 23:38:09 +00:00
sentriz
5155dee2e8 feat(countrw): add countrw package 2022-03-10 00:49:05 +00:00
sentriz
c7862761bd support parsing floats 2022-03-10 00:49:05 +00:00
sentriz
74c955b723 refactor: ioutil -> io 2022-03-10 00:49:05 +00:00
sentriz
5420f01089 refactor(mockfs): automatically clean up with t.Cleanup() 2022-03-02 15:19:12 +00:00
sentriz
9d406afb1f refactor(scanner): take seed from fuzzer 2022-03-02 09:30:51 +00:00
sentriz
d6492c1521 refactor(scanner): switch ext() path 2022-02-27 20:56:53 +00:00
sentriz
e56f64a758 feat(subsonic): sort artist album list
fixes #197
2022-02-25 21:00:24 +00:00
sentriz
bb9b52b960 try to save some extra writes of albums 2022-02-25 20:46:42 +00:00
xavier
55c09209b6 feat(subsonic): improve getArtistInfo2.view similar artist results (#203)
Co-authored-by: xavier <xavier@futurae.com>
2022-02-25 17:49:08 +00:00
sentriz
401c17b355 add a test for a compilation album without album artist tags
related https://github.com/sentriz/gonic/issues/185
related https://github.com/sentriz/gonic/issues/185#issuecomment-1050092128
2022-02-24 19:15:37 +00:00
sentriz
d3d2ed3469 add a test for scan tag errors 2022-02-24 19:15:37 +00:00
sentriz
599636663d support returning errors from mockfs tags 2022-02-24 19:15:37 +00:00
sentriz
19bc7f16aa add test for deleting artists 2022-02-24 19:15:37 +00:00