Skip to content

[AI-FSSDK] [FSSDK-12368] Cleanup flag base setup (local holdouts)#506

Closed
Mat001 wants to merge 1 commit intomasterfrom
ai/mat001/FSSDK-12368-legacy-holdout-cleanup
Closed

[AI-FSSDK] [FSSDK-12368] Cleanup flag base setup (local holdouts)#506
Mat001 wants to merge 1 commit intomasterfrom
ai/mat001/FSSDK-12368-legacy-holdout-cleanup

Conversation

@Mat001
Copy link
Copy Markdown
Contributor

@Mat001 Mat001 commented Apr 20, 2026

Summary

Removes legacy flag-level holdout fields from the SDK as cleanup after local holdouts (FSSDK-12369) implementation.

Jira Ticket: FSSDK-12368

Changes

Step 1: Remove Legacy Fields ✅

  • Removed includedFlags and excludedFlags from Holdout.__init__()
  • Removed from HoldoutDict type definition

Step 2: Remove Legacy Methods ✅

  • Removed get_holdouts_for_flag() method from ProjectConfig
  • Removed entire flag-level targeting infrastructure:
    • global_holdouts list
    • included_holdouts dict
    • excluded_holdouts dict
    • flag_holdouts_map dict
    • Flag-level population logic in __init__
  • Removed flag-level holdout checking from DecisionService.get_variation_for_feature()

Step 3: Update Tests ✅

  • Removed includedFlags and excludedFlags from all test fixtures (41 occurrences)
  • Removed 8 test methods testing deprecated functionality

Verification

✅ Zero occurrences of includedFlags, excludedFlags, getHoldoutsForFlag in codebase
✅ All deprecated fields/methods removed
✅ Test fixtures updated to use new API

Impact

  • 7 files modified
  • 272 lines removed, 5 lines added
  • Net: -267 lines of legacy code eliminated

Test Plan

  • All existing tests pass
  • No references to deprecated fields/methods remain
  • Holdout functionality works using new local holdouts API

🤖 Generated with Claude Code

Remove deprecated flag-level holdout targeting system:
- Remove includedFlags and excludedFlags fields from Holdout model
- Remove get_holdouts_for_flag() method from ProjectConfig
- Remove flag-level holdout evaluation logic from decision service
- Update all tests to remove references to deprecated fields and methods

This cleanup prepares the SDK for the new rule-level holdout system
implemented in FSSDK-12369.

Verification:
- grep for "includedFlags", "excludedFlags", "getHoldoutsForFlag" returns zero results
- All legacy holdout tests updated to use new API
- No broken references remain

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
@Mat001 Mat001 closed this Apr 20, 2026
@Mat001 Mat001 deleted the ai/mat001/FSSDK-12368-legacy-holdout-cleanup branch April 20, 2026 18:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant