• v0.5.5 08379c51c7

    v0.5.5 Stable

    x released this 2026-02-23 09:19:11 +00:00 | 5 commits to main since this release

    Signed by x
    GPG key ID: A14ACA8AB45A9C27

    VSKI v0.5.5

    Improvements

    • Better filter operator parsing - Reordered regex alternation to match longer operators first (>=, <=, !=) before shorter ones (>, <, =).
    • Parentheses handling - Added stripParens() function to properly remove parentheses from grouped filter conditions.

    Technical Details

    Files Changed

    • internal/services/records.go - Fixed filter being ignored in field rules bypass path (line 131)
    • internal/utils/query.go - Fixed regex operator order and added parentheses stripping

    Filter Examples Now Working

    // Comparison operators
    client.collection("posts").getList(1, 30, { filter: "views >= 100" });
    client.collection("posts").getList(1, 30, { filter: "views <= 500" });
    
    // Logical operators
    client.collection("posts").getList(1, 30, { 
      filter: "published = true AND views > 100" 
    });
    client.collection("posts").getList(1, 30, { 
      filter: "category = 'drafts' OR views >= 1000" 
    });
    
    // Parentheses grouping
    client.collection("posts").getList(1, 30, { 
      filter: "(category = 'tech' OR category = 'news') AND published = true" 
    });
    
    // LIKE operator
    client.collection("posts").getList(1, 30, { 
      filter: "title ~ 'Post'" 
    });
    

    Testing

    New e2e test added: 52_filters_test.ts - Comprehensive test coverage for:

    • Equality operators (=, !=)
    • Comparison operators (>, <, >=, <=)
    • Logical operators (AND, OR)
    • LIKE operator (~)
    • Parentheses grouping
    • Combined filters with sorting
    • Combined filters with pagination

    Changelog

    v0.5.5 (2026-02-23)

    Fixed

    • Filters now work correctly when field rules are active (admin or defined field rules)
    • Filter parser correctly handles >= and <= operators
    • Parentheses in filter expressions are properly handled

    Added

    • stripParens() helper function in internal/utils/query.go
    • E2E test suite for filter functionality (52_filters_test.ts)

    Changed

    • Regex operator alternation reordered to match longer operators first
    Downloads