"""Protect a real feature boundary, not only a visible UI button."""
from keygen_device_sdk import FeatureNotLicensedError, LicenseSDKError


def export_hdl(client) -> None:
    try:
        state = client.validate_or_raise()
        state.require("YOUR_FEATURE_CODE")
        print("Exporting HDL...")
    except FeatureNotLicensedError:
        print("This License does not include HDL export")
    except LicenseSDKError as exc:
        print(f"Export blocked: {exc}")
