[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#927304: marked as done (testing-pu: aptly/1.3.0+ds1-2.1+deb10u1)



Your message dated Sun, 26 May 2019 14:01:40 +0100
with message-id <20190526130140.GA14330@powdarrmonkey.net>
and subject line Re: Bug#927304: unblock: aptly/1.3.0+ds1-2.2
has caused the Debian Bug report #927304,
regarding testing-pu: aptly/1.3.0+ds1-2.1+deb10u1
to be marked as done.

This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.

(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact owner@bugs.debian.org
immediately.)


-- 
927304: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=927304
Debian Bug Tracking System
Contact owner@bugs.debian.org with problems
--- Begin Message ---
Package: release.debian.org
Severity: normal
User: release.debian.org@packages.debian.org
Usertags: unblock

Please unblock package aptly

* It fixes #911924(support database migration from <= 1.3.0-6)

  As I said in #911924, this should be grave. My justification is that
  users should be able to upgrade from stretch, without losting data.

* Previous NMU includes a patch which has a mistake, which may cause
  lost one DB field info.

unblock aptly/1.3.0+ds1-2.2

The debdiff is:


diff -Nru aptly-1.3.0+ds1/debian/changelog aptly-1.3.0+ds1/debian/changelog
--- aptly-1.3.0+ds1/debian/changelog	2019-04-05 23:19:14.000000000 +0800
+++ aptly-1.3.0+ds1/debian/changelog	2019-04-16 00:18:23.000000000 +0800
@@ -1,3 +1,12 @@
+aptly (1.3.0+ds1-2.2) unstable; urgency=medium
+
+  * Non-maintainer upload.
+  * Add patch to fix DB backwards compatibility (Closes: #911924)
+  * Fix struct field tag typo
+  * Update debian/NEWS about DB compatibility
+
+ -- Shengjing Zhu <zhsj@debian.org>  Tue, 16 Apr 2019 00:18:23 +0800
+
 aptly (1.3.0+ds1-2.1) unstable; urgency=medium
 
   [ Shengjing Zhu ]
diff -Nru aptly-1.3.0+ds1/debian/NEWS aptly-1.3.0+ds1/debian/NEWS
--- aptly-1.3.0+ds1/debian/NEWS	2019-04-05 22:38:08.000000000 +0800
+++ aptly-1.3.0+ds1/debian/NEWS	2019-04-16 00:18:23.000000000 +0800
@@ -1,3 +1,13 @@
+aptly (1.3.0+ds1-2.2) unstable; urgency=medium
+
+  This version tries to fix the database backwards compatibility,
+  so you don't need to rebuild the database if you upgrade from
+  aptly <= 1.3.0-6.
+
+  However some fields are missing, like created time of a snapshot.
+
+ -- Shengjing Zhu <zhsj@debian.org>  Sat, 13 Apr 2019 23:26:39 +0800
+
 aptly (1.3.0+ds1-2) unstable; urgency=medium
 
   * The database created by aptly <= 1.3.0-6 is not compatible
diff -Nru aptly-1.3.0+ds1/debian/patches/Fix-time.Time-msgpack-decoding-backwards-compatibili.patch aptly-1.3.0+ds1/debian/patches/Fix-time.Time-msgpack-decoding-backwards-compatibili.patch
--- aptly-1.3.0+ds1/debian/patches/Fix-time.Time-msgpack-decoding-backwards-compatibili.patch	1970-01-01 08:00:00.000000000 +0800
+++ aptly-1.3.0+ds1/debian/patches/Fix-time.Time-msgpack-decoding-backwards-compatibili.patch	2019-04-16 00:18:23.000000000 +0800
@@ -0,0 +1,40 @@
+From: Shengjing Zhu <zhsj@debian.org>
+Date: Sat, 13 Apr 2019 22:57:46 +0800
+Subject: Fix time.Time msgpack decoding backwards compatibility
+
+This allows aptly to decode DB created by old codec library.
+
+Forwarded: https://github.com/aptly-dev/aptly/pull/830
+---
+ deb/remote.go   | 3 ++-
+ deb/snapshot.go | 3 ++-
+ 2 files changed, 4 insertions(+), 2 deletions(-)
+
+diff --git a/deb/remote.go b/deb/remote.go
+index 167d45f..71eb984 100644
+--- a/deb/remote.go
++++ b/deb/remote.go
+@@ -600,7 +600,8 @@ func (repo *RemoteRepo) Decode(input []byte) error {
+ 	decoder := codec.NewDecoderBytes(input, &codec.MsgpackHandle{})
+ 	err := decoder.Decode(repo)
+ 	if err != nil {
+-		if strings.HasPrefix(err.Error(), "codec.decoder: readContainerLen: Unrecognized descriptor byte: hex: 80") {
++		if strings.HasPrefix(err.Error(), "codec.decoder: readContainerLen: Unrecognized descriptor byte: hex: 80") ||
++			strings.Contains(err.Error(), "invalid length of bytes for decoding time") {
+ 			// probably it is broken DB from go < 1.2, try decoding w/o time.Time
+ 			var repo11 struct { // nolint: maligned
+ 				UUID             string
+diff --git a/deb/snapshot.go b/deb/snapshot.go
+index fc7689c..feef44a 100644
+--- a/deb/snapshot.go
++++ b/deb/snapshot.go
+@@ -140,7 +140,8 @@ func (s *Snapshot) Decode(input []byte) error {
+ 	decoder := codec.NewDecoderBytes(input, &codec.MsgpackHandle{})
+ 	err := decoder.Decode(s)
+ 	if err != nil {
+-		if strings.HasPrefix(err.Error(), "codec.decoder: readContainerLen: Unrecognized descriptor byte: hex: 80") {
++		if strings.HasPrefix(err.Error(), "codec.decoder: readContainerLen: Unrecognized descriptor byte: hex: 80") ||
++			strings.Contains(err.Error(), "invalid length of bytes for decoding time") {
+ 			// probably it is broken DB from go < 1.2, try decoding w/o time.Time
+ 			var snapshot11 struct {
+ 				UUID      string
diff -Nru aptly-1.3.0+ds1/debian/patches/Fix-UUID-struct-field-not-encoded-in-msgpack.patch aptly-1.3.0+ds1/debian/patches/Fix-UUID-struct-field-not-encoded-in-msgpack.patch
--- aptly-1.3.0+ds1/debian/patches/Fix-UUID-struct-field-not-encoded-in-msgpack.patch	2019-04-05 23:18:43.000000000 +0800
+++ aptly-1.3.0+ds1/debian/patches/Fix-UUID-struct-field-not-encoded-in-msgpack.patch	2019-04-16 00:18:23.000000000 +0800
@@ -13,7 +13,7 @@
  2 files changed, 5 insertions(+), 5 deletions(-)
 
 diff --git a/deb/local.go b/deb/local.go
-index e9fa17c..79cc308 100644
+index e9fa17c..fb3e404 100644
 --- a/deb/local.go
 +++ b/deb/local.go
 @@ -14,7 +14,7 @@ import (
@@ -30,7 +30,7 @@
  	DefaultComponent string `codec:",omitempty"`
  	// Uploaders configuration
 -	Uploaders *Uploaders `code:",omitempty" json:"-"`
-+	Uploaders *Uploaders `code:"Uploaders,omitempty" json:"-"`
++	Uploaders *Uploaders `codec:"Uploaders,omitempty" json:"-"`
  	// "Snapshot" of current list of packages
  	packageRefs *PackageRefList
  }
diff -Nru aptly-1.3.0+ds1/debian/patches/series aptly-1.3.0+ds1/debian/patches/series
--- aptly-1.3.0+ds1/debian/patches/series	2019-04-05 23:04:23.000000000 +0800
+++ aptly-1.3.0+ds1/debian/patches/series	2019-04-16 00:18:23.000000000 +0800
@@ -2,3 +2,4 @@
 kjk-lzma.patch
 pborman-uuid.patch
 Fix-UUID-struct-field-not-encoded-in-msgpack.patch
+Fix-time.Time-msgpack-decoding-backwards-compatibili.patch

--- End Message ---
--- Begin Message ---
On Tue, May 21, 2019 at 12:17:17AM +0800, Shengjing Zhu wrote:
> Control: tags -1 - moreinfo
> 
> On Sun, May 12, 2019 at 1:42 AM Jonathan Wiltshire <jmw@debian.org> wrote:
> > Please go ahead but use version 1.3.0+ds1-2.2~deb10u1 since this is
> > backport of something in unstable, not a divergence of testing.
> >
> 
> Sorry for the delay, it has been uploaded and built on all release
> architectures.
> 
> --
> Shengjing Zhu

Unblocked; thanks.

-- 
Jonathan Wiltshire                                      jmw@debian.org
Debian Developer                         http://people.debian.org/~jmw

4096R: 0xD3524C51 / 0A55 B7C5 1223 3942 86EC  74C3 5394 479D D352 4C51

--- End Message ---

Reply to: