- Created RELEASE_0.2.7_STATUS.md documenting critical bug fix - Updated MEMORY.md with Headlamp plugin development rules - Documented proper import paths and dependency management - Added Artifact Hub package information Generated with [Claude Code](https://claude.ai/code) via [Happy](https://happy.engineering) Co-Authored-By: Claude <noreply@anthropic.com> Co-Authored-By: Happy <yesreply@happy.engineering>
4.8 KiB
Release v0.2.7 Status
Release Date: 2026-02-12 Status: ✅ COMPLETE
Critical Bug Fix Release
This release fixes a critical bug where the plugin failed to load in the browser due to using internal Headlamp API paths.
Issue
The plugin was importing from internal paths like @kinvolk/headlamp-plugin/lib/lib/k8s/cluster instead of using the official public API. This caused the following error in the browser:
TypeError: undefined is not an object (evaluating 'Ot.KubeObject')
The plugin would appear in backend logs as loaded, but the sidebar would not appear in the UI.
Root Cause
- Used internal import paths:
@kinvolk/headlamp-plugin/lib/lib/k8s/* - These paths are not in the Vite build system's externals list
- Headlamp doesn't provide these internal modules to plugins
- Result:
undefinedwhen plugin tries to accessKubeObject,apiFactoryWithNamespace, etc.
Solution
Updated all imports to use the official public API:
Before (v0.2.5, v0.2.6):
import { KubeObject } from '@kinvolk/headlamp-plugin/lib/lib/k8s/cluster';
import { apiFactoryWithNamespace } from '@kinvolk/headlamp-plugin/lib/lib/k8s/apiProxy';
After (v0.2.7):
import { K8s, ApiProxy } from '@kinvolk/headlamp-plugin/lib';
const { KubeObject } = K8s.cluster;
const { apiFactoryWithNamespace } = ApiProxy;
Files Modified
src/types.ts- UseK8s.cluster.KubeObjectInterfacesrc/lib/SealedSecretCRD.ts- Use official K8s and ApiProxy importspackage.json- Moved node-forge to dependencies (from devDependencies)vite.config.js- NEW - Custom globals config (not actually needed after import fix)
Commits
f2a8ec4- fix: use official Headlamp API instead of internal paths5675517- chore: bump version to 0.2.773cb990- fix: sort imports for linter7828f02- chore: release v0.2.7 (automated by CI)
Release Details
- Version: v0.2.7
- Tag: v0.2.7
- GitHub Release: https://github.com/privilegedescalation/headlamp-sealed-secrets-plugin/releases/tag/v0.2.7
- Tarball: headlamp-sealed-secrets-0.2.7.tar.gz
- Checksum:
sha256:b2ca7d70e22839178fe46f3618abe6fc6b9dc9b51b9c52a6faa4759d4f756152 - Archive URL: https://github.com/privilegedescalation/headlamp-sealed-secrets-plugin/releases/download/v0.2.7/headlamp-sealed-secrets-0.2.7.tar.gz
Build Metrics
- Bundle: 357.92 kB (98.00 kB gzipped) - slightly smaller than v0.2.5/v0.2.6
- Build time: ~1s (optimized)
- TypeScript: ✅ No errors
- Linter: ✅ No warnings
Verification
Local Testing
- ✅ Plugin builds successfully
- ✅ Plugin packages into tarball
- ✅ Tarball structure validated
- ✅ Checksum computed and verified
Kubernetes Deployment
- ✅ Plugin installed in Headlamp pod
- ✅ Plugin loaded by Headlamp backend
- ✅ Plugin appears in browser (sidebar visible)
- ✅ No JavaScript errors in browser console
- ✅ All functionality working
CI/CD
- ✅ Release workflow completed successfully
- ✅ GitHub release created with tarball
- ✅ Metadata updated in
artifacthub-pkg.yml - ✅ Tag v0.2.7 pushed to origin
Artifact Hub Sync
- Status: Pending (5-10 minutes expected)
- Package Name:
sealed-secrets(notheadlamp-sealed-secrets) - URL: https://artifacthub.io/packages/headlamp/privilegedescalation/sealed-secrets
- Monitoring: Background task checking every 60 seconds
Key Learnings
-
Always use official Headlamp plugin API
- Import from
@kinvolk/headlamp-plugin/lib - Never use internal paths like
/lib/lib/k8s/*
- Import from
-
Build system behavior
- Headlamp build system has hardcoded externals list in Vite config
.pluginrcfile is NOT actually read by the build system- Custom
vite.config.jscan override externals but not needed with proper imports
-
Dependency placement matters
- Third-party dependencies (like node-forge) must be in
dependencies - Headlamp build system externalizes devDependencies by default
- Third-party dependencies (like node-forge) must be in
-
Testing approach
- Backend logs showing plugin loaded ≠ plugin working in browser
- Always check browser console for JavaScript errors
- Hard refresh (Cmd+Shift+R / Ctrl+Shift+R) required after plugin updates
Next Steps
- ✅ Release v0.2.7 - COMPLETE
- ⏳ Monitor Artifact Hub sync (5-10 minutes)
- 📋 Update memory/MEMORY.md with learnings - COMPLETE
- 📋 Create RELEASE_0.2.7_STATUS.md - COMPLETE
- ⏳ Test plugin installation from Artifact Hub when synced
- 📋 Verify plugin works in fresh Headlamp instance
Conclusion
✅ v0.2.7 Successfully Released
The critical bug preventing the plugin from loading in the browser has been fixed by using the official Headlamp plugin API instead of internal paths. The plugin now loads correctly and all functionality is working as expected.
Users on v0.2.5 or v0.2.6 should upgrade to v0.2.7 immediately.