question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

[RFE] headlamp-plugin "upgrade" command for upgrading plugins

See original GitHub issue

Current situation

There are a number of things that need updating in existing plugin package.json scripts, and there could be in the future.

Typically new headlamp plugin versions required plugin authors to do things like:

  • upgrading the headlamp-plugin dependency version
  • adding extra config inside package.json (like the new eslint/prettier config)
  • adding extra required config files (like a previous version did with a tsconfig file)

Impact

As we upgrade headlamp plugins, make it easier for authors to upgrade their plugins so they are compatible.

Ideal future situation

Plugin authors know how to migrate to new versions of the plugin configuration (and code).

Implementation options

  • headlamp-plugin migrate would see the version in the package.json and try to run a migration script for each version. Similar to db migration scripts.
  • mention migration requirements in the release notes
  • add a plugin migration documentation page (to also link to from release notes) mentioning how to upgrade every version.

The headlamp-plugin/template folder git history shows changes to recent versions of the plugin.

By keeping most changes inside headlamp-plugins and keeping the API backwards compatible, the need for this is reduced. However that can’t work for every change.

This is related to the “Create a compatibility validation for plugins” issue. It could be that headlamp-plugin could check for new releases of headlamp-plugin and print a warning that the plugin is outdated, and link to instructions on how to do migration.

Issue Analytics

  • State:open
  • Created 2 years ago
  • Comments:5 (5 by maintainers)

github_iconTop GitHub Comments

1reaction
joaquimrochacommented, Feb 21, 2022

@illume , thanks for raising this issue. The 0.4.0 version of headlamp-plugin we published is still compatible with the previous versions. However, plugins created with this new version will have files like the ts/jsconfig ones which should be used but are not available unless one is creating a new plugin. So, this makes me think that instead of a headlamp-plugin migrate command, maybe we should just have headlamp-plugin update (and/or upgrade) command, which updates the headlamp-plugin version listed in the plugin’s package.json and performs any migration (including things not purely considered migration, like adding the mentioned config files).

About the docs, I think having a migration or update section with the changes needed to be done by plugin authors to stay up to date is a good idea as you suggested.

0reactions
illumecommented, Jul 22, 2022

npm start should probably print a warning if the version of headlamp-plugin is not up to date.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Create a compatibility validation for plugins · Issue #423 · kinvolk ...
However, if we are to make the installation of plugins more dynamic, w... ... [RFE] headlamp-plugin "upgrade" command for upgrading plugins #426.
Read more >
Upgrading plugins from the Plugin Manager
To upgrade plugins from the Plugin Manager: From your CloudBees product, select Manage Jenkins Manage Plugins. On the Updates tab, select Check now...
Read more >
RFE: Use "plymouth change-mode --system-upgrade" on ...
As part of my Flicker Free Boot work: https://fedoraproject.org/wiki/Changes/FlickerFreeBoot I've been working a new theme for offline-updates following: ...
Read more >
Plugins Functionality | Headlamp - GitHub Pages
Headlamp's plugins exist for changing or adding functionality related to the user interface and experience. Plugins Lib. The @kinvolk/headlamp-plugin module ...
Read more >
Untitled
Skyrim best warrior standing stone, Pro tools audio plugins guide, ... Early july mcat too late, Returning home, Projector headlights 1996 f250?
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found