{"id":21333,"library":"featuremanagement","title":"Microsoft Feature Management","description":"A Python library for enabling/disabling features at runtime, commonly used in .NET-style feature flag systems. Current version: 2.1.0. Released as needed, follows semantic versioning.","status":"active","version":"2.1.0","language":"python","source_language":"en","source_url":"https://github.com/microsoft/FeatureManagement-Python","tags":["feature-flags","feature-management","microsoft","azure"],"install":[{"cmd":"pip install featuremanagement","lang":"bash","label":"Install from PyPI"}],"dependencies":[{"reason":"Required for using Azure App Configuration as a feature flag provider.","package":"azure-appconfiguration-provider","optional":false}],"imports":[{"note":"Import from featuremanagement directly, not from submodules.","wrong":"","symbol":"FeatureManager","correct":"from featuremanagement import FeatureManager"},{"note":"Correct import path.","wrong":"","symbol":"FeatureFilterEvaluationContext","correct":"from featuremanagement import FeatureFilterEvaluationContext"}],"quickstart":{"code":"from featuremanagement import FeatureManager\n\n# Initialize with in-memory feature flags\nfeature_manager = FeatureManager(feature_flags={\n    \"Beta\": {\n        \"enabled\": True\n    }\n})\n\n# Check if a feature is enabled\nif feature_manager.is_enabled(\"Beta\"):\n    print(\"Beta feature is enabled\")\nelse:\n    print(\"Beta feature is disabled\")","lang":"python","description":"Basic usage: create a FeatureManager with a dictionary of flags and check if a feature is enabled."},"warnings":[{"fix":"Ensure your flag dictionary structure matches: {\"FeatureName\": {\"enabled\": True}}.","message":"Feature flags dictionary must follow the correct schema: each flag must have an 'enabled' key (boolean) and optionally 'conditions'.","severity":"gotcha","affected_versions":">=2.0.0"},{"fix":"Use the Azure App Configuration provider to load flags automatically, or manually parse flags to match the expected schema.","message":"The library expects feature flags in a specific format when using Azure App Configuration; mismatched structure can cause silent failures.","severity":"gotcha","affected_versions":">=2.0.0"},{"fix":"Ensure you pass the correct arguments: is_enabled(feature_name, user_context=None).","message":"The method 'is_enabled' is stable but some older documentation refers to 'is_enabled' with a different signature (without the user context).","severity":"deprecated","affected_versions":">=2.0.0"}],"env_vars":null,"last_verified":"2026-04-27T00:00:00.000Z","next_check":"2026-07-26T00:00:00.000Z","problems":[{"fix":"Run 'pip install featuremanagement' in the correct environment.","cause":"The library is not installed or the Python environment is incorrect.","error":"ModuleNotFoundError: No module named 'featuremanagement'"},{"fix":"Use FeatureManager from featuremanagement 2.0+, which includes 'is_enabled'. Check your installed version with 'pip show featuremanagement'.","cause":"Typo or older version without 'is_enabled' method.","error":"AttributeError: 'FeatureManager' object has no attribute 'is_enabled'"},{"fix":"Ensure each flag has an 'enabled' key with a boolean value. Optionally add 'conditions' with appropriate filters.","cause":"The flags dictionary passed to FeatureManager does not conform to the required schema.","error":"ValueError: The feature flag configuration is invalid."}],"ecosystem":"pypi","meta_description":null,"install_score":null,"install_tag":null,"quickstart_score":null,"quickstart_tag":null}