diff --git a/api/funkwhale_api/music/tasks.py b/api/funkwhale_api/music/tasks.py index 218e374e8239c91861f82dbf75245cd94bee7ead..7b1b4898111f71b6947724dd4119fd1e36e1dfb5 100644 --- a/api/funkwhale_api/music/tasks.py +++ b/api/funkwhale_api/music/tasks.py @@ -259,7 +259,9 @@ def get_cover_from_fs(dir_path): 'import_job') def import_job_run(self, import_job, replace=False, use_acoustid=False): def mark_errored(exc): - logger.error('[Import Job %s] Error during import: %s', str(exc)) + logger.error( + '[Import Job %s] Error during import: %s', + import_job.pk, str(exc)) import_job.status = 'errored' import_job.save(update_fields=['status']) diff --git a/changes/changelog.d/274.bugfix b/changes/changelog.d/274.bugfix new file mode 100644 index 0000000000000000000000000000000000000000..c4c5a3aecccd1ddbcd62c3a3a35a2937455853fe --- /dev/null +++ b/changes/changelog.d/274.bugfix @@ -0,0 +1 @@ +Broken logging statement during import error (#274) diff --git a/changes/changelog.d/278.bugfix b/changes/changelog.d/278.bugfix new file mode 100644 index 0000000000000000000000000000000000000000..e1d831de166d25d9c46e134e96d3255af12e3ef6 --- /dev/null +++ b/changes/changelog.d/278.bugfix @@ -0,0 +1 @@ +Broken search bar on library home (#278) diff --git a/front/src/components/audio/Search.vue b/front/src/components/audio/Search.vue index 890c83f5bfc2d6562eedfda26b9a63a4fe631bf1..9cfea3bc0cae5da768bbf1dbefe7e12b405f508c 100644 --- a/front/src/components/audio/Search.vue +++ b/front/src/components/audio/Search.vue @@ -29,9 +29,9 @@ </template> <script> +import _ from 'lodash' import axios from 'axios' import logger from '@/logging' -import backend from '@/audio/backend' import AlbumCard from '@/components/audio/album/Card' import ArtistCard from '@/components/audio/artist/Card' @@ -50,7 +50,6 @@ export default { albums: [], artists: [] }, - backend: backend, isLoading: false } }, @@ -61,7 +60,7 @@ export default { this.search() }, methods: { - search () { + search: _.debounce(function () { if (this.query.length < 1) { return } @@ -77,15 +76,11 @@ export default { self.results = self.castResults(response.data) self.isLoading = false }) - }, + }, 500), castResults (results) { return { - albums: results.albums.map((album) => { - return backend.Album.clean(album) - }), - artists: results.artists.map((artist) => { - return backend.Artist.clean(artist) - }) + albums: results.albums, + artists: results.artists } } },