Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Detect changes to replaced_by #4127

Merged
merged 1 commit into from
Jul 22, 2024

Conversation

HebaruSan
Copy link
Member

Problem

During KSP-CKAN/NetKAN#10108, we noticed that replaced_by is a bit janky.

Causes

  • We check for the replaced_by property in the installed module, not the available module, so if users install a module and then later we add replaced_by to migrate them to a new identifier, they won't see the replace checkbox unless they reinstall the mod to get the new metadata.
  • Compounding this, when we decide whether to prompt for reinstallation, replaced_by isn't checked. So the user would have to reinstall manually, which mostly defeats the purpose.

Changes

Now if you add replaced_by to a module, users who already have it installed will be prompted to reinstall it with the upgrade checkbox, after which they'll be prompted to replace it with the replace checkbox.

replaced_by could use more streamlining after this, but this will at least make it baseline usable.

@HebaruSan HebaruSan added Bug Something is not working as intended Easy This is easy to fix Core (ckan.dll) Issues affecting the core part of CKAN Relationships Issues affecting depends, recommends, etc. labels Jul 22, 2024
@HebaruSan HebaruSan merged commit f7b7d1c into KSP-CKAN:master Jul 22, 2024
3 checks passed
@HebaruSan HebaruSan deleted the fix/replaced_by-reinst branch July 22, 2024 15:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Something is not working as intended Core (ckan.dll) Issues affecting the core part of CKAN Easy This is easy to fix Relationships Issues affecting depends, recommends, etc.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant