mirror of
https://github.com/windmill-labs/windmill.git
synced 2026-09-06 00:02:13 +00:00
* nit(mcp): filter out scripts without main function from tools list - Add no_main_func field to ScriptInfo struct - Update SQL query to select no_main_func from database - Filter scripts where no_main_func is true in list_tools function - Hub scripts remain unaffected as requested Resolves #6021 Co-authored-by: Ruben Fiszel <rubenfiszel@users.noreply.github.com> * perf(mcp): optimize script filtering with SQL WHERE clause Move the no_main_func filtering from Rust code to SQL WHERE clause for better performance: - Add conditional WHERE clause in inner_get_items for scripts only - Remove Rust-level filtering loop in list_tools function - Reduces data transfer and improves query performance by filtering at database level - Handles NULL values properly with (o.no_main_func IS NOT TRUE OR o.no_main_func IS NULL) Co-authored-by: centdix <centdix@users.noreply.github.com> * fix * refactor(mcp): optimize filtering by removing no_main_func field selection Remove no_main_func field from ScriptInfo struct and SQL selection while keeping WHERE clause filtering. This improves performance by filtering at the database level without transferring unnecessary data to the application layer. Co-authored-by: Ruben Fiszel <rubenfiszel@users.noreply.github.com> --------- Co-authored-by: claude[bot] <209825114+claude[bot]@users.noreply.github.com> Co-authored-by: Ruben Fiszel <rubenfiszel@users.noreply.github.com> Co-authored-by: centdix <centdix@users.noreply.github.com> Co-authored-by: centdix <farhadg110@gmail.com>