Update to 1.8.3

This commit is contained in:
Kalev Lember 2020-11-17 14:48:21 +01:00
parent 1a5680034e
commit fb01726dcf
6 changed files with 7 additions and 108 deletions

1
.gitignore vendored
View File

@ -85,3 +85,4 @@
/flatpak-1.8.0.tar.xz /flatpak-1.8.0.tar.xz
/flatpak-1.8.1.tar.xz /flatpak-1.8.1.tar.xz
/flatpak-1.8.2.tar.xz /flatpak-1.8.2.tar.xz
/flatpak-1.8.3.tar.xz

View File

@ -1,26 +0,0 @@
From 7ad549b89dfbfb67fd1cbbf6cafdd996e4722246 Mon Sep 17 00:00:00 2001
From: "Owen W. Taylor" <otaylor@fishsoup.net>
Date: Wed, 9 Sep 2020 16:14:57 -0400
Subject: [PATCH] OCI: extract appstream data for runtimes
Runtimes also have appstream data - with description, license information,
and so forth, so we should extract the appstream data from the index
for refs that start with runtime/ as well.
---
common/flatpak-oci-registry.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/common/flatpak-oci-registry.c b/common/flatpak-oci-registry.c
index cf501a5eb..0f7471129 100644
--- a/common/flatpak-oci-registry.c
+++ b/common/flatpak-oci-registry.c
@@ -3120,7 +3120,8 @@ add_image_to_appstream (SoupSession *soup_session,
return;
ref_parts = g_strsplit (ref, "/", -1);
- if (g_strv_length (ref_parts) != 4 || strcmp (ref_parts[0], "app") != 0)
+ if (g_strv_length (ref_parts) != 4 ||
+ (strcmp (ref_parts[0], "app") != 0 && strcmp (ref_parts[0], "runtime") != 0))
return;
id = ref_parts[1];

View File

@ -1,43 +0,0 @@
From 834c8d4524062349e36920ebefbd1c50b14a6c25 Mon Sep 17 00:00:00 2001
From: Alexander Larsson <alexl@redhat.com>
Date: Fri, 11 Sep 2020 16:24:23 +0200
Subject: [PATCH] Don't loop authentincating if updating to the current version
In case we need to authenticate for updates (in my test case i was
doing an OCI downgrade) we might need to download a commit object (or
in the OCI case a manifest json), so it did a request_required_tokens(),
but that noticed during the flatpak_transaction_normalize_ops() call
that the partial resolve to a particular commit actually was the
same as the local installed commit and marked op->skip = TRUE.
However, when we got back to resolving the op again we didn't actually
look at the skip, so it kept looping wanting (but never doing) auth.
The fix is to just directly resolve ops marked as skipped.
---
common/flatpak-transaction.c | 12 ++++++++++++
1 file changed, 12 insertions(+)
diff --git a/common/flatpak-transaction.c b/common/flatpak-transaction.c
index 410df8e54..9f9da23bd 100644
--- a/common/flatpak-transaction.c
+++ b/common/flatpak-transaction.c
@@ -2765,6 +2765,18 @@ resolve_ops (FlatpakTransaction *self,
if (op->resolved)
continue;
+ if (op->skip)
+ {
+ /* We're not yet resolved, but marked skip anyway, this can happen if during
+ * request_required_tokens() we were normalized away even though not fully resolved.
+ * For example we got the checksum but need to auth to get the commit, but the
+ * checksum we got was the version already installed.
+ */
+ g_assert (op->resolved_commit != NULL);
+ mark_op_resolved (op, op->resolved_commit, NULL, NULL, NULL);
+ continue;
+ }
+
if (op->kind == FLATPAK_TRANSACTION_OPERATION_UNINSTALL)
{
/* We resolve to the deployed metadata, because we need it to uninstall related ops */

View File

@ -1,32 +0,0 @@
From 6cf80f4703e57a819c6adc94b5a98b7c3e4c57d2 Mon Sep 17 00:00:00 2001
From: Alexander Larsson <alexl@redhat.com>
Date: Fri, 11 Sep 2020 16:47:05 +0200
Subject: [PATCH] OCI: Fix progress reporting
Somewhere during the progress reporting cleanup we lost the progress
for OCI pulls, this puts it back.
---
common/flatpak-progress.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/common/flatpak-progress.c b/common/flatpak-progress.c
index e3b8338c5..a83bcf816 100644
--- a/common/flatpak-progress.c
+++ b/common/flatpak-progress.c
@@ -428,6 +428,7 @@ flatpak_progress_update_oci_pull (FlatpakProgress *self,
if (self == NULL)
return;
+ self->requested = n_layers; /* Need to set this to trigger start of progress reporting, see update_status_progress_and_estimating() */
self->outstanding_fetches = n_layers - pulled_layers;
self->fetched_delta_parts = pulled_layers;
self->total_delta_parts = n_layers;
@@ -438,6 +439,8 @@ flatpak_progress_update_oci_pull (FlatpakProgress *self,
self->total_delta_part_usize = total_size;
self->total_delta_superblocks = 0;
update_status_progress_and_estimating (self);
+
+ self->callback (self->status, self->progress, self->estimating, self->user_data);
}
guint32

View File

@ -2,8 +2,8 @@
%global ostree_version 2018.9 %global ostree_version 2018.9
Name: flatpak Name: flatpak
Version: 1.8.2 Version: 1.8.3
Release: 3%{?dist} Release: 1%{?dist}
Summary: Application deployment framework for desktop apps Summary: Application deployment framework for desktop apps
License: LGPLv2+ License: LGPLv2+
@ -11,10 +11,6 @@ URL: http://flatpak.org/
Source0: https://github.com/flatpak/flatpak/releases/download/%{version}/%{name}-%{version}.tar.xz Source0: https://github.com/flatpak/flatpak/releases/download/%{version}/%{name}-%{version}.tar.xz
# Add Fedora flatpak repositories # Add Fedora flatpak repositories
Source1: flatpak-add-fedora-repos.service Source1: flatpak-add-fedora-repos.service
# Various OCI fixes backported from upstream
Patch0: 3845.patch
Patch1: 3849.patch
Patch2: 3850.patch
# Fix bogus volatiles caught by gcc-11 # Fix bogus volatiles caught by gcc-11
Patch3: %{name}-gcc11.patch Patch3: %{name}-gcc11.patch
@ -273,6 +269,9 @@ fi
%changelog %changelog
* Tue Nov 17 2020 Kalev Lember <klember@redhat.com> - 1.8.3-1
- Update to 1.8.3
* Sat Oct 31 2020 Jeff Law <law@redhat.com> - 1.8.2-3 * Sat Oct 31 2020 Jeff Law <law@redhat.com> - 1.8.2-3
- Fix bogus volatiles caught by gcc-11 - Fix bogus volatiles caught by gcc-11

View File

@ -1 +1 @@
SHA512 (flatpak-1.8.2.tar.xz) = f27c05b2621328dce31e4c31ae097765864bac84f6c1fada23f48c0235c6b85f447948a07861653f7bed4e17e43f8ff3d2c60263e23426c765c787b5f447a4e2 SHA512 (flatpak-1.8.3.tar.xz) = be6dbe16e29f56cb66a5bf18f5cf7d5810b58eda7e2f7168227e6b73ec5e6c879752348be745fc7eb3fb71c65bb97900904a42fbd7a05f0f6f2568ae40fbba9e