jgrulich created this revision.
Restricted Application added a project: Plasma.
Restricted Application added a subscriber: plasma-devel.

REVISION SUMMARY
  I've made few improvements which should help and make installation or update 
  process with flatpak backend a bit better experience:
  
  1. Properly cancel flatpak transactions, it now calls proper g_cancellable to 
cancel running transactions in FlatpakTransactionJob
  
  2. Pass FlatpakTransaction as a parent of FlatpakTransactionJob so it gets 
deleted together with parent
  
  3. Make difference between finished transaction, whether it finished 
successfuly or finished with an error, with this when we finish a flatpak 
transaction we can update app metadata accordingly, because when the 
transaction fails, we shouldn't do that, because failed updates will be marked 
as installed instead of updatable and the user would think that the app has 
been updated even though they see an error
  
  4. When installing an application which don't have required runtime installed 
we should care only about state of the application and not of the runtime. I.e 
imagine installing application requiring a runtime, it will start downloading 
both together, the app will be installed first and waiting for runtime to 
finish, but when the installation of runtime fails, we call 
transactionFinished(false) and that would cause the app marked as not 
installed, while only runtime failed, also we would set transaction status to 
DoneWithError status also ending up with up not being updated in FlatpakBackend

REPOSITORY
  R134 Discover Software Store

BRANCH
  Plasma/5.10

REVISION DETAIL
  https://phabricator.kde.org/D6298

AFFECTED FILES
  libdiscover/Transaction/Transaction.h
  libdiscover/backends/FlatpakBackend/FlatpakTransaction.cpp
  libdiscover/backends/FlatpakBackend/FlatpakTransaction.h
  libdiscover/backends/FlatpakBackend/FlatpakTransactionJob.cpp
  libdiscover/backends/FlatpakBackend/FlatpakTransactionJob.h

To: jgrulich, apol
Cc: plasma-devel, ZrenBot, spstarr, progwolff, lesliezhai, ali-mohamed, 
jensreuterberg, abetts, sebas, apol, mart, lukas

Reply via email to