Skip to content

Conversation

@mturley
Copy link
Contributor

@mturley mturley commented Dec 17, 2025

Description

🤖 Description generated in part by Claude Code

Adds a temporary development feature flag to hide the Hugging Face access token field from catalog settings, allowing gradual rollout of this feature.

Changes

Feature Flag Refactoring

  • Refactored useTempDevCatalogAdvancedFiltersFeatureAvailable hook into a more general useTempDevFeatureAvailable hook that supports multiple feature flags
  • Consolidated feature flag management into a single enum-based system with TempDevFeature enum containing:
    • CatalogAdvancedFilters - for advanced filters feature
    • CatalogHuggingFaceApiKey - for HuggingFace access token field
  • Updated window methods to support toggling each feature independently via browser console

UI Changes

  • Modified CredentialsSection.tsx to conditionally render:
    • The "Credentials" section title only when the HF API key feature is enabled
    • The access token field and validation button only when the HF API key feature is enabled
    • The organization field always remains visible
  • Updated ModelPerformanceViewToggleCard.tsx to use the refactored hook

Test Updates

  • Updated modelCatalogSettings.ts page object to support enabling the HuggingFace API key feature flag in tests
  • Modified 7 cypress tests that interact with the access token field to enable TempDevCatalogHuggingFaceApiKeyFeature
  • Tests now follow the same pattern as TempDevCatalogAdvancedFiltersFeature in modelCatalog.ts

Testing

  • Make sure the access token field is hidden from the add/manage source form by default.
  • On the catalog settings page, go to the add/manage source form.
  • In your browser console, run:
window.setTempDevCatalogHuggingFaceApiKeyFeatureAvailable(true);
  • See that the field becomes visible.

Merge criteria:

  • All the commits have been signed-off (To pass the DCO check)
  • The commits have meaningful messages
  • Automated tests are provided as part of the PR for major new functionalities; testing instructions have been added in the PR body (for PRs involving changes that are not immediately obvious).
  • The developer has manually tested the changes and verified that the changes work.
  • Code changes follow the kubeflow contribution guidelines.
  • For first time contributors: Please reach out to the Reviewers to ensure all tests are being run, ensuring the label ok-to-test has been added to the PR.

If you have UI changes

  • The developer has added tests or explained why testing cannot be added.
  • Included any necessary screenshots or gifs if it was a UI change.
  • Verify that UI/UX changes conform the UX guidelines for Kubeflow.

…atalog settings

Signed-off-by: Mike Turley <mike.turley@alum.cs.umass.edu>
Signed-off-by: Mike Turley <mike.turley@alum.cs.umass.edu>
@YuliaKrimerman
Copy link
Contributor

/lgtm
/approve

@google-oss-prow
Copy link

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: YuliaKrimerman

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@google-oss-prow google-oss-prow bot merged commit 944e1ee into kubeflow:main Jan 7, 2026
26 checks passed
@mturley mturley deleted the hide-hf-api-key branch January 8, 2026 16:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants