flathub / com.sublimetext.three

https://flathub.org/apps/details/com.sublimetext.three
6 stars 4 forks source link

Find a good user story for upgrading Package Control #37

Open ptomato opened 5 months ago

ptomato commented 5 months ago

See #20.

We currently include Package Control as extra-data in this flatpak. However, Package Control does not version their file at the location where we look for the extra-data. They just replace the same file with a new version, and it has a different signature.

This is bad, because it completely breaks the upgrading story for the whole app, not just Package Control. If we ship any update to the app, the extra-data will be downloaded at update time, and if Package Control has shipped a new version in the meantime, the extra-data download will fail.

When I followed up with Package Control about this (https://github.com/wbond/package_control/issues/1508), they said we should not be automatically downloading Package Control. At the time this app was added to Flathub, there was no other convenient way to get Package Control besides installing it as extra-data, but now Sublime Text has an in-app feature that will download and install Package Control, so that's less of a problem.

So clearly the right thing to do is remove the Package Control extra-data and ship a Sublime Text update on Flathub. However, I believe that that will leave existing installations without Package Control, which will break packages for basically all existing users (almost nobody uses Sublime Text without Package Control) and it won't be obvious what the problem is.

This issue is about figuring out how to do this. Either we figure out how to preserve people's existing Package Control installation during the upgrade even if we don't have the extra-data anymore; or we pop up a very loud message telling users how to initiate the in-app installation of Package Control.

x80486 commented 1 month ago

Is there a way to display a dialog after the upgrade with the breaking change and possible solutions?

I think upgrading to the latest runtime is more important.

ptomato commented 1 month ago

There should be a way to automatically open a document with the message, the first time the app is opened after the upgrade. Many extensions do this in order to show their changelog after they are updated. I don't know how to do it, though.