From 580712acd11d5afdacd51c2e8d29313efc93d520 Mon Sep 17 00:00:00 2001 From: cooljqln Date: Fri, 24 Jan 2025 00:40:48 +0000 Subject: Resolve some issues with dangling index records (#193) - The tag parser's cache is now cleared between indexing runs, preventing stale data from being used - Multi-value tag fields (genres, all artists) are now properly ingested in the tag value cache - Cleaning up removed index records now properly handles the case where only a subset of the records for multi-value tags need to be deleted. - Synthesizing missing tag values is now done in the tag parser instead of TrackTags, which resolves some issues with multi-value tag callbacks from libtags not being handled properly These fixes seem to address all the issues with stale index records we were able to repro (including the issues in https://codeberg.org/cool-tech-zone/tangara-fw/issues/191), but if you've got any more cases with consistent repros then lmk! Co-authored-by: ailurux Reviewed-on: https://codeberg.org/cool-tech-zone/tangara-fw/pulls/193 --- src/tangara/lua/lua_database.hpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src/tangara/lua/lua_database.hpp') diff --git a/src/tangara/lua/lua_database.hpp b/src/tangara/lua/lua_database.hpp index 51e71758..fa2c26a3 100644 --- a/src/tangara/lua/lua_database.hpp +++ b/src/tangara/lua/lua_database.hpp @@ -13,8 +13,9 @@ namespace lua { auto db_check_iterator(lua_State*, int stack_pos) -> database::Iterator*; +auto db_check_record(lua_State*, int stack_pos) -> database::Record*; -auto pushTagValue(lua_State* L, const database::TagValue& val) -> void; +auto pushTagValue(lua_State* L, const database::TagValue& val) -> void; auto RegisterDatabaseModule(lua_State*) -> void; -- cgit v1.2.3